Changeset 2728 in lmdz_wrf for trunk/tools/generic_tools.py


Ignore:
Timestamp:
Oct 18, 2019, 5:41:56 PM (5 years ago)
Author:
lfita
Message:

Fixing too small values and adding last value in `pretty_int'

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/generic_tools.py

    r2720 r2728  
    1144911449#    print 'closestint:',closestint,'Ibeg:',Ibeg,'val:',val,'dval:',dval
    1145011450
    11451     while val < maxv:
     11451    while val <= maxv:
    1145211452        values.append(val)
    1145311453        val = val + dval
     11454
     11455    values = np.where(np.abs(values) < dval*10.e-5, 0., values)
    1145411456
    1145511457    return np.array(values, dtype=np.float)
Note: See TracChangeset for help on using the changeset viewer.