[Python] How do I resove the ImportError encountered while using the fssa package in python?

Discussão em 'Python' iniciado por Stack, Fevereiro 13, 2025.

  1. Stack

    Stack Membro Participativo

    I am using python from a anaconda installation and using the python notebook. From the jupyer notebook (ipython) I import fssa like:

    import fssa


    I get the following error message (see below).

    Any help from you will be appreciated.

    I have tried uninstalling and reinstalling scipy, numpy, and fssa and reinstalling them, but the problem seems to remain.

    ImportError Traceback (most recent call last)
    /tmp/ipykernel_218856/781571052.py in <module>
    ----> 1 import fssa

    ~/anaconda3/lib/python3.9/site-packages/fssa/__init__.py in <module>
    82
    83 import pkg_resources
    ---> 84 from .fssa import scaledata, quality, autoscale
    85
    86 __version__ = pkg_resources.get_distribution(__name__).version

    ~/anaconda3/lib/python3.9/site-packages/fssa/fssa.py in <module>
    46 import scipy.optimize
    47
    ---> 48 from .optimize import _minimize_neldermead
    49
    50

    ~/anaconda3/lib/python3.9/site-packages/fssa/optimize.py in <module>
    11 import numpy
    12 from numpy import asfarray
    ---> 13 from scipy.optimize.optimize import (OptimizeResult,
    14 _status_message, wrap_function)
    15

    ImportError: cannot import name 'wrap_function' from 'scipy.optimize.optimize'
    (/home/debasish/anaconda3/lib/python3.9/site-packages/scipy/optimize/optimize.py)

    Continue reading...

Compartilhe esta Página