Skip to content

Commit

Permalink
[geom,field] Update variable/value attrs
Browse files Browse the repository at this point in the history
  • Loading branch information
holl- committed Mar 11, 2024
1 parent a2d774f commit ab75193
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions phi/field/_field.py
Original file line number Diff line number Diff line change
Expand Up @@ -540,10 +540,10 @@ def dimension(self, name: str):
return BoundDim(self, name)

def __value_attrs__(self):
return '_values', '_boundary'
return '_values',

def __variable_attrs__(self):
return '_values', '_geometry'
return '_values', '_geometry', '_boundary'

def __expand__(self, dims: Shape, **kwargs) -> 'Field':
return self.with_values(expand(self.values, dims, **kwargs))
Expand Down
4 changes: 3 additions & 1 deletion phi/geom/_mesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,11 @@ def __init__(self, vertices: Graph,
# e_face =

def __variable_attrs__(self):
return ()
return '_vertices', '_center', '_volume', '_faces', '_valid_mask', '_face_vertices', '_relative_face_distance', '_neighbor_offsets'

def __value_attrs__(self):
return '_vertices',

@property
def shape(self) -> Shape:
return shape(self._polygons).non_spatial & channel(self._vertices)
Expand Down

0 comments on commit ab75193

Please sign in to comment.