Skip to main content

Bragg Edge modeling

Project description

CI codecov DOI

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.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

braggedgemodeling-0.2.0.tar.gz (28.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

braggedgemodeling-0.2.0-py3-none-any.whl (25.5 kB view details)

Uploaded Python 3

File details

Details for the file braggedgemodeling-0.2.0.tar.gz.

File metadata

  • Download URL: braggedgemodeling-0.2.0.tar.gz
  • Upload date:
  • Size: 28.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for braggedgemodeling-0.2.0.tar.gz
Algorithm Hash digest
SHA256 3b223b09c74af6c0add98aa91bbdf23929807cffd2775fd0edab061a6f0c407f
MD5 38ff1c01bf0105bd08e2797337f014b5
BLAKE2b-256 351459238ea11ec4823b661e7376c0fff1fb52d4ed7b36b06a9fbb0abe085969

See more details on using hashes here.

Provenance

The following attestation bundles were made for braggedgemodeling-0.2.0.tar.gz:

Publisher: publish.yml on ornlneutronimaging/braggedgemodeling

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file braggedgemodeling-0.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for braggedgemodeling-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e6114da8e2754c1e429d77ab4ae44ce56ac590b712b12f9ae89ee1e63462e708
MD5 41fba3ea85a4485a155ba365db9f8faa
BLAKE2b-256 95735054e07633d8396b7508f410eaba89cd73dfdc195294686cd800ca877fdd

See more details on using hashes here.

Provenance

The following attestation bundles were made for braggedgemodeling-0.2.0-py3-none-any.whl:

Publisher: publish.yml on ornlneutronimaging/braggedgemodeling

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page