执行train.py进入except fluid.core.EOFException:
Created by: legendxty
用log跟了一下,在执行以下命令的时候,都出现了进入except fluid.core.EOFException:的情况: python3 tools/train.py -c configs/det/det_r50_vd_east.yml python3 tools/train.py -c configs/rec/rec_chinese_common_train.yml
然后把train_eval_det_run函数中的try和except注释,出现如下错误: Traceback (most recent call last): File "tools/train.py", line 112, in main() File "tools/train.py", line 104, in main program.train_eval_det_run(config, exe, train_info_dict, eval_info_dict) File "/home/aistudio/PaddleOCR/tools/program.py", line 240, in train_eval_det_run return_numpy=False) File "/opt/conda/envs/python35-paddle120-env/lib/python3.7/site-packages/paddle/fluid/executor.py", line 790, in run six.reraise(*sys.exc_info()) File "/opt/conda/envs/python35-paddle120-env/lib/python3.7/site-packages/six.py", line 693, in reraise raise value File "/opt/conda/envs/python35-paddle120-env/lib/python3.7/site-packages/paddle/fluid/executor.py", line 785, in run use_program_cache=use_program_cache) File "/opt/conda/envs/python35-paddle120-env/lib/python3.7/site-packages/paddle/fluid/executor.py", line 850, in _run_impl return_numpy=return_numpy) File "/opt/conda/envs/python35-paddle120-env/lib/python3.7/site-packages/paddle/fluid/executor.py", line 684, in _run_parallel tensors = exe.run(fetch_var_names)._move_to_list() paddle.fluid.core_avx.EOFException: There is no next data. at [/paddle/paddle/fluid/operators/reader/read_op.cc:111]
我这里的det的label文件内容是: total/20200614115922_yu-GD7325_type1.jpg [{"transcription": "豫GD7325", "points":[[748, 384], [748, 480], [940, 384], [940, 480]]}] ... rec的label文件内容是: total/20200614115922_yu-GD7325_type0.jpg 豫GD7325
det_east_icdar15_reader.yml的配置如下: TrainReader: reader_function: ppocr.data.det.dataset_traversal,TrainReader process_function: ppocr.data.det.east_process,EASTProcessTrain num_workers: 8 img_set_dir: ./dataset label_file_path: ./dataset/det-train-labels.txt background_ratio: 0.125 min_crop_side_ratio: 0.1 min_text_size: 1
EvalReader: reader_function: ppocr.data.det.dataset_traversal,EvalTestReader process_function: ppocr.data.det.east_process,EASTProcessTest img_set_dir: ./dataset label_file_path: ./dataset/det-test-labels.txt
TestReader: reader_function: ppocr.data.det.dataset_traversal,EvalTestReader process_function: ppocr.data.det.east_process,EASTProcessTest infer_img: img_set_dir: ./dataset label_file_path: ./dataset/det-test-labels.txt do_eval: True