Plotting — rasterio documentation
rasterio.readthedocs.io › en › latestRasterio also provides rasterio.plot.show () to perform common tasks such as displaying multi-band images as RGB and labeling the axes with proper geo-referenced extents. The first argument to show () represent the data source to be plotted. This can be one of. A numpy ndarray, 2D or 3D. If the array is 3D, ensure that it is in rasterio band order.
Color — rasterio documentation
https://rasterio.readthedocs.io/en/latest/topics/color.htmlGDAL builds the color interpretation based on the driver and creation options. With the GTiff driver, rasters with exactly 3 bands of uint8 type will be RGB, 4 bands of uint8 will be RGBA by default.. Color interpretation can be set when creating a new datasource with the photometric creation option: >>> profile = src. profile >>> profile ['photometric'] = "RGB" >>> with rasterio. …
How to visualize multiband imagery using rasterio ...
gis.stackexchange.com › questions › 306164Dec 16, 2018 · The Rasterio Plotting documentation describes how to visualize multiband imagery. For example, using 4-band NAIP imagery: import rasterio from rasterio.plot import show src = rasterio.open("path/to/your/image/m_3511642_sw_11_1_20140704.tif") show(src) To visualize specific band combination use the following approach . In this case, I am creating a false color composite image using the NIR band: