UW-Hydro / tonic

A pre/post processing toolbox for hydrologic models
MIT License
20 stars 34 forks source link

VIC 4.2 parameter file data formatting read error Tonic #74

Closed Saadi4469 closed 4 years ago

Saadi4469 commented 4 years ago

Hello, I am trying VIC 4.2.d parameter files to NetCDF using Tonic, but I am getting a data-type/formatting error while reading the vegetation parameter file. How can I please fix this issue?

File "~\tonic\models\vic\grid_params.py", line 1503, in veg
    gridcel[cell], nveg[cell] = np.array(line).astype(int)

ValueError: invalid literal for int() with base 10: ''
266566 3
    1 0.524590 0.10 0.05 1.00 0.45 5.00 0.0
      5.175 5.175 5.175 5.175 5.175 5.175 5.175 5.175 5.175 5.175 5.175 5.175
    6 0.311475 0.10 0.10 1.00 0.65 1.00 0.25
      0.087 0.112 0.125 0.263 0.812 2.338 3.425 2.963 2.550 1.600 0.375 0.125
    7 0.163934 0.10 0.10 1.00 0.65 1.00 0.25
      0.275 0.300 0.350 0.650 1.112 1.900 2.050 1.775 1.262 0.625 0.388 0.312
266568 3
    1 0.625000 0.10 0.05 1.00 0.45 5.00 0.50
      5.175 5.175 5.175 5.175 5.175 5.175 5.175 5.175 5.175 5.175 5.175 5.175
    6 0.296875 0.10 0.10 1.00 0.65 1.00 0.25
      0.087 0.112 0.125 0.263 0.812 2.338 3.425 2.963 2.550 1.600 0.375 0.125
    7 0.078125 0.10 0.10 1.00 0.65 1.00 0.25
      0.275 0.300 0.350 0.650 1.112 1.900 2.050 1.775 1.262 0.625 0.388 0.312

subset_vegetation.params.txt