-
Notifications
You must be signed in to change notification settings - Fork 5
Description
import freegs4e
ImportError Traceback (most recent call last)
File ~/opt/anaconda3/envs/freegsnke1/lib/python3.10/site-packages/freegs4e/critical.py:44
43 try:
---> 44 from numba import njit
45 except ImportError:
File ~/opt/anaconda3/envs/freegsnke1/lib/python3.10/site-packages/numba/init.py:59
56 raise ImportError(msg)
---> 59 _ensure_critical_deps()
60 # END DO NOT MOVE
61 # ---------------------- WARNING WARNING WARNING ----------------------------
File ~/opt/anaconda3/envs/freegsnke1/lib/python3.10/site-packages/numba/init.py:45, in _ensure_critical_deps()
43 msg = (f"Numba needs NumPy 2.0 or less. Got NumPy "
44 f"{numpy_version[0]}.{numpy_version[1]}.")
---> 45 raise ImportError(msg)
47 try:
ImportError: Numba needs NumPy 2.0 or less. Got NumPy 2.2.
During handling of the above exception, another exception occurred:
NameError Traceback (most recent call last)
Cell In[1], line 1
----> 1 import freegs4e
File ~/opt/anaconda3/envs/freegsnke1/lib/python3.10/site-packages/freegs4e/init.py:39
35 from importlib import metadata
37 version = metadata.version("freegs4e")
---> 39 from . import control, jtor, machine, plotting
40 from .dump import OutputFile
41 from .equilibrium import Equilibrium
File ~/opt/anaconda3/envs/freegsnke1/lib/python3.10/site-packages/freegs4e/control.py:12
9 from numpy.linalg import inv
10 from scipy import optimize
---> 12 from . import critical
15 class constrain(object):
16 """
17 Adjust coil currents using constraints. To use this class,
18 first create an instance by specifying the constraints
(...)
40 gamma - A scalar, minimises the magnitude of the coil currents
41 """
File ~/opt/anaconda3/envs/freegsnke1/lib/python3.10/site-packages/freegs4e/critical.py:46
44 from numba import njit
45 except ImportError:
---> 46 warnings.warn("Numba not found, using slower version")
48 def njit(*args, **kwargs):
49 return lambda f: f
NameError: name 'warnings' is not defined