Bragg Edge Modeling
This python package provides tools to model and help analyze neutron Bragg Edge imaging data.
Main functionality: given lattice structure of a material and optionally a texture model and an instrument beam model, calculate neutron Bragg Edge spectrum as a function of neutron wavelength.
Features
- Calculation of basic Bragg Edge spectrum from crystal structure specification, assuming an isotropic powder sample, and accounting for various contributions to neutron scattering including, for example, diffraction and inelastic scattering (using incoherent approximation)
- Modeling of texture:
- March Dollase
- Modeling of peak profile:
- Jorgensen model
- Flexible design to allow future extension to texture and peak profile models
- Allow easy fitting to measured Bragg Edge data
Installation
braggedgemodeling requires Python 3.12+.
# from PyPI
pip install braggedgemodeling
# or from conda (anaconda.org neutronimaging channel)
conda install -c conda-forge -c neutronimaging braggedgemodeling
The distribution is named braggedgemodeling (the short name bem is already taken on PyPI) and the import package is also braggedgemodeling. Code written against the old bem module can add a one-line alias as a drop-in stop-gap:
import braggedgemodeling as bem
For development, the project uses pixi:
git clone https://github.com/ornlneutronimaging/braggedgemodeling.git
cd braggedgemodeling
pixi run test # build the environment and run the test suite
Documentation
Please refer to https://ornlneutronimaging.github.io/braggedgemodeling for documentation on installation, usage, and API.
Community guidelines
How to contribute
Please clone the repository, make changes and make a pull request.
How to report issues
Please use the github issues to report issues or bug reports.
Support
Please either use the github issues to ask for support, or contact the authors directly using email.
Known problems
- Debye temperatures are listed in a table, which is missing data for some elements. However, users can provide their own table in a configuration file.
Release files for braggedgemodeling 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| braggedgemodeling-0.2.0.tar.gz | 28.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| braggedgemodeling-0.2.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 53.9 kB
Release files / braggedgemodeling-0.2.0.tar.gz
| Download URL | braggedgemodeling-0.2.0.tar.gz |
|---|---|
| Size | 28.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3b223b09c74af6c0add98aa91bbdf23929807cffd2775fd0edab061a6f0c407f
|
|
BLAKE2b-256 checksum How to use checksums |
351459238ea11ec4823b661e7376c0fff1fb52d4ed7b36b06a9fbb0abe085969
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.13
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 14, 2026.
Transparency logRelease files / braggedgemodeling-0.2.0-py3-none-any.whl
| Download URL | braggedgemodeling-0.2.0-py3-none-any.whl |
|---|---|
| Size | 25.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e6114da8e2754c1e429d77ab4ae44ce56ac590b712b12f9ae89ee1e63462e708
|
|
BLAKE2b-256 checksum How to use checksums |
95735054e07633d8396b7508f410eaba89cd73dfdc195294686cd800ca877fdd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.13
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 14, 2026.
Transparency log