Evolution #365
ouvertSuivi Tests Preprocessing : fichier nc Rouen mode Bassin versant Températures Tmx Tmin
Description
Intitulé des fichiers :
tasAdjust_France_CNRM-CERFACS-CNRM-CM5_CNRM-ALADIN63_Historical_METEO-FRANCE_ADAMONT-France_SAFRAN_day_19510101-20051231.nc
tasmaxAdjust_France_CNRM-CERFACS-CNRM-CM5_CNRM-ALADIN63_Historical_METEO-FRANCE_ADAMONT-France_SAFRAN_day_19510101-20051231.nc
tasminAdjust_France_CNRM-CERFACS-CNRM-CM5_CNRM-ALADIN63_Historical_METEO-FRANCE_ADAMONT-France_SAFRAN_day_19510101-20051231.nc
Il s'agit des données historiques. les trois fichiers sont posés sur mediaserv dans /home/elejan/DriasRouen/
L'ipynb utilisé est checkNETCDF-final.ipynb sur une raspiB+ version Bulleyes.
Le traitement du fichier, donne l'erreur ci-dessous :
`"---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
Input In [14], in
80 print ('Measured variable and units : %s -> %s' % (varname[i], units[i]))
81 print ('{: 85 print ('file contents 1 :\n', netcdf_file.variables[varname[i]][0,:,0,0])
86 print ('file contents 2 :\n', netcdf_file.variables[varname[i]][34,:,0,0])
87 print ('file contents 3 :\n', netcdf_file.variables[varname[i]][93,:,0,0])
File src/netCDF4/netCDF4.pyx:4382, in netCDF4._netCDF4.Variable.getitem_()
File /home/callisto/.local/share/virtualenvs/JupyterLab-RHxiRMZV/lib/python3.9/site-packages/netCDF4/utils.py:335, in _StartCountStride(elem, shape, dimensions, grp, datashape, put, use_get_vars)
333 # make sure there are not too many dimensions in slice.
334 if len(elem) > nDims:
--> 335 raise ValueError("slicing expression exceeds the number of dimensions of the variable")
337 # Compute the dimensions of the start, count, stride and indices arrays.
338 # The number of elements in the first n dimensions corresponds to the
339 # number of times the _get method will be called.
340 sdim = []
ValueError: slicing expression exceeds the number of dimensions of the variable"`
L'affichage des étapes précédentes semble tout à fait correct :
`Absolute path/filename of input files to process : RouenDonnees/tasmaxAdjust_France_CNRM-CERFACS-CNRM-CM5_CNRM-ALADIN63_Historical_METEO-FRANCE_ADAMONT-France_SAFRAN_day_19510101-20051231.nc
Started at : 2023-02-19 16:26:35.044430
This program extracts first and last dates/grid nodes/Lat Lon/X Y/ variable and units of data for each file.
i = 3 ; j = 3
Lat min max : 49.3905834 49.5366064
Lon min max : 0.9602562 1.1771732
X min max : 500000 516000
Y min max : 2489000 2505000
Measured variable and units : tasmaxAdjust -> K
tasmaxAdjust ('time', 'j', 'i') (20089, 3, 3) float32
`