geotrellis / maml

Map Algebra Modeling Language: It's what we and whales are.
https://geotrellis.github.io/maml/
Apache License 2.0
16 stars 10 forks source link

Assume correct extents in binary ops to avoid floating point errors #91

Closed moradology closed 5 years ago

moradology commented 5 years ago

Floating point math can lead to situations in which combined GridExtents fail a requirement that checks correspondence between CellSize+Extent on the one hand and pixel cols/rows on the other.

This is likely desirable behavior if it happens only when bad data has been passed into MAML. It is very undesirable if it occurs in certain edge cases that are able to compute results properly, as happens whenever the Extent/CellSize ratio becomes too large and floating point arithmetic's approximations fail us.

The upshot of this is that we get slightly less guarded execution but avoid false positive errors