From 49c4a3a7ed0118e16c9cac0417cb3955f0571463 Mon Sep 17 00:00:00 2001 From: LDOUBLEV Date: Tue, 17 Aug 2021 02:46:18 +0000 Subject: [PATCH] gpu_id is None when args.use_gpu as False --- tools/infer/predict_det.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/infer/predict_det.py b/tools/infer/predict_det.py index 62e7ff73..5c75e0c4 100755 --- a/tools/infer/predict_det.py +++ b/tools/infer/predict_det.py @@ -111,7 +111,7 @@ class TextDetector(object): inference_config=self.config, pids=pid, process_name=None, - gpu_ids=gpu_id, + gpu_ids=gpu_id if args.use_gpu else None, time_keys=[ 'preprocess_time', 'inference_time', 'postprocess_time' ], -- GitLab