ruotianluo / self-critical.pytorch

Unofficial pytorch implementation for Self-critical Sequence Training for Image Captioning. and others.
MIT License
991 stars 278 forks source link

Get error when evaluate meteor #215

Open ly201802004 opened 4 years ago

ly201802004 commented 4 years ago

hi, @ruotianluo. when i use --language_eval 1 option to evaluate BLEU/METEOR/CIDEr scores during training, i always get this error:BrokenPipeError: [Errno 32] Broken pipe.Details are as follows: computing METEOR score... Traceback (most recent call last): File "tools/train.py", line 298, in train(opt) File "tools/train.py", line 252, in train dp_model, lw_model.crit, loader, eval_kwargs) File "./captioning/utils/eval_utils.py", line 221, in eval_split lang_stats = language_eval(dataset, predictions, n_predictions, eval_kwargs, split) File "./captioning/utils/eval_utils.py", line 87, in language_eval cocoEval.evaluate() File "coco-caption/pycocoevalcap/eval.py", line 59, in evaluate score, scores = scorer.compute_score(gts, res) File "coco-caption/pycocoevalcap/meteor/meteor.py", line 43, in compute_score stat = self._stat(res[i][0], gts[i]) File "coco-caption/pycocoevalcap/meteor/meteor.py", line 67, in _stat self.meteor_p.stdin.write(score_line+'\n') BrokenPipeError: [Errno 32] Broken pipe

Do you know how to fix it?thanks a lot!

ruotianluo commented 4 years ago

I have never seen this before. Sorry. You might as well search on stackoverflow or so.