我试图从Colab上的River导入指标,但我目前安装的numpy和River使用的版本可能存在一些版本不匹配from river import metrics
我正在尝试运行此程序,但收到以下错误
ImportError: numpy.core.multiarray failed to import
RuntimeError Traceback (most recent call last)
__init__.pxd in numpy.import_array()
RuntimeError: module compiled against API version 0x10 but this version of numpy is 0xf
During handling of the above exception, another exception occurred:
ImportError Traceback (most recent call last)
<ipython-input-6-3108f4ad0000> in <module>
----> 1 from river import metrics
2 from river import stream
3 from river import preprocessing
4 from river import tree,neighbors,naive_bayes,ensemble,linear_model
5 from river.drift import DDM, ADWIN, EDDM, PageHinkley, KSWIN, HDDM_A, HDDM_W
1 frames
/usr/local/lib/python3.9/dist-packages/river/metrics/mutual_info.py in <module>
4
5 from river import metrics
----> 6 from river.metrics.expected_mutual_info import expected_mutual_info
7
8 __all__ = [
build/lib.linux-x86_64-cpython-38/river/metrics/expected_mutual_info.pyx in init river.metrics.expected_mutual_info()
__init__.pxd in numpy.import_array()
ImportError: numpy.core.multiarray failed to import
1条答案
按热度按时间cvxl0en21#
这个
pip install numpy==1.8.0
解决了类似的我.尝试升级numpy.