source:
issm/oecreview/Archive/25834-26739/ISSM-26638-26639.diff@
26740
Last change on this file since 26740 was 26740, checked in by , 3 years ago | |
---|---|
File size: 1.7 KB |
-
../trunk-jpl/test/NightlyRun/test257.py
23 23 # Generate basin IDs for 3 basins 24 24 idbasin = np.zeros((md.mesh.numberofelements,)) 25 25 iid1 = np.where(md.mesh.y >= 2. / 3. * ymax)[0] 26 iid2 = intersect(np.where(md.mesh.y < 2. / 3. * ymax)[0], np.where(md.mesh.x >= 1. / 3. * xmax)[0])27 iid3 = intersect(np.where(md.mesh.y < 2. / 3. * ymax)[0], np.where(md.mesh.x < 1. / 3. * xmax)[0])26 iid2 = np.where(np.logical_and(md.mesh.y < 2. / 3. * ymax, md.mesh.x >= 1. / 3. * xmax))[0] 27 iid3 = np.where(np.logical_and(md.mesh.y < 2. / 3. * ymax, md.mesh.x < 1. / 3. * xmax))[0] 28 28 for ii in range(md.mesh.numberofelements): 29 29 for vertex in range(3): 30 30 if md.mesh.elements[ii][vertex] - 1 in iid1: # one vertex in basin 1; NOTE: offset because of 1-based vertex indexing -
../trunk-jpl/test/NightlyRun/test812.py
2 2 import numpy as np 3 3 from socket import gethostname 4 4 from model import * 5 from parameterize import * 6 from setflowequation import * 7 from setmask import * 8 from solve import * 9 from triangle import * 5 from parameterize import parameterize 6 from setflowequation import setflowequation 7 from setmask import setmask 8 from solve import solve 9 from triangle import triangle 10 from SetMLHOBC import SetMLHOBC 10 11 11 12 md = triangle(model(), '../Exp/Square.exp', 50000.) 12 13 md = setmask(md, 'all', '')
Note:
See TracBrowser
for help on using the repository browser.