深度学习
季南枫(JIM)
这个作者很懒,什么都没留下…
展开
-
Pycharm找不到自己工程里的模块
运行程序出现找不到模块的报错:解决方法:在运行的程序中加入代码:import syssys.path.append('工程所在的绝对路径')原创 2022-02-20 11:33:59 · 1107 阅读 · 0 评论 -
ZeroDivisionError: division by zero
在跑图像翻译ImageCaptioning.pytorch-master代码时出现报错:修改方法:将eval.py文件中的74和75行用下面的代码替换:if opt.dump_json == 1:# dump the json json.dump(predictions, open('vis/vis.json', 'w'))原创 2022-02-12 21:05:39 · 982 阅读 · 1 评论 -
ImportError: DLL load failed: 找不到指定的程序。
当出现如下错误时:可以用:pip uninstall h5py 先卸载了h5py然后再用:conda install h5py原创 2021-12-12 13:18:51 · 473 阅读 · 0 评论 -
AttributeError: module ‘tensorflow.io‘ has no attribute ‘gfile‘
问题出在这里:我们可以将tf.io.gfile.makedirs(logdir)替换为:if not os.path.exists(logdir): os.makedirs(logdir)这个问题解决了还是会报错:程序错误定位到:解决方法:self._general_file_writer = tf.io.gfile.GFile(self._file_name, "wb")改为:self._general_file_writer = tf.gfile.GFile(self原创 2021-12-10 22:58:36 · 1370 阅读 · 0 评论 -
ModuleNotFoundError: No module named ‘lmdbdict‘
解决方法:pip install lmdbdict这样既可解决原创 2021-12-09 20:19:19 · 318 阅读 · 0 评论 -
ModuleNotFoundError: No module named ‘用户自定义模块‘
当发现自己已经在工程中定义了自己的模块,但导入时报错说ModuleNotFoundError: No module named ‘用户自定义模块’,这有可能是没有识别出你的工程目录,可以在你的程序中加入如下语句:import osimport syssys.path.append('用户工程的绝对路径')这样,问题就解决了...原创 2021-12-09 20:08:57 · 1151 阅读 · 0 评论 -
FileNotFoundError: [Errno 2] No such file or directory: ‘./models/config.pickle‘
在跑show_attend_and_tell论文的代码时,如果出现下面的错误:说明你在命令窗口输入运行命令时没有加上模型的路径,例如:python main.py --phase=test正确的运行该程序的命令应该是:python main.py --phase=test --model_file='./models/289999.npy'...原创 2021-09-01 12:54:57 · 610 阅读 · 0 评论