Skip to content

Commit

Permalink
all_updates_included_3
Browse files Browse the repository at this point in the history
  • Loading branch information
felicio93 committed May 31, 2024
1 parent 97fbb12 commit 002b487
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
1 change: 1 addition & 0 deletions ocsmesh/hfun/mesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,7 @@ def add_patch(

# TODO: Add pool input support like add_feature for performance

# pylint: disable=R0801
# TODO: Support other shapes - call buffer(1) on non polygons(?)
if not isinstance(multipolygon, (Polygon, MultiPolygon)):
raise TypeError(
Expand Down
1 change: 1 addition & 0 deletions ocsmesh/hfun/raster.py
Original file line number Diff line number Diff line change
Expand Up @@ -876,6 +876,7 @@ def add_patch(

# TODO: Add pool input support like add_feature for performance

# pylint: disable=R0801
# TODO: Support other shapes - call buffer(1) on non polygons(?)
if not isinstance(multipolygon, (Polygon, MultiPolygon)):
raise TypeError(
Expand Down
9 changes: 6 additions & 3 deletions ocsmesh/mesh/mesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -1531,9 +1531,12 @@ def area(self):
y = xy[:, 1]

elnode = self.mesh.elements.array()
x1 = x[elnode[:, 0]]; y1 = y[elnode[:, 0]]
x2 = x[elnode[:, 1]]; y2 = y[elnode[:, 1]]
x3 = x[elnode[:, 2]]; y3 = y[elnode[:, 2]]
x1 = x[elnode[:, 0]]
y1 = y[elnode[:, 0]]
x2 = x[elnode[:, 1]]
y2 = y[elnode[:, 1]]
x3 = x[elnode[:, 2]]
y3 = y[elnode[:, 2]]
if np.any(elnode.mask):
x4 = x[elnode[:, 3]]; y4 = y[elnode[:, 3]]
mask = elnode.mask[:, -1]
Expand Down

0 comments on commit 002b487

Please sign in to comment.