Bug in dem_builder if mem > 10000 due to GDAL
If configuring a memory > 10000, dem_builder, which use gdal_wrap command will fail silently (without aborting the process).
This is due to https://github.com/OSGeo/gdal/issues/1345: -wm option considers that for a number > 10000, memory is expressed in bytes, not MB.
There are error logs, but no failure:
2024-06-04T12:30:59.835 INFO:dem_builder.py::build_dem:+proj=utm +zone=31 +datum=WGS84 +units=m +no_defs
ERROR 5: GDALWarpOptions.Validate(): dfWarpMemoryLimit=16384 is unreasonably small.
dem_builder should be improved to better take into account memory parameter, and to better detect error cases.
Maybe using GDAL Python API would be better?