Changeset 1548 in lmdz_wrf for trunk


Ignore:
Timestamp:
Apr 28, 2017, 8:13:58 PM (8 years ago)
Author:
lfita
Message:

Replacing error by warning on no-selection of slice for existant dimension-variables in 'compute_opersvarsfiles'

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/nc_var_tools.py

    r1547 r1548  
    73917391                if dimv != 'WRFtime':
    73927392                    odimv = objnc.variables[dimv]
     7393                    print fname + ': Lluis dictslice:', dictslice
     7394                    print fname + ': Lluis odimv:', odimv.dimensions
    73937395                    varslice, Dddv[dimn] = SliceVarDict(odimv, dictslice)
     7396                    print fname + ': Lluis varslice:', varslice
     7397                    print fname + ': Lluis Dddv:', Dddv
    73947398                    Ddv[dimn] = odimv[tuple(varslice)]
    73957399                    Dtdv[dimn] = odimv.dtype
     
    74437447                found = False
    74447448                if not gen.searchInlist(Dddv.keys(), dimn):
    7445                     print errormsg
     7449                    print warnmsg
    74467450                    print '  ' + fname + ": sliced variable has dimension '" + dimn+ \
    74477451                      "' but there is no slicing-dimension information"
    7448                     print "    add range for the dimension as '[dim]|[dimv]|[range]'"
    7449                     quit(-1)
    7450 
     7452                    print "    add range for the dimension as '[dim]|[dimv]|[range]'"
     7453                    print '    trying now tacking all values of the dimension-variable'
     7454                    print "    ", varn + "'s dimensions:", dimvarvals
     7455                    print '    provided slicing dimension-variables:', Dddv.keys()
     7456                    Dddv[dimn] = dimn
     7457                    #quit(-1)
    74517458        else:
    74527459        # Computing using results of previous computations
Note: See TracChangeset for help on using the changeset viewer.