Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoiding more numpy 2.0 deprecation warnings #3049

Merged
merged 3 commits into from
Jun 20, 2024

Conversation

eepeterson
Copy link
Contributor

@eepeterson eepeterson commented Jun 20, 2024

Description

Numpy 2.0 deprecates np.cross for 2D arrays which was used in the Polygon class. To address this we simply append a 0 to the points for the dimension perpendicular to the plane and take the only non-zero component of the cross product which is that last dimension.

Fixes # (issue)

Checklist

  • I have performed a self-review of my own code
  • I have run clang-format (version 15) on any C++ source files (if applicable)
  • I have followed the style guidelines for Python source files (if applicable)
  • I have made corresponding changes to the documentation (if applicable)
  • I have added tests that prove my fix is effective or that my feature works (if applicable)

@paulromano paulromano added this to the v0.15.0 milestone Jun 20, 2024
@paulromano paulromano enabled auto-merge (squash) June 20, 2024 17:32
@paulromano paulromano merged commit 4bd0b09 into openmc-dev:develop Jun 20, 2024
15 checks passed
church89 pushed a commit to openmsr/openmc that referenced this pull request Jul 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants