Skip to content

Commit

Permalink
Reading in decay radiation data in atom data (#2471)
Browse files Browse the repository at this point in the history
* Reading in decay radiation data in atom data

* Added docstring

* Fixes the checksum
  • Loading branch information
Knights-Templars authored Nov 20, 2023
1 parent 84cf2e6 commit 0599113
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
2 changes: 1 addition & 1 deletion tardis/data/atomic_data_repo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ kurucz_cd23_chianti_H_He:
- https://dev.azure.com/tardis-sn/TARDIS/_apis/git/repositories/tardis-refdata/items?path=atom_data/kurucz_cd23_chianti_H_He.h5&resolveLfs=true
- https://media.githubusercontent.com/media/tardis-sn/tardis-refdata/master/atom_data/kurucz_cd23_chianti_H_He.h5
uuid: NA
md5: 69a304e1e85e06508fe02dd8c5ba9397
md5: b95b862ef9f06ac20ad4fa70070af59d
11 changes: 11 additions & 0 deletions tardis/io/atom_data/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,12 @@ class AtomData(object):
index: atomic_number, ion_number, level_number_lower, level_number_upper
columns: A_ul[1/s], nu0[Hz], alpha, beta, gamma
decay_radiation_data : pandas.DataFrame
A dataframe containing the *decay radiation data* with:
index: Isotope names
columns: atomic_number, element, Rad energy, Rad intensity decay mode.
Curated from nndc
Attributes
----------
prepared : bool
Expand All @@ -108,6 +114,7 @@ class AtomData(object):
atomic_number2symbol : OrderedDict
photoionization_data : pandas.DataFrame
two_photon_data : pandas.DataFrame
decay_radiation_data : pandas.DataFrame
Methods
-------
Expand Down Expand Up @@ -139,6 +146,7 @@ class AtomData(object):
"yg_data",
"two_photon_data",
"linelist",
"decay_radiation_data",
]

# List of tuples of the related dataframes.
Expand Down Expand Up @@ -275,6 +283,7 @@ def __init__(
yg_data=None,
two_photon_data=None,
linelist=None,
decay_radiation_data=None,
):
self.prepared = False

Expand Down Expand Up @@ -337,6 +346,8 @@ def __init__(
if linelist is not None:
self.linelist = linelist

if decay_radiation_data is not None:
self.decay_radiation_data = decay_radiation_data
self._check_related()

self.symbol2atomic_number = OrderedDict(
Expand Down

0 comments on commit 0599113

Please sign in to comment.