Closed rajadain closed 6 years ago
Here's the current output from develop
when posting the above file:
{
"result": {
"List(0)": null
}
}
... and here's the output from this branch:
{
"result": {
"List(0)": 93.80207061767578
}
}
Tried out the prior operations & the values remain the same as on develop
.
Seeing values for 1 sq km in MMW:
This looks good to me!
I tested it with the jar and in MMW/BigCZ and both worked as described above. The values for the existing operations remained the same post-pixelIsArea
, and the value for the new pixel op is now coming back as not null.
Overview
Previously, we would always treat raster pixels as points, so if a pixel's centroid was covered in an area of interest it would be included, otherwise not. For certain rasters, where the pixel sizes are very large, for small areas of interest, no pixels are included since the areas do not cover their centroids.
By allowing the calling JSON to specify whether to treat pixels as points or areas, we allow treating certain rasters (as determined by the caller) as having pixels as areas, which will make small areas of interests run again.
Connects https://github.com/WikiWatershed/model-my-watershed/issues/2253
Demo
Testing Instructions
develop
, POST it to the geoprocessing service. Ensure you see a 0 in the output.worker
VM. Restart the geoprocessing service.base.py
: