Closed stevevdw28 closed 1 year ago
Hi, This error was due to the way we read the variables from the netCDF files where we expect the meteo variable to be the last one. I just release Lisvap v1.2.7 which corrects this issue allowing the variables to be in any order inside the netCDF.
I need help to calculate the variables of evapo(transpi)ration. I am testing the python code using netcdf files as input. I have an error that keeps coming back when I run LISVAP using this python command src/lisvap1.py settings_tpl.xml -v -t which is as follows:
Traceback (most recent call last): File "/home/elic/stevevdw/Documents/lisflood-lisvap/src/lisvap1.py", line 97, in
sys.exit(main())
File "/home/elic/stevevdw/Documents/lisflood-lisvap/src/lisvap1.py", line 93, in main
lisvapexe(lissettings)
File "/home/elic/stevevdw/Documents/lisflood-lisvap/src/lisvap1.py", line 65, in lisvapexe
dynfmw.run()
File "/opt/easybuild/soft/2021b/software/PCRaster/4.3.3-GCCcore-11.2.0-Python-3.9.6/python/pcraster/framework/dynamicFramework.py", line 63, in run
self._runInitial()
File "/opt/easybuild/soft/2021b/software/PCRaster/4.3.3-GCCcore-11.2.0-Python-3.9.6/python/pcraster/framework/frameworkBase.py", line 354, in _runInitial
self._userModel().initial()
File "/home/elic/stevevdw/Documents/lisflood-lisvap/src/lisvap/lisvapinitial.py", line 84, in initial
self.misc_module.initial()
File "/home/elic/stevevdw/Documents/lisflood-lisvap/src/lisvap/hydrological/miscinitial.py", line 73, in initial
self.var.Dem = loadmap('Dem')
File "/home/elic/stevevdw/Documents/lisflood-lisvap/src/lisvap/utils/readers.py", line 149, in loadmap
mapnp = nf1.variables[value][cut2:cut3, cut0:cut1]
File "src/netCDF4/_netCDF4.pyx", line 4382, in netCDF4._netCDF4.Variable.getitem
File "/opt/easybuild/soft/2021b/software/ELIC_Python/1-foss-2021b/lib/python3.9/site-packages/netCDF4/utils.py", line 335, in _StartCountStride
raise ValueError("slicing expression exceeds the number of dimensions of the variable")
ValueError: slicing expression exceeds the number of dimensions of the variable
I don't understand this error given my files. I allow myself to share them with you via the following link: LISVAP_inputs.zip. All files are named according to model conventions.