nasa / RHEAS

Regional Hydrologic Extremes Assessment System
MIT License
73 stars 54 forks source link

NCEP Min/Max Temperature Error #60

Closed wle0001 closed 7 years ago

wle0001 commented 7 years ago

Error: Tmax is less than Tmin in weather data file.
File: WEATH001.WTH Line: 7 Error key: IPWTH

Any ideas? This is when using NCEP met data.

dssat.log.txt test_ke.conf.txt

kandread commented 7 years ago

I was able to reproduce this, but something is off. I examined all the WTH files that are used as inputs to DSSAT and none has a Tmax less than Tmin. cd /home/rheas/RHEAS/tmpUtLiDq for d in *;do cd -- $d;for f in *.WTH;do awk 'NR>5{if($3<$4){print$0}}' $f;done;cd ..;done should return nothing, but if Tmax (3rd column) was less than Tmin (4th column), it would have returned that row. One issue is that NCEP temperature is in Kelvins, which shouldn't happen. When I manually converted them to Celsius, the error disappeared. I will go ahead and rebuild the NCEP data tables, and check whether the units are corrected.