Skip to content

Commit

Permalink
Remove horizontal coordinates when ditching thin prisms (#394)
Browse files Browse the repository at this point in the history
Removing the unused horizontal coordinates when discarding thin prisms
of a prism layer. Since we only check the vertical boundaries, we can
exclude the horizontal ones.
  • Loading branch information
santisoler authored Mar 14, 2023
1 parent 9c3d5d9 commit 4d7b356
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion harmonica/_forward/prism_layer.py
Original file line number Diff line number Diff line change
Expand Up @@ -519,7 +519,7 @@ def _discard_thin_prisms(
A copy of the ``density`` array that doesn't include the density values
for thin prisms.
"""
west, east, south, north, bottom, top = tuple(prisms[:, i] for i in range(6))
bottom, top = prisms[:, -2], prisms[:, -1]
# Mark prisms with thickness < threshold as null prisms
thickness = top - bottom
null_prisms = thickness < thickness_threshold
Expand Down

0 comments on commit 4d7b356

Please sign in to comment.