Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gamma ray refactor #2139

Merged
merged 7 commits into from
Jul 7, 2023
Merged

Conversation

andrewfullard
Copy link
Contributor

@andrewfullard andrewfullard commented Oct 24, 2022

📝 Description

Type: 🚀 feature

Refactoring of the gamma-ray code to allow for easier modification.

🚦 Testing

How did you test these changes?

  • Testing pipeline
  • Other method (describe)
  • My changes can't be tested (explain why)

☑️ Checklist

  • I requested two reviewers for this pull request
  • I updated the documentation according to my changes
  • I built the documentation by applying the build_docs label

Note: If you are not allowed to perform any of these actions, ping (@) a contributor.

@codecov
Copy link

codecov bot commented Oct 24, 2022

Codecov Report

Merging #2139 (09a4183) into master (e3184f4) will increase coverage by 0.14%.
The diff coverage is 29.32%.

@@            Coverage Diff             @@
##           master    #2139      +/-   ##
==========================================
+ Coverage   61.63%   61.77%   +0.14%     
==========================================
  Files          75       78       +3     
  Lines        8649     8859     +210     
==========================================
+ Hits         5331     5473     +142     
- Misses       3318     3386      +68     
Impacted Files Coverage Δ
tardis/energy_input/gamma_ray_grid.py 19.60% <0.00%> (ø)
tardis/energy_input/GXPacket.py 33.33% <10.00%> (-25.93%) ⬇️
tardis/energy_input/samplers.py 34.09% <34.09%> (ø)
tardis/montecarlo/montecarlo_numba/opacities.py 38.18% <34.54%> (-3.64%) ⬇️
tardis/energy_input/gamma_ray_interactions.py 20.40% <50.00%> (ø)
tardis/energy_input/util.py 32.30% <100.00%> (ø)
tardis/montecarlo/packet_source.py 79.24% <0.00%> (-18.20%) ⬇️
tardis/plasma/standard_plasmas.py 70.09% <0.00%> (-4.40%) ⬇️
tardis/montecarlo/montecarlo_numba/vpacket.py 20.56% <0.00%> (-1.23%) ⬇️
tardis/montecarlo/base.py 86.97% <0.00%> (-0.64%) ⬇️
... and 15 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@andrewfullard
Copy link
Contributor Author

andrewfullard commented Nov 29, 2022

Refactor and original code are matching, it was a case of differences in gamma-ray data processing from sandia vs NNDC. Need to closely investigate the gamma-ray spectra differences and consider which data to use.

NNDC data from nuclear:
image

Sandia data seems to lead to more energy deposition at late times:
image

The sandia decay data stores the end-point energies for positrons, which is not actually what we want (or at least, it's not what anybody else uses).

@andrewfullard andrewfullard removed the request for review from satwik-kambham January 30, 2023 15:39
@andrewfullard andrewfullard marked this pull request as ready for review January 30, 2023 15:48
Copy link
Contributor

@Rodot- Rodot- left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few bits of code are not covered by tests, but that seems fine for now as they would require integration tests

@andrewfullard andrewfullard merged commit 0896a43 into tardis-sn:master Jul 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants