安裝pySCENIC報錯:AttributeError: module 'numpy' has no attribute 'object'.
剛開始安裝pySCENIC的代碼如下:
conda create -n pyscenic
conda activate pyscenic
pip install pyscenic
檢查pySCENIC是否安裝成功:
pyscenic -h
發(fā)現(xiàn)有以下錯誤:
AttributeError: module 'numpy' has no attribute 'object'.
結(jié)果google一搜索,發(fā)現(xiàn)是pySCENIC的代碼中用了numpy過時的命令。
重新安裝pySCENIC:
conda env remove -n pyscenic
conda create -n pyscenic python=3.8.1
conda activate pyscenic
pip install numpy==1.19.5
pip install pandas==1.3.5
pip install numba==0.56.4
pip install pyscenic==0.12.1
然后再檢查pySCENIC是否安裝成功:
pyscenic -h

pyscenic -h的結(jié)果輸出
可以成功運行了!
以上命令參考以下內(nèi)容:
【記錄向】經(jīng)驗分享:Pyscenic軟件不兼容報錯解決方法_attributeerror: module 'numpy' has no attribute 'o-CSDN博客
AttributeError: module 'numpy' has no attribute 'object'.[BUG] · Issue #474 · aertslab/pySCENIC (github.com)