Using the point cloud filter is what's needed. Filter, not splitter.
one filter with:
@Component(z)==@Value(_band{0}.band_nodata)
and another output with:
@Component(z)!=@Value(_band{0}.band_nodata)
Hi @ts_84 , another approach, I think you can use RasterExtentsCoercer and AreaCalculator to get the areas of data extents and raster extents, and then calculate percentage of Nodata area from those areas.
I have an RGB raster, 1600 x 1000 pixels, and am assuming 255 is nodata. What I tried is a RasterExpressionEvaluator using the expression:
Int8: if (AA0] < 255 && AA1] < 255 && AA2] < 255, 0, 1)
Basically, if a cell is <255 then create a value 0, else create a value 1.
Now I run this through a RasterStatisticsCalculator. It tells me that band0.sum = 235926
So (235926 / (1600 * 1000)) * 100 = 14.75, so 14.75% of my raster is made up of nodata.
The advantage of that method is that it's quick. The disadvantage is that it destroys the raster data. But it's easy enough to just get this result and then merge it back onto the original raster using a FeatureMerger.
I have an RGB raster, 1600 x 1000 pixels, and am assuming 255 is nodata. What I tried is a RasterExpressionEvaluator using the expression:
Int8: if (AA0] < 255 && AA1] < 255 && AA2] < 255, 0, 1)
Basically, if a cell is <255 then create a value 0, else create a value 1.
Now I run this through a RasterStatisticsCalculator. It tells me that band0.sum = 235926
So (235926 / (1600 * 1000)) * 100 = 14.75, so 14.75% of my raster is made up of nodata.
The advantage of that method is that it's quick. The disadvantage is that it destroys the raster data. But it's easy enough to just get this result and then merge it back onto the original raster using a FeatureMerger.
In case it helps, I made this one of our questions of the week and covered it here: https://www.youtube.com/watch?v=ZvSaHQ7gouI&t=87s