Skip to content

Commit

Permalink
Do not import PBA if not used
Browse files Browse the repository at this point in the history
  • Loading branch information
ThibeauWouters committed Dec 19, 2024
1 parent 6dc0bf1 commit 8fe9cb6
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 83 deletions.
1 change: 1 addition & 0 deletions src/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fiesta.egg-info
7 changes: 6 additions & 1 deletion src/fiesta/train/AfterglowData.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@

from fiesta.constants import days_to_seconds
import afterglowpy as grb
from PyBlastAfterglowMag.wrappers import run_grb


class AfterglowData:
Expand Down Expand Up @@ -372,6 +371,12 @@ def _call_pyblastafterglow(self,
Args:
Float[Array, "n_times"]: The flux density in mJys at the given times.
"""

try:
from PyBlastAfterglowMag.wrappers import run_grb
except ImportError:
raise ImportError("PyBlastAfterglowMag is not installed. Please install it from source")

# Define jet structure (analytic; gaussian) -- 3 free parameters
struct = dict(
struct= self.jet_type, # type of the structure tophat or gaussian
Expand Down
58 changes: 0 additions & 58 deletions src/fiestaEM.egg-info/PKG-INFO

This file was deleted.

9 changes: 0 additions & 9 deletions src/fiestaEM.egg-info/SOURCES.txt

This file was deleted.

1 change: 0 additions & 1 deletion src/fiestaEM.egg-info/dependency_links.txt

This file was deleted.

13 changes: 0 additions & 13 deletions src/fiestaEM.egg-info/requires.txt

This file was deleted.

1 change: 0 additions & 1 deletion src/fiestaEM.egg-info/top_level.txt

This file was deleted.

0 comments on commit 8fe9cb6

Please sign in to comment.