Bonjour,
J'essaie de visualiser un fichier grib avec matplotlib.
J'ai installé matplotlib, eccodes, cfgrib et ecmwflibs
1 2 3 4 5 6
| grib = xr.open_dataset(self.file, engine="cfgrib")
ds = grib.isel(step=0, heightAboveGround=0)
temperature = ds['dpt']
print(temperature.shape)
print(type(temperature)) |
Résultat :
1 2
| (601, 801)
<class 'xarray.core.dataarray.DataArray'> |
Mais quand je veut afficher les données graphiquement avec matplotlib, je fais temperature.plot(), j'ai l'erreur:
ECCODES ERROR : JPEG support not enabled. Please rebuild with -DENABLE_JPG=ON
Pourquoi il cherche le support jpeg, alors je passe une instruction de matplotlib?
comment résoudre le problème?
Merci,
Nico
Partager