简体   繁体   中英

How can I fix this Polyfit error with Numpy in Pycharm?

When I run any program that uses Numpy in Pycharm, it returns the following error:

init_dgelsd failed init
Traceback (most recent call last):
  File "<input>", line 1, in <module>
  File "/private/var/folders/0_/ry6vqn855lq0d7n4mww1fks00000gn/T/AppTranslocation/2710F87A-D4CC-42F0-82D4-81D5521E1E33/d/PyCharm CE.app/Contents/plugins/python-ce/helpers/pydev/_pydev_bundle/pydev_import_hook.py", line 21, in do_import
    module = self._system_import(name, *args, **kwargs)
  File "/Users/max/venv/lib/python3.9/site-packages/numpy/__init__.py", line 286, in <module>
    raise RuntimeError(msg)
RuntimeError: Polyfit sanity test emitted a warning, most likely due to using a buggy Accelerate backend. If you compiled yourself, see site.cfg.example for information. Otherwise report this to the vendor that provided NumPy.
RankWarning: Polyfit may be poorly conditioned

This error is returned whenever I attempt to import numpy , also if I simply type import numpy as np in the python console.

I believe I may have to redownload numpy, but I don't even know how to uninstall it from Pycharm in the first place. Do you guys know whether or not I just have to reinstall Numpy, and if so, how to uninstall it from Pycharm?

Using

pip install numpy 

At the cmd for windows

Get cmd: win_key+r

To uninstall using in cmd:

pip uninstall numpy 

But main problem, I think, with python 3.9

Reinstall to python 3.8 first.

就我而言,我运行的是 python 3.8.6,我升级了 NumPy 的版本,它的运行非常棒。

pip install --upgrade numpy

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM