mapstp: a tool to associate MCNP and STP models¶
Note
This documentation is currently under active development.
The tool allows associate STP model components and cells of the MCNP model generated from the STP model with Super MC or GEOUNED. The association implies properties: material, density correction factor and radwaste classification tag. A user can use 3D editor to assign properties in 3D model. The properties propagate through the tree hierarchy from top to bottom and can be refined on lower levels, if needed. So, one can define that almost everything in the model is steel, inserting [m-steel] label on the top of hierarchy and set more proper value, like [m-water] or whatever, on some components or even [m-void] to define bodies as empty spaces.
Todo
Improve description, give examples and add links.
Usage¶
Command line interface¶
mapstp¶
Transfers meta information from STP to MCNP
For given STP file creates Excel table with a list of STP paths to STP components, corresponding to cells in MCNP model, would it be generated from the STP with SuperMC.
If MCNP file is also specified as the second mcnp-file argument, then produces output MCNP file with STP paths inserted as end of line comments after corresponding cells with prefix “sep:”. The material numbers and densities are set according to the meta information provided in the STP.
mapstp [OPTIONS] [mcnp-file]
Options
- --override, --no-override¶
Override existing files, (default: no)
- -o, --output <output>¶
File to write the MCNP with marked cells (default: stdout)
- -e, --excel <excel-file>¶
Excel file to write the component paths
- -s, --sql <sql-file>¶
SQLite3 file with the model information
- --materials <materials-file>¶
Text file containing MCNP materials specifications. If present, the selected materials present in this file are printed to the output MCNP model, so, it becomes complete valid model
- -m, --materials-index <materials-index-file>¶
Excel file containing materials mnemonics and corresponding references for MCNP model (default: file from the package internal data corresponding to ITER C-model)
- --version¶
Show the version and exit.
- --help¶
Show this message and exit.
Arguments
- [mcnp-file]¶
Required argument
Todo
Describe CLI in details.
Installation¶
From PyPI (recommended):
pip install mapstp
# or
uv pip install mapstp
With package manager (as dependency):
# uv
uv add mapstp
# pixi
pixi add --pypi mapstp
# poetry
poetry add mapstp
# ...
From source:
uv pip install https://github.com/MC-kit/map-stp.git
# or
pip install https://github.com/MC-kit/map-stp.git
Roadmap & Future Development¶
Planned Features:¶
☐ Harmonize with GEOUNED
☐ Harmonize with Radmodelling
API Reference¶
Examples¶
Contributing¶
We welcome contributions! Please see our GitHub repository for contribution guidelines.