Changeset 2050 in lmdz_wrf


Ignore:
Timestamp:
Aug 7, 2018, 7:12:34 PM (7 years ago)
Author:
lfita
Message:

Adding creation of CF-time variable for non-diaganostics pure file

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/get_WRFsounding-surface_data.bash

    r2049 r2050  
    416416      echo " " >> ${ofileins}
    417417      mv selvar_new.nc ${simsfcmapdiagsf}
     418      python ${pyHOME}/nc_var.py -o WRF_CFtime_creation -S 19491201000000,minutes    \
     419        -f ${simsfcdiagsf} -v time
     420      if test $? -ne 0; then
     421        echo ${errmsg}
     422        echo "  python failed!!"
     423        echo python ${pyHOME}/nc_var.py -o WRF_CFtime_creation -S 19491201000000,minutes \
     424        -f ${simsfcdiagsf} -v time
     425        exit
     426        rm ${simsfcdiagsf}
     427      fi
     428      echo "* creation of CF-time variable for file at sfc point: "${stlon}", "      \
     429        ${stlat} >> ${ofileins}
     430      echo python ${pyHOME}/nc_var.py -o WRF_CFtime_creation -S 19491201000000,minutes \
     431        -f ${simsfcdiagsf} -v time >> ${ofileins}
     432      echo " " >> ${ofileins}
    418433    fi
    419434    #Adding non-diagnostic variables
     
    559574    # If there was not diagnostics
    560575    if test ! -f ${simsfcdiagsf}; then
    561       dddv='Time@time'
     576      dddv='Time@Time'
    562577      selvars='LON,LAT,time'
    563578      python ${pyHOME}/nc_var.py -o selvar -S ${dddv} -f ${simsfcptf} -v ${selvars}
     
    576591      echo " " >> ${ofileins}
    577592      mv selvar_new.nc ${simsfcdiagsf}
     593      python ${pyHOME}/nc_var.py -o WRF_CFtime_creation -S 19491201000000,minutes    \
     594        -f ${simsfcdiagsf} -v time
     595      if test $? -ne 0; then
     596        echo ${errmsg}
     597        echo "  python failed!!"
     598        echo python ${pyHOME}/nc_var.py -o WRF_CFtime_creation -S 19491201000000,minutes \
     599        -f ${simsfcdiagsf} -v time
     600        exit
     601        rm ${simsfcdiagsf}
     602      fi
     603      echo "* creation of CF-time variable for file at sfc point: "${stlon}", "      \
     604        ${stlat} >> ${ofileins}
     605      echo python ${pyHOME}/nc_var.py -o WRF_CFtime_creation -S 19491201000000,minutes \
     606        -f ${simsfcdiagsf} -v time >> ${ofileins}
     607      echo " " >> ${ofileins}
    578608    fi
    579609    varsadd=`echo ${nondiagvs} | tr ':' ' '`
     
    724754      echo " " >> ${ofileins}
    725755      mv selvar_new.nc ${simsfcmapdiagsf}
     756      python ${pyHOME}/nc_var.py -o WRF_CFtime_creation -S 19491201000000,minutes    \
     757        -f ${simsfcdiagsf} -v time
     758      if test $? -ne 0; then
     759        echo ${errmsg}
     760        echo "  python failed!!"
     761        echo python ${pyHOME}/nc_var.py -o WRF_CFtime_creation -S 19491201000000,minutes \
     762        -f ${simsfcdiagsf} -v time
     763        exit
     764        rm ${simsfcdiagsf}
     765      fi
     766      echo "* creation of CF-time variable for file at sfc point: "${stlon}", "      \
     767        ${stlat} >> ${ofileins}
     768      echo python ${pyHOME}/nc_var.py -o WRF_CFtime_creation -S 19491201000000,minutes \
     769        -f ${simsfcdiagsf} -v time >> ${ofileins}
     770      echo " " >> ${ofileins}
    726771    fi
    727772
Note: See TracChangeset for help on using the changeset viewer.