WSL/SLF GitLab Repository

Fixing the case where rounding errors make the isSameGeolocalization test...

Fixing the case where rounding errors make the isSameGeolocalization test fail, even though the two grids are basically the same Geolocalization.

Example:

the following test for two grids failed, even though it's clear that it's related to floating point rounding errors (see bold)

  • grid2D.getNx()==target.grid2D.getNx() ---> 486 == 486
  • grid2D.getNy()==target.grid2D.getNy() ---> 200 == 200
  • llcorner: Altitude -999 Lat/Long (-4°45'0.000000" , -12°15'0.000000") Lat/Long (-4.7500000000 , -12.2500000000) X/Y_coords (-2416423 , 11129371) Projection PROJ (3031) EPSG 3031
  • target.llcorner: Altitude -999 Lat/Long (-4°45'0.000000" , -12°15'0.000000") Lat/Long (-4.7500000000 , -12.2500000000) X/Y_coords (-2416423 , 11129371) Projection PROJ (3031) EPSG 3031
  • cellsize==target.cellsize ---> -999 != 5528.85
  • ur_lat==target.ur_lat ---> 5.20000000000000017764 != 5.19999980926513671875
  • ur_lon==target.ur_lon ---> 12.00000000000000177636 != 12.00000000000000000000

Merge request reports

Loading