Command line tool to separate tallies into individual files for large MCNP meshtal outputs that contain multiple tallies.
Usage: splitmesh <path> [options]
Arguments:
<path> Path to input meshtal file
Options:
-v, --verbose... Verbose logging (-v, -vv)
-q, --quiet Supress all log output (overrules --verbose)
-h, --help Print help (see more with '--help')
Split options:
-t, --tallies <id>... List of tallies to extract
-o, --output <name> Prefix for output files [default: fmesh]
Note: --help shows more information and examples
Help is printed with the -h
flag, and --help
will show examples, default
values, examples, and any important behaviour.
Direct from github:
cargo install --git https://github.com/repositony/splitmesh.git
All executables are under ~/.cargo/bin/
, which should already be in your path
after installing Rust.
Click here if you have never used Rust
If you have never used the Rust programming language, the toolchain is easily installed from the official website
Run the following to download and run rustup-init.sh
, which will install
the Rust toolchain for your platform.
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
This should have added source $HOME/.cargo/env
to the bash profile, so update
your environment with source ~/.bashrc
.
On Windows, download and run rustup-init.exe
from the official installs.
Splits up all meshes found in a meshtal file into their individual files.
This is very useful for processing large meshtal files with multiple tallies, or for just reducing file sizes to a minimum for post-processing.
By default, every tally found in the file is splt into individual files.
Use the --tallies
option to specify one or more tallies to be separated
out. Invalid entries are simply ignored.
# Extract only tallies with ID 104, 204, and 504 from the primary file
splitmesh /path/to/file.msht --tallies 104 204 504
The name of the output files is appended with the tally number as
<output>_<id>.msht
. Output defaults to fmesh
, but this may be changed.
# Change output file names to "mymesh_<id>.msht"
splitmesh /path/to/file.msht --output mymesh