qgis / QGIS

QGIS is a free, open source, cross platform (lin/win/mac) geographical information system (GIS)
https://qgis.org
GNU General Public License v2.0
10.52k stars 2.99k forks source link

Import of NetCDF fails upon order of variables #42552

Closed raphaeljolivet closed 3 years ago

raphaeljolivet commented 3 years ago

Qgis version : 3.18.0-Zürich

I struggled to import a NetCDF file as a mesh layer. I found that Qgis has strange and undocumented requirements for it.

The file in question :

I found first that QGis requires the dimensions to be in a specific order : time, y, x. To my knowledge, this does not corresponds to any convention.

Then, if the variables are in alphabetical order (gis, lat, lon, time, x, y ) the file imports correctly :

However, if the same file has different order of variables (time, x, y, lat, lon, gis) then :

I think this should be fixed and / or explained clearly in the documentation

I attach both files here : example-nc-files.zip

roya0045 commented 3 years ago

@PeterPetrik Would you know if such issues are related to MDAL or QGIS-specific?

PeterPetrik commented 3 years ago

Hi, this is definitely MDAL issue please let discuss there.

vcloarec commented 3 years ago

@raphaeljolivet Indeed, it is a MDAL issue that will be fixed. Can you use your data for testing in MDAL?