From 0cda9b87579ec3c8c45c94c4480a65f36d577499 Mon Sep 17 00:00:00 2001 From: littletomatodonkey <2120160898@bit.edu.cn> Date: Thu, 29 Oct 2020 12:57:50 +0800 Subject: [PATCH] fix cuda default value (#1051) --- ppocr/data/cls/dataset_traversal.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ppocr/data/cls/dataset_traversal.py b/ppocr/data/cls/dataset_traversal.py index 01f8c89c..ea05b859 100755 --- a/ppocr/data/cls/dataset_traversal.py +++ b/ppocr/data/cls/dataset_traversal.py @@ -74,7 +74,7 @@ class SimpleReader(object): def get_device_num(): if self.use_gpu: - gpus = os.environ.get("CUDA_VISIBLE_DEVICES", 1) + gpus = os.environ.get("CUDA_VISIBLE_DEVICES", "1") gpu_num = len(gpus.split(',')) return gpu_num else: