Skip to content

Commit

Permalink
using from_plasma
Browse files Browse the repository at this point in the history
  • Loading branch information
Sonu0305 committed Jan 21, 2025
1 parent cdfbbda commit 14221dd
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions tardis/spectrum/formal_integral.py
Original file line number Diff line number Diff line change
Expand Up @@ -288,17 +288,10 @@ def __init__(
self.transport.montecarlo_configuration
)
if plasma and opacity_state and macro_atom_state:
if hasattr(plasma, "photo_ion_cross_sections"):
continuum_state = ContinuumState.from_legacy_plasma(plasma)
else:
continuum_state = None
self.opacity_state = OpacityState(

Check warning on line 291 in tardis/spectrum/formal_integral.py

View check run for this annotation

Codecov / codecov/patch

tardis/spectrum/formal_integral.py#L291

Added line #L291 was not covered by tests
electron_density=plasma.electron_densities,
t_electrons=plasma.t_electrons,
line_list_nu=plasma.atomic_data.lines.nu,
plasma=plasma,
tau_sobolev=opacity_state.tau_sobolev,
beta_sobolev=plasma.beta_sobolev,
continuum_state=continuum_state,
).to_numba(
macro_atom_state,
transport.line_interaction_type,
Expand Down

0 comments on commit 14221dd

Please sign in to comment.