chaospy
chaospy copied to clipboard
chaospy does not support numpy 2.0
Describe the bug
Importing the module makes Python fail when chaospy
is installed from pip
using numpy
2.0. It is likely to be a problem related to the support of numpy 2.0 in numpoly
.
To Reproduce Provide a minimal code example that reproduces the error.
import chaospy
Expected behavior A clear and concise description of what you expected to happen. If an exception is raised, please provide the exception traceback.
Traceback (most recent call last):
File "/home/circleci/project/script.py", line 13, in <module>
import chaospy
File "/home/circleci/.pyenv/versions/3.10.14/lib/python3.10/site-packages/chaospy/__init__.py", line 11, in <module>
from numpoly import *
File "/home/circleci/.pyenv/versions/3.10.14/lib/python3.10/site-packages/numpoly/__init__.py", line 34, in <module>
from .array_function import *
File "/home/circleci/.pyenv/versions/3.10.14/lib/python3.10/site-packages/numpoly/array_function/__init__.py", line 70, in <module>
from .prod import prod
File "/home/circleci/.pyenv/versions/3.10.14/lib/python3.10/site-packages/numpoly/array_function/prod.py", line 13, in <module>
@implements(numpy.prod, numpy.product)
File "/home/circleci/.pyenv/versions/3.10.14/lib/python3.10/site-packages/numpy/__init__.py", line 410, in __getattr__
raise AttributeError("module {!r} has no attribute "
AttributeError: module 'numpy' has no attribute 'product'
Desktop (please complete the following information):
- OS: Linux
- Python version: 3.10
- Chaospy version : 4.3.15
Additional context Add any other context about the problem here. I installed chaospy using pip. Here are the versions used from the log:
chaospy-4.3.15-py3-none-any.whl (254 kB)
numpoly-1.2.12-py3-none-any.whl (148 kB)
numpy-2.0.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (19.3 MB)