Proposed fix for a very important bug in reprojecting to lower resolution.
I think it's better (more correct) than previous behaviour, but not sure yet if it is 100% accurate.
It seems to me that the downsampling now happens in the original projection system, and then it is warping to the new CRS. This will work fine if the low resolution pixel is rectangular in both projection systems.
Checklist
[x] ./CHANGELOG.md updated, if necessary. Link to the issue if closed, otherwise the PR.
The fix works but I had to fall back to old (bad) behaviour in cases at the edge of valid target crs bounds. My method to compute target cellsize resulted in an error there.
https://github.com/locationtech/geotrellis/issues/3541
Overview
Proposed fix for a very important bug in reprojecting to lower resolution. I think it's better (more correct) than previous behaviour, but not sure yet if it is 100% accurate.
It seems to me that the downsampling now happens in the original projection system, and then it is warping to the new CRS. This will work fine if the low resolution pixel is rectangular in both projection systems.
Checklist
docs
guides update, if necessaryDemo
Optional. Screenshots/REPL
Notes
Optional. Ancillary topics, caveats, alternative strategies that didn't work out, anything else.
Closes #XXX