There is a corner case not covered in georaster.merge_all():
Imagine you have some rasters you want to merge and crop by a ROI. One of the rasters is very close to the polygon, overlapping it or not, by less than the target resolution. In some cases, the footprints intersect but the result of the crop yields a raster with 0 height or width, which raises an exception in the next _reproject call (inside georaster._prepare_other_raster function).
This PR checks if tmp cropped image has 0 width or height and discards it if it does, allowing you to merge using the rest of the valid images.
There is a corner case not covered in
georaster.merge_all()
:Imagine you have some rasters you want to merge and crop by a ROI. One of the rasters is very close to the polygon, overlapping it or not, by less than the target resolution. In some cases, the footprints intersect but the result of the crop yields a raster with 0 height or width, which raises an exception in the next
_reproject
call (insidegeoraster._prepare_other_raster
function).This PR checks if tmp cropped image has 0 width or height and discards it if it does, allowing you to merge using the rest of the valid images.