Closed soxofaan closed 3 months ago
To add insult to injury, the tests were quite hard to debug:
and it turns out that the coordinate order of the y dimension is different: the actuals have descending y coords, while reference data have ascending y coords. This trips up numpy assert_allclose
making it claim that everything is different, while there is actually no difference
with 524709b the tests now fail with
TypeError: The DType <class 'numpy.FloatAbstractDType'> could not be promoted by <class 'numpy.dtype[bytes]'>. This means that no common DType exists for the given inputs. For example they cannot be stored in a single array unless the dtype is
object
. The full list of DTypes is: (<class 'numpy.dtype[bytes_]'>, <class 'numpy._FloatAbstractDType'>)
test_atmospheric_correction_constoverridenparams
passes again
In https://github.com/Open-EO/openeo-geopyspark-integrationtests/commit/b4dc2758064beff8bf54e4447686b88e5ef3cf2b I fixed the
compare_xarrays()
helper, which checked a lot less than it seemed: to compare the pixel values, it basically didnp.testing.assert_allclose(x, x)
which never fails of course :facepalm:Note that this bug has always been there since introducing
compare_xarrays
in 7b7b2dc47e1c0e25f8c522530bcd882463a51150Fixing the bug now makes
test_atmospheric_correction_constoverridenparams
fail