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 munkm feedback to JOSS paper #649

Open
wants to merge 9 commits into
base: joss_submit
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
212 changes: 212 additions & 0 deletions inst/paper.bib
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ @techreport{Bates:2022
title = {The MCNPTools Package: Installation and Use},
institution = {Los Alamos National Laboratory},
DOI = {10.2172/1884737},
number = {LA-UR-22-28935},
url = {https://www.osti.gov/biblio/1884737},
year = {2022},
type = {Report}
Expand All @@ -100,3 +101,214 @@ @techreport{Campbell:2021
}


@misc{Scopatz:2012,
author = {Scopatz, Anthony and Romano, Paul K. and Wilson, Paul P. H. and Huff, Kathryn D.},
title = {PyNE: Python for Nuclear Engineering},
publisher = {American Nuclear Society},
volume = {107},
pages = {985-987},
month = {November 11-15},
year = {2012},
type = {Conference Paper}
}

@software{rodionov_mckit_2024,
title = {mckit},
url = {https://github.com/MC-kit/mckit},
version = {0.8.3},
author = {Rodionov, Roman and Portnov, Dmitri},
date = {2024},
}

@software{travleev_numjuggler_2022,
title = {numjuggler},
url = {https://github.com/travleev/numjuggler},
version = {2.42.36},
date = {2022},
author = {Travleev, Anton and Previti, Alberto and Portnov, Dmitri},
}

@software{mariano_mcnp_2022,
title = {{MCNP} Input Reader},
url = {https://github.com/ENEA-Fusion-Neutronics/MCNP-Input-Reader},
version = {0.2.1},
author = {Mariano, Giovanni},
date = {2022},
keywords = {read input},
}

@software{laghi_mctools_2023,
title = {mctools},
url = {https://github.com/dodu94/mctools},
author = {Laghi, Davide},
date = {2023},
}

@software{batkov_mc-tools_2024,
title = {mc-tools},
url = {https://github.com/kbat/mc-tools},
version = {1.0.post1},
author = {Batkov, Konstantin and Borghi, Nicolò and Furutaka, Kazuyoshi and Ansell, Stuart and Vezhlev, Egor},
date = {2024-12-20},
}

@software{pacific_northwest_national_laboratory_cardsharpformcnp_2025,
title = {{CardSharpForMCNP}},
url = {https://github.com/pnnl/CardSharpForMCNP},
version = {1.4.2},
author = {{Pacific Northwest National Laboratory}},
date = {2025},
}

@software{hagen_wig_2021,
title = {wig},
url = {https://github.com/alexhagen/wig},
author = {Hagen, Alex},
date = {2021-04},
}

@inproceedings{persaud_python-based_2024,
title = {Python-based software tools for {MCNP}},
url = {https://doi.org/10.1109/NSS/MIC/RTSD57108.2024.10655039},
doi = {10.1109/NSS/MIC/RTSD57108.2024.10655039},
pages = {1--1},
booktitle = {2024 {IEEE} Nuclear Science Symposium ({NSS}), Medical Imaging Conference ({MIC}) and Room Temperature Semiconductor Detector Conference ({RTSD})},
author = {Persaud, A. and Unzueta, M. Ayllon and Surry, E. K. and Parsons, A. M.},
date = {2024},
keywords = {Data visualization, Feature extraction, Geometry, Microwave integrated circuits, Monte Carlo methods, Semiconductor detectors, Writing},
}

@software{marcinkevicius_npp_mcnp_plugin_2025,
title = {{NPP}\_MCNP\_Plugin},
url = {https://github.com/kordusas/npp_mcnp_plugin},
author = {Marcinkevicius, Benjaminas},
date = {2025},
keywords = {syntax highlighter},
}

@article{harb_novel_2023,
title = {A Novel Algorithm for {CAD} to {CSG} Conversion in {McCAD}},
volume = {4},
rights = {https://creativecommons.org/licenses/by/4.0/},
issn = {2673-4362},
url = {https://www.mdpi.com/2673-4362/4/2/31},
doi = {10.3390/jne4020031},
abstract = {Modeling and simulation lie at the heart of the design process of any nuclear application. An accurate representation of the radiation environment ensures not only the feasibility of new technologies, but it also aids in operation, maintenance, and even decommissioning. With increasingly complex designs, high-fidelity models have become a necessity for design maturity. {McCAD} has been under development for many years at Karlsruhe Institute of Technology ({KIT}) to facilitate the process of generating suitable models for nuclear analyses. In this paper, an overview of the major advances in the new version of the code is presented. A novel conversion algorithm has proven to be robust in significantly reducing the processing time to generate radiation transport models, making it easier to iterate on design details. A first-of-a-kind capability to generate hierarchical void cells is also discussed with preliminary analysis showing performance gains for particle tracking.},
pages = {436--447},
number = {2},
journaltitle = {Journal of Nuclear Engineering},
shortjournal = {{JNE}},
author = {Harb, Moataz and Leichtle, Dieter and Fischer, Ulrich},
urldate = {2025-02-03},
date = {2023-06-15},
langid = {english},
file = {Full Text:C\:\\Users\\nasag\\Zotero\\storage\\MSEZ3L84\\Harb et al. - 2023 - A Novel Algorithm for CAD to CSG Conversion in McC.pdf:application/pdf},
}

@software{romano_mcnp_2024,
title = {{MCNP} Conversion tools for {OpenMC}},
url = {https://github.com/openmc-dev/openmc_mcnp_adapter},
author = {Romano, Paul and Li, Kaiwen and Shriwise, Patrick and Valderrama, Juan},
date = {2024},
keywords = {conversions, read input},
}

@software{shimwell_neutronics_2024,
title = {Neutronics Material Maker},
url = {https://github.com/fusion-energy/neutronics_material_maker},
version = {1.2.1},
author = {Shimwell, Jonathan and Billingsley, John and Buendia, Coronel and {Neutronics Material Material Contributors}},
date = {2024},
keywords = {input templater},
}

@software{repositony_vscode_mcnp_2024,
title = {vscode\_mcnp},
url = {https://github.com/repositony/vscode_mcnp},
author = {{Repositony}},
date = {2024},
keywords = {syntax highlighter},
}

@software{turkoglu_mcnp-syntax-highlighting_2018,
title = {{MCNP}-syntax-highlighting},
url = {https://github.com/danyalturkoglu/MCNP-syntax-highlighting},
author = {Turkoglu, Danyal},
date = {2018},
keywords = {syntax highlighter},
}

@software{mancusi_t4_geom_convert_2024,
title = {t4\_geom\_convert},
url = {https://github.com/arekfu/t4_geom_convert},
version = {1.1.2},
author = {Mancusi, Davide},
date = {2024},
keywords = {conversions, converter, read input},
}

@software{pease_pymcnp_2025,
title = {{PyMCNP}},
url = {https://github.com/FSIBT/PyMCNP},
author = {Pease, Devin and Ayllon Unzueta, Mauricio and Surry, Emily and Persaud, Arun},
date = {2025},
keywords = {input {API}},
}

@software{portnov_map-stp_2024,
title = {map-stp},
url = {https://github.com/MC-kit/map-stp},
author = {Portnov, Dimitri},
date = {2024},
keywords = {input templater},
}

@software{hung_mcnp6-hpge_detector_simulation_2023,
title = {{MCNP}6-{HPGE}\_Detector\_Simulation},
url = {https://github.com/hungbt1908/MCNP6-HPGE_Detector_Simulation},
author = {Hung, Bui Tien},
date = {2023},
keywords = {specific problem automation},
}

@software{galdon_bemp_thesis_2024,
title = {{BEMP}\_Thesis},
url = {https://github.com/mgaldon17/BEMP_Thesis},
version = {1.0.0},
author = {Galdon, Manuel},
date = {2024},
keywords = {specific problem automation},
}

@software{niess_gdnp_2018,
title = {{GDNP}},
url = {https://github.com/niess/gdnp},
author = {{niess}},
date = {2018},
keywords = {input templater},
}

@software{richet_funz_2023,
title = {Funz Plugin-{MCNP}},
url = {https://github.com/Funz/plugin-MCNP},
version = {1.16-0},
author = {Richet, Yann},
date = {2023},
keywords = {input templater},
}

@software{ikarino_mcnp_2021,
title = {{MCNP} Input Generator},
url = {https://github.com/ikarino/mcnp_input_generator},
author = {{ikarino}},
date = {2021},
keywords = {input templater},
}

@software{park_rodcal-mcnp_2021,
title = {rodcal-mcnp},
url = {https://github.com/patrickpark910/rodcal-mcnp},
author = {Park, Patrick},
date = {2021},
keywords = {specific problem automation},
}
68 changes: 65 additions & 3 deletions inst/paper.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,13 @@ like the Workflow Template and Toolkit System (WATTS) [@Romano:2022].
This though requires the user to create a template from the set of problems they plan to model.
This would be well suited for a sensitivity study where many very similar simulations are run,
but not for making large edits to an input file or making a single problem from scratch.
PyNE: the Nuclear Engineering Toolkit offers some similar capabilities for input generation.
Copy link
Collaborator

Choose a reason for hiding this comment

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

Should we move this sentence to the following paragraph?


PyNE can create MCNP input files for specific features and extract some data from MCNP output files.
However, its full capabilities extend far beyond interfacing with MCNP.
PyNE can simplify material creations, analyses of cross section data,
transmutations of complex systems, and interfacing with other common nuclear engineering software and data formats [@scopatz:2012].
Copy link
Collaborator

Choose a reason for hiding this comment

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

References appear to be case-sensitive in markdown. Bibliography uses capitalized @Scopatz.

PyNE is an excellent companion tool to MontePy.

All of these previous solutions were incomplete in one way or another.
Neither were able to read in a previous MCNP input file and edit it in a general manner.
Expand All @@ -135,8 +142,8 @@ as opposed to manual editing of the XML input files.

Ideally this object-oriented interface should be in Python as it is such a prolific language,
especially among novice and intermediate programmers.
One library does exist, MCNPy.
It is a Python wrapper for a java engine that can read, edit, and write MCNP input files.
A few such libraries do exist: MCNPy, mckit, and others discussed later.
MCNPy is a Python wrapper for a java engine that can read, edit, and write MCNP input files.
It can "understand" MCNP inputs,
or as the authors put it,
it has a "metamodel" for MCNP [@Kowal:2023].
Expand All @@ -148,10 +155,62 @@ It does not appear that MCNPy has any automated testing suite at this time,
and so there is no guarantee that it will actually perform the functions it claims to.
In addition it imposes additional formatting requirements on an input file that is read,
beyond what MCNP requires [@Kulesza:2022].
Mckit on the other hand is written primarily in python, and does use automated testing.
Unfortunately the existing documentation is difficult to acces, incomplete, and primarily in russian.
It was difficult to assess the state of this project due to this.
It appeared that mckit is more of a functional programming style library,
rather than an object-oriented programming style [@rodionov_mckit_2024].
MontePy provides all of these listed capabilities,
while also being written purely in Python, and avoiding this barrier to forming a thriving
open source community.

##### TODO PyNE, mckit
Copy link
Collaborator

Choose a reason for hiding this comment

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

Remove PyNE from todo


The authors did try to find as many Open Source Python libraries that had at least some overlap with MontePy.
Copy link
Collaborator

Choose a reason for hiding this comment

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

The authors did try

sounds a little weird.

as many Open Source Python libraries that

as many....as possible?

Maybe:

The authors attempted to find as many open-source Python libraries which overlapped MontePy's capabilities as possible.

This was not an exhaustive seach, but should cover many such libraries.
Given the number of libraries found the following lists will simply be an attempt to categorize these libraries.

The first group of libraries are those which attempt to have a read, edit, write capability for MCNP input files.
These all do not fully parse the inputs as they do not use context-free parsers,
and are generally feature limited, and may lack sufficient documentation.
These libaries are:

* numjuggler [@travleev_numjuggler_2022]
* MCNP Input Reader [@mariano_mcnp_2022]
* mctools [@laghi_mctools_2023]
* mc-tools [@batkov_mc-tools_2024]
* PyMCNP [@persaud_python-based_2024]

There are even more tools that specialize in input templating and generation.
These are clearly not complete alternatives as they lack the ability to read MCNP input files.
These libraries are:

* CardSharpForMCNP [@pacific_northwest_national_laboratory_cardsharpformcnp_2025]
* wig [@hagen_wig_2021]
* Plugin-MCNP [for Funz] [@richet_funz_2023]
* GDNP [@niess_gdnp_2018]
* map-stp [@portnov_map-stp_2024]
* MCNP Input Generator [@ikarino_mcnp_2021]
* Neutronics Material Maker [@shimwell_neutronics_2024]

There are also libraries that specialize in parsing an MCNP input file in order to convert the model
to be an input for another program:

* MCNP Conversion tools for OpenMC [@romano_mcnp_2024]
* t4\_geom\_convert [@mancusi_t4_geom_convert_2024]

There are also libraries that have to parse MCNP inputs to some extent as they provide MCNP syntax highlighting support for various text editors:

* MCNP-syntax-highlighting [@turkoglu_mcnp-syntax-highlighting_2018]
* NPP\_MCNP\_Plugin [@marcinkevicius_npp_mcnp_plugin_2025]
* vscode\_mcnp [@repositony_vscode_mcnp_2024]

Finally there are the libraries that have been purpose built for working with and automating a specific type of MCNP models:

* BEMP\_Thesis [@galdon_bemp_thesis_2024]
* MCNP6-HPGe_Detector_simulation [@hung_mcnp6-hpge_detector_simulation_2023]
* rodcal-mcnp [@park_rodcal-mcnp_2021]

MontePy is currently targeting two primary communities.
First, Nuclear Engineers with moderate Python experience as a user base.
The goal is to get these users to use the interface to remove the tedium from
Expand All @@ -174,7 +233,7 @@ This tool is a prime example of a real-life case where MontePy could be applied

# Status of MontePy

As of MontePy 0.5.0 many of the most commonly used MCNP inputs (cards) are supported.
As of MontePy 0.5.4 many of the most commonly used MCNP inputs (cards) are supported.
Copy link
Collaborator

Choose a reason for hiding this comment

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

use comma: 0.5.4,

These include:

* Cells, which are the base of an MCNP geometry and contain a material and a CSG geometry definition.
Expand Down Expand Up @@ -210,6 +269,9 @@ will not be adding support for output files to allow development to focus on sup
MCNP supports over 140 different inputs (cards).
For almost all of the remaining input types that MontePy doesn't support the information
from the input is still available to the user.
The next planned release at the time of publication is version 1.0.0.
This new release is significant redesign of the material definition interface,
making the material interface much more user-friendly.
The exceptions are those inputs with syntax that conflicts with the rest of MCNP,
which need to be handled specifically on their own.
Adding more object-oriented support for all of these inputs is an ongoing project.
Expand Down