Skip to content

Commit

Permalink
Fixed looping import
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewfullard committed Apr 21, 2021
1 parent daede05 commit cf853e9
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
13 changes: 4 additions & 9 deletions tardis/montecarlo/montecarlo_numba/interaction.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from enum import IntEnum

from numba import njit
from tardis.montecarlo.montecarlo_numba import njit_dict, njit_dict_no_parallel
from tardis.montecarlo.montecarlo_numba.numba_interface import (
Expand All @@ -14,17 +12,14 @@
get_inverse_doppler_factor,
angle_aberration_CMF_to_LF,
)
from tardis.montecarlo.montecarlo_numba.r_packet import test_for_close_line
from tardis.montecarlo.montecarlo_numba.r_packet import (
test_for_close_line,
InteractionType,
)
from tardis.montecarlo.montecarlo_numba.utils import get_random_mu
from tardis.montecarlo.montecarlo_numba.macro_atom import macro_atom


class InteractionType(IntEnum):
BOUNDARY = 1
LINE = 2
ESCATTERING = 3


@njit(**njit_dict_no_parallel)
def thomson_scatter(r_packet, time_explosion):
"""
Expand Down
8 changes: 7 additions & 1 deletion tardis/montecarlo/montecarlo_numba/r_packet.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from tardis.montecarlo.montecarlo_numba import (
njit_dict_no_parallel,
)
from tardis.montecarlo.montecarlo_numba.interaction import InteractionType

from tardis.montecarlo.montecarlo_numba.estimators import (
set_estimators,
set_estimators_full_relativity,
Expand All @@ -31,6 +31,12 @@
)


class InteractionType(IntEnum):
BOUNDARY = 1
LINE = 2
ESCATTERING = 3


class PacketStatus(IntEnum):
IN_PROCESS = 0
EMITTED = 1
Expand Down

0 comments on commit cf853e9

Please sign in to comment.