
报错解决方案
文章平均质量分 53
解决使用python等过程中遇到的报错问题
Ther_T
这个作者很懒,什么都没留下…
展开
-
MemoryError的处理方式
Bug:MemoryError: Unable to allocate 4.34 GiB for an array with shape (40442, 80, 60, 3) and data type float64记录几种查到的解决策略:1. 低精度保存数据一般计算上通过numpy得到的16位浮点数。float64占用的内存是float32的两倍,是float16的4倍,比如对于CIFAR10数据集,如果采用float64来表示,需要60000323238/1024**3=1.4G60000∗32原创 2021-12-07 21:32:14 · 9858 阅读 · 0 评论 -
graphviz.backend.ExecutableNotFound: failed to execute ‘dot‘, make sure the Graphviz executables are
Python 使用 Graphviz 绘图遇到的问题和解决方法目录解决方法1.下载安装2.设置环境变量检查在利用graphviz进行模型可视化时,调试出现如下报错:graphviz.backend.ExecutableNotFound: failed to execute 'dot', make sure the Graphviz executables are on your systems' PATH解决方法1.下载安装Graphviz的官网下载:https://graphviz.git原创 2021-10-25 14:18:05 · 4167 阅读 · 4 评论 -
Python读取xlsx文件时报错“xlrd.biffh.XLRDError: Excel xlsx file; not supported”
在使用PyCharm编辑器进行xlrd读取Excel数据时,出现了“xlrd.biffh.XLRDError: Excel xlsx file; not supported”的错误,如下所示错误分析: 我安装的xlrd版本为2.0.1版,程序报错主要是xlrd的2.0以上版本不支持后缀名.xlsx文件的读取,支持.xls文件的读取。最新的xlrd居然不支持Excel .xlsx文件的读取。通过查找大量的资料,找到解决该问题的办法。方法一:在调用read_excel()函数时,添加条件“eng原创 2021-10-12 13:28:56 · 1497 阅读 · 1 评论 -
cv2.error: OpenCV(4.5.3) C:\Users\runneradmin\AppData\Local\Temp\pip-req-build-q3d_8t8e\opencv\modul
在使用 python-opencv进行识别处理时可能会遇到下面的错误:Traceback (most recent call last):File “D:/pycharm/pythonProject/demo2/main.py”, line 6, in img_gray=cv2.cvtColor(img_rgbcv2.COLOR_BGR2GRAY)cv2.error: OpenCV(4.5.3) C:\Users\runneradmin\AppData\Local\Temp\pip-req-bui原创 2021-10-02 15:15:53 · 26461 阅读 · 1 评论 -
python中解决You are using pip version 19.2.3, however version 21.2.4 is available.报错的解决方法
pip安装三方库不成功,提示:WARNING: You are using pip version 19.2.3, however version 21.2.4 is available. You should consider upgrading via the ‘python -m pip install --upgrade pip’ command.原因:pip版本过低导致安装第三方库失败解决方案:更新pip版本1、cmd打开命令窗口2、输入命令:easy_install -U pip(如下原创 2021-10-01 19:09:26 · 12902 阅读 · 4 评论