python sentinel 2-L2A

Hi everyone,

I am new on processing sentinel2 data with python.
I am stucked on plotting a sentinel 2 image using rasterio. I am not able to plot correctly the image : strange colors or all white.
Why this happens?
I think the issue is related with the image conversion from 16 bit to 8 bit.
If this is the problem, any idea to do it in python?

Many thanks

Here is an example of processing sentinel 2 in python, using rasterio Library,

Source: https://www.hatarilabs.com/ih-en/sentinel2-images-explotarion-and-processing-with-python-and-rasterio

Also here following you could find other example, using rasterio, but with Landsat,

Source: https://geohackweek.github.io/raster/04-workingwithrasters/

1 Like