报错处理【1】

1.ERROR: pip’s dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
gensim 4.3.0 requires FuzzyTM>=0.4.0, which is not installed.

由于pip的依赖解析器在安装包时没有考虑到已经安装的所有包,导致依赖冲突。在这种情况下,gensim 4.3.0 需要 FuzzyTM >= 0.4.0,但它尚未安装。

安装 FuzzyTM:

pip install FuzzyTM>=0.4.0

如果问题仍然存在,创建一个新的虚拟环境来安装这些包,以避免与现有环境中的其他包产生冲突。步骤操作:

#安装虚拟环境工具(如果尚未安装):
pip install virtualenv
#创建一个新的虚拟环境:
virtualenv my_new_env
#激活虚拟环境(对于 Windows 系统):
my_new_env\Scripts\activate

进入新的虚拟环境后,可以安装需要的包,而不会影响全局安装的包:

pip install gensim
pip install FuzzyTM>=0.4.0

完成安装后,您可以在此虚拟环境中使用这些包,而不会遇到依赖冲突问题。
如果需要退出虚拟环境,只需在命令行中输入 deactivate 即可。

2.WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by ‘ProxyError(‘Cannot connect to proxy.’, NewConnectionError(’<pip._vendor.urllib3.connection.HTTPSConnection object at 0x0000017B2BC3EC70>: Failed to establish a new connection: [WinError 10061] 由于目标计算机积极拒绝,无法连接。‘))’: /simple/pdpbox/
ERROR: Could not find a version that satisfies the requirement pdpbox (from versions: none)
ERROR: No matching distribution found for pdpbox
方法:https://blog.csdn.net/weixin_45912307/article/details/109556388添加链接描述

3.python进行RF模型构建时,使用Graphviz包对决策树进行可视化时报错:
graphvizs-executables-are-not-found
参考的这个网址上的回答成功解决:https://stackoverflow.com/questions/28312534/graphvizs-executables-are-not-found-python-3-4

pip install graphviz则不成功,但是使用命令conda install graphviz则成功安装:

#决策时可视化代码
import os
os.environ["PATH"] += os.pathsep + 'D:\\Anaconda\\envs\\py38\\Lib\\site-packages\\graphviz'
from sklearn import tree
import graphviz
import pydotplus  
dot_data = tree.export_graphviz(estimator, out_file=None, 
                         feature_names=X_train.columns,  
                         class_names=['0','1'],  
                         filled=True, rounded=True,  
                         special_characters=True)  
graph = pydotplus.graph_from_dot_data(dot_data)  
graph.write_pdf("estimator_tree.pdf") 

得到结果如下:
在这里插入图片描述
3. 报错:fatal: unable to access ‘https://github.com/YosefLab/Cassiopeia/’: Failed to connect to github.com port 443: Connection refused
在这里插入图片描述
解决方法:
输入:

 git config --global url."https://ghproxy.com/https://github.com".insteadOf "https://github.com"

在这里插入图片描述

参考网址

  • 1
    点赞
  • 4
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值