bwinkel / pycraf

pycraf is a package that provides functions and procedures for various tasks in spectrum-management compatibility studies.
35 stars 15 forks source link

SRTM handling when tiles are missing #9

Closed bwinkel closed 5 years ago

bwinkel commented 5 years ago

At the moment, pycraf raises an exception, if an (SRTM) ".hgt" file is missing, e.g.:

OSError: No hgt-file found for (11d, 60d), was looking for N60E011.hgt
in directory: ...

It would be better to only raise a warning and set the missing tile's data to zeros, because for some regions, with a lot of sea in the vicinity, tiles are not available at all (would be zero anyway).

bwinkel commented 5 years ago

It turns out, that pycraf was setting tiles to zero already, if (and only if) no tile existed (on the two download servers). Nevertheless, if would still be good to raise a warning for cases where the tile just not exists on disk.