Changeset 1397 in lmdz_wrf for trunk/tools
- Timestamp:
- Dec 20, 2016, 5:41:09 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tools/generic_tools.py
r1396 r1397 10936 10936 10937 10937 wgt = np.where(dist <= maxdist, dist / inc, 0.) 10938 #print 'Lluis weights _______', sortdist[0:4] 10939 #for i in range(3): 10940 # print wgt[:,i] 10938 if np.sum(wgt) > 1.000001: 10939 wgt = np.where(dist <= maxdist, dist, 0.) 10940 inc = np.sum(wgt) 10941 wgt = np.where(wgt > 0., wgt/inc, 0.) 10942 Nvals = np.sum(wgt > 0.) 10943 10944 # print 'Lluis weights _______', sortdist[0:4],'max:',maxdist,'sum:',np.sum(wgt) 10945 # for i in range(3): 10946 # print wgt[:,i] 10941 10947 10942 10948 return wgt, Nvals, distpos
Note: See TracChangeset
for help on using the changeset viewer.