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

Added support for passing Configuration object in run_tardis #1559

Merged
merged 4 commits into from
May 14, 2021

Conversation

aribalam
Copy link
Contributor

@aribalam aribalam commented May 2, 2021

Description

Merging this PR will allow for configuration objects to be passed in run_tardis.

config = Configuration.from_yaml('tardis_example.yml')
run_tardis(config)

Fixes #1294

@wkerzendorf Kindly have a look.

Motivation and context

How has this been tested?

  • Testing pipeline.
  • Other.

Examples

Type of change

  • Bug fix.
  • New feature.
  • Breaking change.
  • None of the above.

Checklist

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • (optional) I have built the documentation on my fork following the instructions.
  • I have assigned and requested two reviewers for this pull request.

@codecov
Copy link

codecov bot commented May 2, 2021

Codecov Report

Merging #1559 (974ec09) into master (923e59d) will increase coverage by 0.19%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1559      +/-   ##
==========================================
+ Coverage   68.18%   68.37%   +0.19%     
==========================================
  Files          73       73              
  Lines        6308     6375      +67     
==========================================
+ Hits         4301     4359      +58     
- Misses       2007     2016       +9     
Impacted Files Coverage Δ
tardis/tardis/io/config_reader.py 82.35% <0.00%> (-3.98%) ⬇️
tardis/tardis/base.py 55.00% <0.00%> (+49.44%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 923e59d...974ec09. Read the comment docs.

@marxwillia
Copy link
Contributor

This is a great addition. @aribalam can you please write a test for this new functionality?

@aribalam
Copy link
Contributor Author

aribalam commented May 4, 2021

@marxwillia I have added the test as a function in test_tardis_full.py as I am not sure where to add this test to. Please let me know if any changes are required!

@andrewfullard andrewfullard merged commit f84c1d0 into tardis-sn:master May 14, 2021
atharva-2001 pushed a commit to atharva-2001/tardis that referenced this pull request Oct 1, 2021
…sn#1559)

* added support to pass config objects in run_tardis

* updated docstrings

* added tests for the feature

* added docstrings
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.

Reading csvy model causes problems using Configuration
3 participants