Documentation site: https://beykyle.github.io/jitr/
A nuclear reaction toolkit, production ready for calibration and uncertainty-quantification, featuring:
- fast calculable
$\mathcal{R}$ -matrix solver for parametric reaction models - built in uncertainty-quantified optical potentials
- built in nuclear data
- plenty of examples demonstrating the propagation of uncertainties into reaction observables and model calibration
Give your nuclear reaction UQ workflow a caffeine-kick with jitr!
The documentation site is available at https://beykyle.github.io/jitr/.
Install the latest released version of jitr from PyPI:
pip install jitrThen use it in Python:
import jitrTo check the installed version:
python -c "import jitr; print(jitr.__version__)"If you use uv, you can add jitr to a uv-managed project with:
uv add jitrOr install it into the current environment with:
uv pip install jitrThis repository uses uv for Python packaging, dependency management, virtual environments, and locking.
git clone https://github.com/beykyle/jitr.git
cd jitrInstall all development dependencies:
uv sync --all-groupsThis creates a local .venv/ environment and installs the package in editable mode along with the development and example dependencies defined in pyproject.toml.
You can run commands through uv:
uv run python
uv run pytestOr activate the environment manually:
source .venv/bin/activateuv run pytestThe example notebooks are tested with pytest and nbval:
uv run --group examples pytest --nbval-lax examples/notebooks/Various example scripts live in examples/. Tutorials live in examples/notebooks/. Currently, the best way to run the notebooks is by cloning the repo and running them in a JupyterLab server with the uv-managed environment as the kernel. This way, you can be sure that all the dependencies are correct and that the notebooks will run as expected.
There are some additional requirements to run the examples. Once you've cloned the repo, from the main directory, run:
uv sync --group examples
Then, register the project environment as a Jupyter kernel:
uv run python -m ipykernel install --user --name jitr --display-name "Python (jitr)"
and start a Jupyter-lab server:
uv run --with jupyter jupyter lab
In JupyterLab, select the Python (jitr) kernel. Notebooks using this kernel will run against the uv-managed .venv/ environment.
Then, you can run the notebooks. In particular, check out:
examples/notebooks/reaction.ipynbwhich demonstrates the use of thereactionssubmoduleexamples/notebooks/builtin_omps_uq.ipynbto see how to use the built-in uncertainty-quantified optical model potentials to propagate uncertainties into reaction observables
This package is part of the BAND Framework
Please consider citing both this package and the BAND Framework if you use this code in your research. The BibTeX entries are:
@software{Beyer_JITR_2024,
author = {Beyer, Kyle},
license = {BSD-3-Clause},
month = oct,
title = {{JITR}},
url = {https://github.com/beykyle/jitr},
version = {1.3.0},
year = {2024}
}@techreport{bandframework,
title = {{BANDFramework: An} Open-Source Framework for {Bayesian} Analysis of Nuclear Dynamics},
author = {Kyle Beyer and Landon Buskirk and Manuel Catacora Rios and Moses Y-H. Chan and Tyler H. Chang and Troy Dasher
and Richard James DeBoer and Christian Drischler and Richard J. Furnstahl and Pablo Giuliani and
Kyle Godbey and Kevin Ingles and Sunil Jaiswal and An Le and Dananjaya Liyanage and Filomena M. Nunes
and Daniel Odell and David O'Gara and Jared O'Neal and Daniel R. Phillips and Matthew Plumlee
and Matthew T. Pratola and Scott Pratt and Oleh Savchuk and Alexandra C. Semposki and \"Ozge S\"urer and
Stefan M. Wild and John C. Yannotty},
institution = {},
number = {Version 0.5.0},
year = {2025},
url = {https://github.com/bandframework/bandframework}
}