Python numpy.test失败,失败:test\u error\u消息(test\u utils.TestEqual)

Python numpy.test失败,失败:test\u error\u消息(test\u utils.TestEqual),python,numpy,Python,Numpy,我是Python新手,所以祈祷这是一个简单的错误 当从anaconda提示符运行以下代码时,我得到一个错误 python -c "import numpy; numpy.test()" 错误消息为 FAIL: test_error_message (test_utils.TestEqual) 更多的信息已经超出我的想象 File "C:\ProgramData\Anaconda22\lib\site-packages\numpy\testing\tests\test_utils.py", l

我是Python新手,所以祈祷这是一个简单的错误

当从anaconda提示符运行以下代码时,我得到一个错误

python -c "import numpy; numpy.test()"
错误消息为

FAIL: test_error_message (test_utils.TestEqual)
更多的信息已经超出我的想象

File "C:\ProgramData\Anaconda22\lib\site-packages\numpy\testing\tests\test_utils.py", line 272, in test_error_message
    "\nArrays are not equal\n\n"
AssertionError: '\nArrays are not equal\n\n(shapes (2L,), (1L, 2L) mismatch)\n x: array([1, 2])\n y: [repr failed for <matrix>: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()]' != '\nArrays are not equal\n\n(shapes (2,), (1, 2) mismatch)\n x: array([1, 2])\n y: [repr failed for <matrix>: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()]'
测试错误消息中的文件“C:\ProgramData\Anaconda22\lib\site packages\numpy\testing\tests\test\utils.py”,第272行 “\n光线不相等\n\n” 断言错误:'\n数组不相等\n\n(形状(2L,),(1L,2L)不匹配)\n x:array([1,2])\n y:[repr失败原因:具有多个元素的数组的真值不明确。请使用a.any()或a.all()\数组不相等\n\n(形状(2,),(1,2)不匹配)\n x:array([1,2])\n y:[repr失败原因:包含多个元素的数组的真值不明确。请使用a.any()或a.all()
我真的不知道如何解决这个问题。有什么建议吗?

好的,所以我不确定为什么这样做有效,但我使用卸载了Numpy

conda uninstall numpy
然后重新安装numpy,带有

conda install numpy
然后重新安装卸载numpy时卸载的所有软件包

conda install astropy bottleneck dask datashape distributed h5py matplotlib numba numexpr numpy odo pandas patsy pygpu pytables pywavelets scikit-image scikit-learn scipy seaborn statsmodels theano 
宾果班戈,别再失败了