o2r-project / geoextent

Python library for extrating geospatial extent of files and directories with multiple data formats
https://o2r.info/geoextent/
MIT License
1 stars 4 forks source link

Add support for NetCDF #24

Closed nuest closed 3 years ago

nuest commented 4 years ago

Test file: https://github.com/o2r-project/geoextent/blob/master/tests/testdata/ECMWF_ERA-40_subset1.nc

nuest commented 3 years ago

Library (if GDAL does not just work): https://pypi.org/project/netCDF4/ Docs: https://unidata.github.io/netcdf4-python/netCDF4/index.html

SbastianGarzon commented 3 years ago

This could be relevant : https://gdal.org/drivers/raster/netcdf.html#georeference _"There is no universal way of storing georeferencing in NetCDF files. The driver first tries to follow the CF-1 Convention from UNIDATA looking for the Metadata named “grid_mapping”. If “gridmapping” is not present, the driver will try to find an lat/lon grid array to set geotransform array. The NetCDF driver verifies that the Lat/Lon array is equally space."

GDAL is already trying to extract the CRS. This means that since #99, NETCDF files are supported (BBOX).

SbastianGarzon commented 3 years ago

Issue closed (spatial extent extraction), extraction of the temporal extent will be handle by #123