From 2c9270539a861f50eef0443b58cde28bf933e7ee Mon Sep 17 00:00:00 2001 From: ProtossDragoon Date: Wed, 16 Nov 2022 17:55:06 +0900 Subject: [PATCH] [Fix] Change mmcv.dump to mmengine.dump - `dump` method was removed from MMCV 2.x. `Use mmengine.dump` instead. --- mmocr/apis/inferencers/mmocr_inferencer.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mmocr/apis/inferencers/mmocr_inferencer.py b/mmocr/apis/inferencers/mmocr_inferencer.py index 5a33e8a33..327140929 100644 --- a/mmocr/apis/inferencers/mmocr_inferencer.py +++ b/mmocr/apis/inferencers/mmocr_inferencer.py @@ -4,6 +4,7 @@ from typing import Dict, List, Optional, Tuple, Union import mmcv +import mmengine import numpy as np from mmocr.registry import VISUALIZERS @@ -210,7 +211,7 @@ def postprocess(self, if print_result: print(results) if pred_out_file != '': - mmcv.dump(results, pred_out_file) + mmengine.dump(results, pred_out_file) if imgs is None: return results return results, imgs