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

Not accepting args/kwargs in BlackBodySimpleSourceRelativistic.create_packets() #2953

Open
nvieira-mcgill opened this issue Jan 21, 2025 · 1 comment · May be fixed by #2962
Open

Not accepting args/kwargs in BlackBodySimpleSourceRelativistic.create_packets() #2953

nvieira-mcgill opened this issue Jan 21, 2025 · 1 comment · May be fixed by #2962

Comments

@nvieira-mcgill
Copy link

Issue with create_packets() when using full relativity. Running TARDIS version from 2024-11-24.

The relevant part of the traceback:

  File "/home/nvieira/tardis-v20241124/lib/python3.12/site-packages/tardis/base.py", line 114, in run_tardis
    simulation.run_convergence()
  File "/home/nvieira/tardis-v20241124/lib/python3.12/site-packages/tardis/simulation/base.py", line 535, in run_convergence
    emitted_luminosity, v_packets_energy_hist = self.iterate(
                                                ^^^^^^^^^^^^^
  File "/home/nvieira/tardis-v20241124/lib/python3.12/site-packages/tardis/simulation/base.py", line 466, in iterate
    transport_state = self.transport.initialize_transport_state(
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/nvieira/tardis-v20241124/lib/python3.12/site-packages/tardis/transport/montecarlo/base.py", line 112, in initialize_transport_state
    packet_collection = self.packet_source.create_packets(
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: BlackBodySimpleSourceRelativistic.create_packets() got an unexpected keyword argument 'seed_offset'

I was able to resolve this by editing BlackBodySimpleSourceRelativistic.create_packets() to also take in args and kwargs.

@andrewfullard
Copy link
Contributor

Could you make a pull request with your fix?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants