EOFError

来源:互联网 发布:安卓录像软件 编辑:程序博客网 时间:2024/05/20 09:47

使用cpickle.load(open(filename,’rb’))时出现错误:

EOFError

这是因为读取的文件为空文件,例如我要读取模型文件:

checkpoint_1 = pickle.load(open(options['checkpoint_output_directory'] + options['checkpoint_stage1'],                                'rb'))  # model trained at the first stage

使用ls -lh查看文件大小,发现文件为0字节.

这里写图片描述

读取文件model_checkpoint_multi_pie_epoch19 正常,读取model_checkpoint_multi_pie_epoch29则出现EOFError错误.

阅读全文
0 0
原创粉丝点击