Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError: cannot import name 'trapz' from 'scipy.integrate' with scipy pre-release #1618

Closed
Zethson opened this issue Jun 16, 2024 · 1 comment · Fixed by #1621
Closed

Comments

@Zethson
Copy link

Zethson commented Jun 16, 2024

from lifelines import (
/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/lifelines/init.py:4: in
from lifelines.fitters.weibull_fitter import WeibullFitter
/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/lifelines/fitters/init.py:21: in
from scipy.integrate import trapz
E ImportError: cannot import name 'trapz' from 'scipy.integrate' (/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/scipy/integrate/init.py)

with the scipy pre-release version

scipy.integrate.trapz, scipy.integrate.cumtrapz, and scipy.integrate.simps have been deprecated in favour of scipy.integrate.trapezoid, scipy.integrate.cumulative_trapezoid, and scipy.integrate.simpson respectively and will be removed in SciPy 1.14.

@Zethson Zethson changed the title E ImportError: cannot import name 'trapz' from 'scipy.integrate' with scipy pre-release ImportError: cannot import name 'trapz' from 'scipy.integrate' with scipy pre-release Jun 16, 2024
@mariosyndena
Copy link

encountered the same issue: works with scipy 1.13.1, but not with scipy 1.14. plz update dependencies or add support for 1.14.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants