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

add export_model_xml arguments to Model.plot_geometry and Model.calculate_volumes #3190

Merged
merged 2 commits into from
Nov 9, 2024

Conversation

nplinden
Copy link
Contributor

@nplinden nplinden commented Nov 8, 2024

Description

This adds an export_model_xml argument to Model.plot_geometry and Model.calculate_volumes, for coherence with the Model.run method.

The implementation mimics that of Model.run and the new argument defaults to True.

Previously running these methods in the same script resulted in populating the working directory with model.xml as well as the geometry/materials/settings/plots/tallies.xml, making things ambiguous.

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)

Copy link
Contributor

@paulromano paulromano left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @nplinden! I made one small update to ensure that if you pass path='other_name.xml', it gets passed to plot_geomtery and calculate_volumes accordingly.

@paulromano paulromano enabled auto-merge (squash) November 9, 2024 17:05
@paulromano paulromano merged commit c05132c into openmc-dev:develop Nov 9, 2024
15 checks passed
magnoxemo pushed a commit to magnoxemo/openmc that referenced this pull request Nov 22, 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