gpt4 book ai didi

python - pip 找不到已安装的 python 包

转载 作者:太空宇宙 更新时间:2023-11-03 18:16:00 24 4
gpt4 key购买 nike

我正在尝试安装 statsmodels,但收到一个依赖错误,指出 statsmodels 需要 patsy。然而 patsy 已经安装了:

Baby-Whip$ sudo pip install patsy
Downloading/unpacking patsy
Downloading patsy-0.3.0-py2.py3-none-any.whl (224kB): 224kB downloaded
Requirement already satisfied (use --upgrade to upgrade): numpy in /System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python (from patsy)
Installing collected packages: patsy
Successfully installed patsy
Cleaning up...

然后当我尝试安装 stasmodels 时:

Baby-Whip$ sudo pip install statsmodels
Downloading/unpacking statsmodels
Downloading statsmodels-0.5.0.tar.gz (5.5MB): 5.5MB downloaded
Running setup.py (path:/private/tmp/pip_build_root/statsmodels/setup.py) egg_info for package statsmodels
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/private/tmp/pip_build_root/statsmodels/setup.py", line 463, in <module>
check_dependency_versions(min_versions)
File "/private/tmp/pip_build_root/statsmodels/setup.py", line 122, in check_dependency_versions
raise ImportError("statsmodels requires patsy. http://patsy.readthedocs.org")
ImportError: statsmodels requires patsy. http://patsy.readthedocs.org
Complete output from command python setup.py egg_info:
Traceback (most recent call last):

File "<string>", line 17, in <module>

File "/private/tmp/pip_build_root/statsmodels/setup.py", line 463, in <module>

check_dependency_versions(min_versions)

File "/private/tmp/pip_build_root/statsmodels/setup.py", line 122, in check_dependency_versions

raise ImportError("statsmodels requires patsy. http://patsy.readthedocs.org")

ImportError: statsmodels requires patsy. http://patsy.readthedocs.org

运行 pip freeze 还会将 patsy 列为已安装的软件包。我在这里缺少什么?任何帮助将不胜感激。

最佳答案

请参阅上面的评论以获得答案。需要安装六个,并使用上述解决方法运行 statsmodels 安装。

旁注:杀了我

关于python - pip 找不到已安装的 python 包,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24998344/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com