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 Jan 30 19:52:26 2023 in commit: cac8d9d848299297977d1315b7e90cc3f7698730
Main index | Imagery index | Topics index | Keywords index | Graphical index | Full index
© 2003-2024 GRASS Development Team, GRASS GIS 8.5.0dev Reference Manual