For antimeridian-crossing scenes, the bbox calculation from shapely was incorrect, such that the bbox was both too large (e.g., spanning almost the entire globe), and didn't quite actually cover the scene (e.g., missing a bit of longitude along the AM). This fixes that, and rounds the values to the standard 6 decimal places.
is obviously wrong, because it spans nearly the entire longitude, from -179.7 to 180, but misses -180 to -179.7 -- so it both covers too much area (e.g, about 356 degrees too much!) and misses the 0.3 degrees to the east of the antimeridian. This bbox should have a SW lon coordinate that's like 178 and a NE lon coordinate that's like -178, which indicates that it actually does cross the AM, rather than spanning the entire globe.
Related issues
Description
For antimeridian-crossing scenes, the bbox calculation from shapely was incorrect, such that the bbox was both too large (e.g., spanning almost the entire globe), and didn't quite actually cover the scene (e.g., missing a bit of longitude along the AM). This fixes that, and rounds the values to the standard 6 decimal places.
For example, a bbox like
is obviously wrong, because it spans nearly the entire longitude, from -179.7 to 180, but misses -180 to -179.7 -- so it both covers too much area (e.g, about 356 degrees too much!) and misses the 0.3 degrees to the east of the antimeridian. This bbox should have a SW lon coordinate that's like 178 and a NE lon coordinate that's like -178, which indicates that it actually does cross the AM, rather than spanning the entire globe.
Checklist