This diff moves the dem clipping and mosaicking functionality into its own class. This allows for users to give paths to their own DEM's (through a path to the footprints shapefile or geopackage). See #13.
evhrToaCLV.py
Added optional command-line argument --dem, user should supply a DEM footprints path
EvhrToA.py
Removed DEM-specific code from the class.
On initialization, if a dem footprints path was provided, the input DEM class will be the InputDem object, if not AsterSrtmDem (adapt-specific case)
InputDem.py
Implements basic validation of the existence of the DEM the shapefile is pointing to through opening the shapefile using ogr and getting the first path to the DEM.
Checks that that DEM path exists and gdal can open the DEM file.
Implements the clipping and mosaicking functionality previously in EvhrToA (without SRTM/ASTERGDEM specific logic)
AsterSrtmDem.py (adapt specific class)
Uses the shapefiles provided with the evhr source code
Performs latitude checking to determine which DEM source to use
EvhrToaCelery.py
Updated function and init args to match EvhrToA
Additional edits:
Outputs should not change if using SRTM/ASTER default method
Outside testing done by @mfrost2NCCS
Passes unit tests
Will need to communicate in documentation how users can create the needed footprints from a dem raster
Description
This diff moves the dem clipping and mosaicking functionality into its own class. This allows for users to give paths to their own DEM's (through a path to the footprints shapefile or geopackage). See #13.
evhrToaCLV.py
--dem
, user should supply a DEM footprints pathEvhrToA.py
InputDem.py
AsterSrtmDem.py (adapt specific class)
EvhrToaCelery.py
Additional edits: