KMarkert / servir-vic-training

Training materials for the VIC hydrologic model setup developed for the @SERVIR program
GNU General Public License v3.0
36 stars 32 forks source link

Got "Index Error: Index is out of bounds for axis 1" when running make_veg_lib.py by my own Data #30

Open mrezaka opened 3 years ago

mrezaka commented 3 years ago

Hi all I meet this error when running make_veg_lib.py for my own data, but when i run it for Nyando_basin Data (LAI & ALB & Basin_LC_IGBP) which are already in the zip file downloaded from GitHub, i don't get the error and veg.lib output forms completely ........................................................................................................................................................................................... python '/home/mrk/Documents/research/servir-vic-training-master/scripts/make_veg_lib.py' '/home/mrk/Documents/research/servir-vic-training-master/data/input/gis1/landcover_LC_IGBP.tif' '/home/mrk/Documents/research/servir-vic-training-master/data/ancillary/tiff_16un-LAI/new/calcu/' '/home/mrk/Documents/research/servir-vic-training-master/data/ancillary/tif-un16-ALB/test/' '/home/mrk/Documents/research/servir-vic-training-master/data/input/example/veg.lib' IGBP Traceback (most recent call last): File "/home/mrk/Documents/research/servir-vic-training-master/scripts/make_veg_lib.py", line 216, in main() File "/home/mrk/Documents/research/servir-vic-training-master/scripts/make_veg_lib.py", line 210, in main make_veg_lib(sys.argv[1],sys.argv[2],sys.argv[3],sys.argv[4],sys.argv[5]) File "/home/mrk/Documents/research/servir-vic-training-master/scripts/make_veg_lib.py", line 149, in make_veg_lib lai.append(np.nanmean(laiStep[clsidx])/1000.)

IndexError: index 3576 is out of bounds for axis 1 with size 3571 ...............................................................................................................................................................................................

could you please help me to know what is the problem with my "LAI & ALB" Data that this error occurs? thanks.

motasemmtsm commented 1 year ago

I got the same error, does anyone knows the solution to this