Changeset 26391


Ignore:
Timestamp:
08/12/21 18:02:48 (4 years ago)
Author:
schlegel
Message:

CHG: matice can handle rheology_B of python len 1 or more now

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/m/classes/matice.py

    r26358 r26391  
    137137        WriteData(fid, prefix, 'object', self, 'class', 'materials', 'fieldname', 'thermal_exchange_velocity', 'format', 'Double')
    138138        # NOTE: We first have to check if we have a NumPy array here
    139         if ((len(np.shape(self.rheology_B)) == 1 and (np.shape(self.rheology_B)[0] == md.mesh.numberofvertices or np.shape(self.rheology_B)[0] == md.mesh.numberofvertices + 1)) or (len(np.shape(self.rheology_B)) == 2 and np.shape(self.rheology_B)[0] == md.mesh.numberofelements and np.shape(self.rheology_B)[1] > 1)):
     139        if (((np.shape(self.rheology_B)[0] == md.mesh.numberofvertices) or (np.shape(self.rheology_B)[0] == md.mesh.numberofvertices + 1)) or ((len(np.shape(self.rheology_B)) == 2) and (np.shape(self.rheology_B)[0] == md.mesh.numberofelements) and (np.shape(self.rheology_B)[1] > 1))):
    140140            mattype = 1
    141141            tsl = md.mesh.numberofvertices
Note: See TracChangeset for help on using the changeset viewer.