Google Summer of Code 2021 with TARDIS
Google Summer of Code 2021 with TARDIS
Google Summer of Code is coming to an end. This summer, I primarily worked on adding Convergence plots and progress bars to TARDIS.
TARDIS is an open-source Monte Carlo radiative-transfer spectral synthesis code for 1D models of supernova ejecta and is designed for rapid spectral modelling of supernovae.
Project Aim
TARDIS displays log messages as the simulation runs which describe the state of the simulation.
[tardis.plasma.standard_plasmas][INFO ] Reading Atomic Data from kurucz_cd23_chianti_H_He.h5 (standard_plasmas.py:92)
[tardis.io.atom_data.util][INFO ] Atom Data kurucz_cd23_chianti_H_He.h5 not found in local path.
Exists in TARDIS Data repo /home/atharva/Downloads/tardis-data/kurucz_cd23_chianti_H_He.h5 (util.py:34)
[tardis.io.atom_data.base][INFO ] Reading Atom Data with: UUID = 6f7b09e887a311e7a06b246e96350010 MD5 = 864f1753714343c41f99cb065710cace (base.py:204)
[tardis.io.atom_data.base][INFO ] Non provided Atomic Data: synpp_refs, photoionization_data, yg_data, two_photon_data (base.py:209)
[tardis.simulation.base][INFO ] Starting iteration 1 of 20 (base.py:367)
[tardis.simulation.base][INFO ] Luminosity emitted = 7.942e+42 erg / s
Luminosity absorbed = 2.659e+42 erg / s
Luminosity requested = 1.059e+43 erg / s
(base.py:536)
My job was to visualize the convergence of the simulation, allowing the user to track the progress of different variables interactively as they change over time. These variables include emitted/absorbed/requested luminosities, inner radiation temperature and dilution factor.
Objective 1: TARDIS Convergence Plots
TARDIS Convergence plots are Plotly FigureWidget subplots that update with each iteration. For the documentation, visit this page. Interactive version below!
Note: This interative version is best viewed on desktop.
Objective 2: TARDIS Progress Bars
TARDIS Progress bars track the number of packets propagated and the number of iterations completed as the simulation progresses.
Final Product
Check out the code (including other contributions)!
TARDIS Convergence Plots: PR #1636, (related: PR #1753 PR #1778, PR #1772, PR #1770, PR #1742)
TARDIS Progress Bars: PR #1703
Demonstrating the nelements and the species_list functionality in the SDEC plot notebook: PR #1665
Edit docstring in the run_tardis function PR #1723
Enabling virtual_packet_logging by default in the visualization folder PR #1693
The documentation main page was freezing due to the Twitter widget: PR #1743 (related: PR #1555 but work started before GSoC)
SDEC plots were not visible in the documentation: PR #1607 (done during bonding period)
For issues, please see this list.
Future Work
Writing tests for the SDEC plotter module: PR #1752
The Monte Carlo Visualization project: TEP PR #28
And a lot more! For seeing my most recent work, please check this. 😎
Acknowledgement
I am extremely grateful to my mentors- James Gillanders, Mark Magee and Jaladh Singhal for their much-needed guidance and efforts. I am also very grateful to Marc Williamson for helping me multiple times during the coding period.
I am also very grateful to have worked with a lot of amazing people from the TARDIS community. During the summer, I learnt a lot about software development, astronomy, different cultures and so much more.
Lastly, I would thank Google Summer of Code for providing me with this opportunity to work with TARDIS.