Note: This document is for an older version of GRASS GIS that will be discontinued soon. You should upgrade, and read the current manual page.
Sentinel-2 scenes can also have small patches of zero cells, typically in water bodies. These patches are removed and filled with neighboring cells.
# download S2 scene affected by no.data pixels within the scene i.sentinel.download settings=credentials.txt \ uuid=0a7cb5ee-80d4-4d15-be19-0b3fdf40791f output=test_s2_scene # show lst of granules in scene i.sentinel.import -p input=test_s2_scene # import selected bands of scene i.sentinel.import input=test_s2_scene pattern='B0(2|3|4|8)_10m' g.list raster g.region raster=T32ULA_20190724T103029_B04_10m -p
# zoom to scene subset with undesired 0-value pixels g.region n=5516940 s=5516840 w=334410 e=334550 res=10 # visualize pixel values, e.g. in red band d.rast T32ULA_20190724T103029_B04_10m d.rast.num T32ULA_20190724T103029_B04_10m text_color=blue # fix 0-value pixels i.zero2null map=T32ULA_20190724T103029_B02_10m,T32ULA_20190724T103029_B03_10m,T32ULA_20190724T103029_B04_10m,T32ULA_20190724T103029_B08_10m # visualize updated pixel values (0 values now replaced), e.g. in red band d.rast T32ULA_20190724T103029_B04_10m d.rast.num T32ULA_20190724T103029_B04_10m text_color=blue
Available at: i.zero2null source code (history)
Latest change: Monday Jun 28 07:54:09 2021 in commit: 1cfc0af029a35a5d6c7dae5ca7204d0eb85dbc55
Main index | Imagery index | Topics index | Keywords index | Graphical index | Full index
© 2003-2023 GRASS Development Team, GRASS GIS 7.8.9dev Reference Manual