EOA-team / eodal

Earth Observation Data Analysis Library
https://eodal.readthedocs.io/en/latest/
GNU General Public License v3.0
93 stars 15 forks source link

Band.from_rasterio() check for Path or URL objects and raise and error depending on the status of USE_STAC #9

Open lukasValentin opened 2 years ago

lukasValentin commented 2 years ago

Currently E:earth_africa:dal does not check if the user passes a "real" file-system path or an URL when reading raster data using Band.from_rasterio() (same for the Band.read_pixels method). If, e.g., USE_STAC = True and a file-system path is passed, this raises an error not properly handled at the moment.

The idea would be to check for the status of the USE_STAC flag and check if the data type of the passed input dataset matches it.