Changeset 2044 in lmdz_wrf


Ignore:
Timestamp:
Aug 7, 2018, 6:07:51 PM (7 years ago)
Author:
lfita
Message:

Adding 'None' cases in ifs

File:
1 edited

Legend:

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

    r2036 r2044  
    716716
    717717  # Sounding
    718   if test ! ${sndid} = 'None'; then
     718  if test ! ${sndid} = 'None' && test ! ${wrfsnddiags} = 'None'; then
    719719    stid=${sndid}
    720720    simsndptf=${odir}'/simout_vars_sndpt_'${stid}'_'${expl}'_'${fdate}'.nc'
     
    726726
    727727  # Surface
    728   if test ! ${sfcid} = 'None'; then
     728  if test ! ${sfcid} = 'None'  && test ! ${wrfsfcdiags} = 'None' ||                  \
     729    test ! ${wrfsfcnodiags} = 'None'; then
    729730    stid=${sfcid}
    730731    simsfcptf=${odir}'/simout_vars_sfcpt_'${stid}'_'${expl}'_'${fdate}'.nc'
     
    736737
    737738  # Surface maps
    738   simsfcmapf=${odir}'/simout_vars_sfcmap_'${expl}'_'${fdate}'.nc'
    739   simsfcmapdiagsf=${odir}'/simout_sfcmapdiags_'${expl}'_'${fdate}'.nc'
    740 
    741   fvals=${infilen}'#'${wrfsfcdiags}'#'${wrfsfcnodiags}
    742   get_WRFsfc2D_data ${fvals}
     739  if test ! ${wrfsfcdiags} = 'None' || test ! ${wrfsfcnodiags} = 'None'; then
     740    simsfcmapf=${odir}'/simout_vars_sfcmap_'${expl}'_'${fdate}'.nc'
     741    simsfcmapdiagsf=${odir}'/simout_sfcmapdiags_'${expl}'_'${fdate}'.nc'
     742
     743    fvals=${infilen}'#'${wrfsfcdiags}'#'${wrfsfcnodiags}
     744    get_WRFsfc2D_data ${fvals}
     745  fi
    743746
    744747  # cdx snd
    745   if test ! ${sndid} = 'None'; then
     748  if test ! ${sndid} = 'None' && test ! ${wrfcdxdiags} = 'None' ||                   \
     749   test ! ${wrfcdxnodiags} = 'None'; then
    746750    stid=${sndid}
    747751    simsfcptf=${odir}'/simcdx_vars_sfcpt_'${stid}'_'${expl}'_'${fdate}'.nc'
     
    754758
    755759  # cdx Surface
    756   if test ! ${sfcid} = 'None'; then
     760  if test ! ${sfcid} = 'None' && test ! ${wrfcdxdiags} = 'None' ||                   \
     761   test ! ${wrfcdxnodiags} = 'None'; then
    757762    stid=${sfcid}
    758763    simsfcptf=${odir}'/simcdx_vars_sfcpt_'${stid}'_'${expl}'_'${fdate}'.nc'
     
    765770
    766771  # cdx Surface maps
    767   simsfcmapf=${odir}'/simcdx_vars_sfcmap_'${expl}'_'${fdate}'.nc'
    768   simsfcmapdiagsf=${odir}'/simcdx_sfcmapdiags_'${expl}'_'${fdate}'.nc'
    769 
    770   fvals=${infilen}'#'${wrfcdxdiags}'#'${wrfcdxnodiags}
    771   get_WRFCDXsfc2D_data ${fvals}
     772  if test ! ${wrfcdxdiags} = 'None' || test ! ${wrfcdxnodiags} = 'None'; then
     773    simsfcmapf=${odir}'/simcdx_vars_sfcmap_'${expl}'_'${fdate}'.nc'
     774    simsfcmapdiagsf=${odir}'/simcdx_sfcmapdiags_'${expl}'_'${fdate}'.nc'
     775
     776    fvals=${infilen}'#'${wrfcdxdiags}'#'${wrfcdxnodiags}
     777    get_WRFCDXsfc2D_data ${fvals}
     778  fi
    772779
    773780fi
Note: See TracChangeset for help on using the changeset viewer.