当我在Surface Pro X上安装32位Anaconda并尝试在Jupyter笔记本中运行import numpy和pandas时,出现此错误。
我尝试使用conda update numpy更新软件包。
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\core\getlimits.py:174: RuntimeWarning: divide by zero encountered in exp2
eps=exp2(ld(-112)),
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\core\getlimits.py:53: RuntimeWarning: divide by zero encountered in log10
self.precision = int(-log10(self.eps))
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\core\getlimits.py:54: RuntimeWarning: divide by zero encountered in power
self.resolution = float_to_float(float_conv(10) ** (-self.precision))
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\core\getlimits.py:186: RuntimeWarning: divide by zero encountered in exp2
epsneg_f80 = exp2(ld(-64))
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\core\getlimits.py:187: RuntimeWarning: divide by zero encountered in exp2
tiny_f80 = exp2(ld(-16382))
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\core\getlimits.py:201: RuntimeWarning: divide by zero encountered in exp2
eps=exp2(ld(-63)),
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\core\getlimits.py:214: RuntimeWarning: divide by zero encountered in nextafter
if hasattr(umath, 'nextafter') # Missing on some platforms?
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\core\getlimits.py:226: RuntimeWarning: divide by zero encountered in exp2
eps=exp2(ld(-105)),
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\core\getlimits.py:227: RuntimeWarning: divide by zero encountered in exp2
epsneg= exp2(ld(-106)),
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\core\getlimits.py:229: RuntimeWarning: divide by zero encountered in exp2
tiny=exp2(ld(-1022)))
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\__init__.py:210: RuntimeWarning: divide by zero encountered in subtract
if not abs(x.dot(x) - 2.0) < 1e-5:
C:\Users\mechm\Anaconda3\lib\site-packages\numpy\__init__.py:210: RuntimeWarning: divide by zero encountered in absolute
if not abs(x.dot(x) - 2.0) < 1e-5:
答案 0 :(得分:0)
找到了可能的解决方法,我运行了此方法。不知道为什么它起作用。
import sys
!conda install --yes --prefix {sys.prefix} numpy