icecube / ASTERIA

A Supernova TEst Routine for IceCube Analysis

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Import Error in Asteria Notebooks

EmmaTintinger opened this issue · comments

Error:
ImportError: cannot import name 'Flavor' from 'asteria.neutrino'

Locations:
-Detector_Hits: Cell [1]:
-Detector_Hits_File: Cell [1]:
-Detector_Response: Cell [1]:
-Inverse_Beta_Decay: Cell [1]:
-Load_Simulation: Cell [1]:
-Piegsa_Earth_Oscillations: Cell [1]:
-Simplemixing_Class: Cell [1]:
-Simulation_Handling: Cell [1]:
-Supernova_Mixing: Cell [1]:

Error trace from Detector_Hits nb:

ImportError Traceback (most recent call last)
Input In [2], in <cell line: 9>()
6 import matplotlib.pyplot as plt
8 from asteria import config, source, detector
----> 9 from asteria.neutrino import Flavor
11 mpl.rc('font', size=18)

ImportError: cannot import name 'Flavor' from 'asteria.neutrino' (/Users/emmatintinger/ASTERIA/python/asteria/neutrino.py)


Solution:
Change “from asteria.neutrino import Flavor” to “from snewpy.neutrino import Flavor” in cell [1]