Gamma Spectroscopy analysis in PYthon
Project description
GammaSPY: Gamma Spectroscopy analysis in PYthon
Warning This package is in active development and may introduce breaking changes.
A suite of open-source tools for automated γ-ray spectroscopy analysis of fast neutron-induced nuclear reactions, developed for data collected with the EXOGAM clover detector array, but can be use for any HPGe detector arrays.
Overview
This repository contains the analysis framework developed for processing and interpreting γ–γ coincidence data from the EXOGAM detector array at GANIL. The tools integrate experimental data processing, nuclear database cross-referencing, and reaction simulation predictions into a unified automated workflow.
The suite currently includes:
- 2D background subtraction — Native ROOT implementation of the Palameta–Waddington background subtraction algorithm for γ–γ matrices, eliminating the need to convert to legacy RadWare formats
- Coincident γ finder — Automated coincidence identification tool with recursive cascade mapping against ENSDF and XUNDL databases, to arbitrary cascade order
- Expected spectrum plotter — Quantitative prediction of gated γ-ray spectra based on TALYS cross-sections, detector efficiency, and experimental geometry
Planned features include:
- DCO and polarization asymmetry extraction — Angular correlation analysis tools for spin-parity assignments from oriented nuclear ensembles
- Custom TALYS modifications — Source code patches extending discrete level tracking, memory allocation, and output formatting in TALYS for level-by-level population cross-sections
Installation
GammaSPY requires ROOT with PyROOT bindings. If you already have a setup with that, you can install simply with:
pip install gammaspy
Otherwise using pixi
(installation instructions) is
highly recommended since it can also install root. Then simply:
git clone https://gitlab.com/Hemantika1122/GammaSPY.git
pixi install
Quick Start
Get projection with background subtraction
If running in jupyter notebook use %jsroot for interactable TCanvases
from gammaspy.hist2d import Hist2D
hgg = Hist2D("output_gg_addback.root", "hgg")
canvas = hgg.draw_projection(gate_energy=1454, gate_width=3, subtract_background=True)
Add coincidence finder
First download the adaptedLevels csv files for relevant isotopes from the nudat website.
from gammaspy.nudat import LevelSchemes
level_schemes = LevelSchemes(
isotopes=["57Ni", "58Ni", "56Co", "57Co"],
)
canvas = hgg.draw_projection(
gate_energy=1454, gate_width=3, level_schemes=level_schemes, coincidence_order=2
)
Expected gamma spectrum
First run Talys simulations with relevant target isotope and neutron energy range. Pass the output location of the simulation to
from gammaspy.simulation import (
save_simulated_counts_1d,
save_simulated_projection_spectrum,
)
save_simulated_counts_1d()
along with incident flux spectrum and other experimental parameters. This will
save the expected 1D counts at different gamma energies as a csv file. Pass this
csv file to save_simulated_projection_spectrum() along with the LevelScheme
object created above and gate energy and widths. It will produce a root file
with expected spectrum which can be overlaid with experimental spectrum.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gammaspy-0.2.0.tar.gz.
File metadata
- Download URL: gammaspy-0.2.0.tar.gz
- Upload date:
- Size: 35.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3efa10c089572bcb2aba52e859eb292c0616852871e59e8530b4b4e60ca3aa66
|
|
| MD5 |
f838f8850272b2ca410eb5475e55aa6c
|
|
| BLAKE2b-256 |
b6367bf715fbee4f64f94b6649e60358601d54516c190d9fd05c7c7ebe43d6a4
|
Provenance
The following attestation bundles were made for gammaspy-0.2.0.tar.gz:
Publisher:
cd.yml on Hemantika1122/GammaSPY
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
gammaspy-0.2.0.tar.gz -
Subject digest:
3efa10c089572bcb2aba52e859eb292c0616852871e59e8530b4b4e60ca3aa66 - Sigstore transparency entry: 1065164905
- Sigstore integration time:
-
Permalink:
Hemantika1122/GammaSPY@ab065084b932ecd44bda1ea1cd99a554f6dd0908 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/Hemantika1122
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
cd.yml@ab065084b932ecd44bda1ea1cd99a554f6dd0908 -
Trigger Event:
release
-
Statement type:
File details
Details for the file gammaspy-0.2.0-py3-none-any.whl.
File metadata
- Download URL: gammaspy-0.2.0-py3-none-any.whl
- Upload date:
- Size: 29.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
874ab50a9013f6502699bf63ed491b0d9b980596f00b08d50cd6a1455bf9d9e1
|
|
| MD5 |
0fbb312d6b9ec8a55596730e61ea6a19
|
|
| BLAKE2b-256 |
86ad07ab39479cf490110149d0cae3cb7470a8b998c39622d8745df05e7a603a
|
Provenance
The following attestation bundles were made for gammaspy-0.2.0-py3-none-any.whl:
Publisher:
cd.yml on Hemantika1122/GammaSPY
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
gammaspy-0.2.0-py3-none-any.whl -
Subject digest:
874ab50a9013f6502699bf63ed491b0d9b980596f00b08d50cd6a1455bf9d9e1 - Sigstore transparency entry: 1065164932
- Sigstore integration time:
-
Permalink:
Hemantika1122/GammaSPY@ab065084b932ecd44bda1ea1cd99a554f6dd0908 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/Hemantika1122
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
cd.yml@ab065084b932ecd44bda1ea1cd99a554f6dd0908 -
Trigger Event:
release
-
Statement type: