From b3807c2faf151764b5200cb821c644a0ee53e843 Mon Sep 17 00:00:00 2001 From: LDOUBLEV Date: Tue, 15 Dec 2020 16:53:27 +0800 Subject: [PATCH 1/4] update install paddle --- doc/doc_ch/installation.md | 6 +++--- doc/doc_en/installation_en.md | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/doc/doc_ch/installation.md b/doc/doc_ch/installation.md index eb9a5c9f..0dddfec0 100644 --- a/doc/doc_ch/installation.md +++ b/doc/doc_ch/installation.md @@ -2,7 +2,7 @@ 经测试PaddleOCR可在glibc 2.23上运行,您也可以测试其他glibc版本或安装glic 2.23 PaddleOCR 工作环境 -- PaddlePaddle 2.0rc0+ ,推荐使用 PaddlePaddle 2.0rc0 +- PaddlePaddle 1.8+ ,推荐使用 PaddlePaddle 2.0rc1 - python3.7 - glibc 2.23 - cuDNN 7.6+ (GPU) @@ -35,11 +35,11 @@ sudo docker container exec -it ppocr /bin/bash pip3 install --upgrade pip 如果您的机器安装的是CUDA9或CUDA10,请运行以下命令安装 -python3 -m pip install paddlepaddle-gpu==2.0.0rc0 -i https://mirror.baidu.com/pypi/simple +python3 -m pip install paddlepaddle-gpu==2.0.0rc1 -i https://mirror.baidu.com/pypi/simple 如果您的机器是CPU,请运行以下命令安装 -python3 -m pip install paddlepaddle==2.0.0rc0 -i https://mirror.baidu.com/pypi/simple +python3 -m pip install paddlepaddle==2.0.0rc1 -i https://mirror.baidu.com/pypi/simple 更多的版本需求,请参照[安装文档](https://www.paddlepaddle.org.cn/install/quick)中的说明进行操作。 ``` diff --git a/doc/doc_en/installation_en.md b/doc/doc_en/installation_en.md index b49c3f02..073b67b0 100644 --- a/doc/doc_en/installation_en.md +++ b/doc/doc_en/installation_en.md @@ -3,7 +3,7 @@ After testing, paddleocr can run on glibc 2.23. You can also test other glibc versions or install glic 2.23 for the best compatibility. PaddleOCR working environment: -- PaddlePaddle1.8+, Recommend PaddlePaddle 2.0rc0 +- PaddlePaddle 1.8+, Recommend PaddlePaddle 2.0rc1 - python3.7 - glibc 2.23 @@ -38,10 +38,10 @@ sudo docker container exec -it ppocr /bin/bash pip3 install --upgrade pip # If you have cuda9 or cuda10 installed on your machine, please run the following command to install -python3 -m pip install paddlepaddle-gpu==2.0rc0 -i https://mirror.baidu.com/pypi/simple +python3 -m pip install paddlepaddle-gpu==2.0rc1 -i https://mirror.baidu.com/pypi/simple # If you only have cpu on your machine, please run the following command to install -python3 -m pip install paddlepaddle==2.0rc0 -i https://mirror.baidu.com/pypi/simple +python3 -m pip install paddlepaddle==2.0rc1 -i https://mirror.baidu.com/pypi/simple ``` For more software version requirements, please refer to the instructions in [Installation Document](https://www.paddlepaddle.org.cn/install/quick) for operation. From 7de103c5134d1f7334170437c9f7174be13b2d40 Mon Sep 17 00:00:00 2001 From: LDOUBLEV Date: Tue, 15 Dec 2020 17:19:31 +0800 Subject: [PATCH 2/4] update doc --- doc/doc_ch/detection.md | 4 ++-- doc/doc_en/detection_en.md | 6 ++++-- train.sh | 6 +++++- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/doc/doc_ch/detection.md b/doc/doc_ch/detection.md index a3190701..ec3cb276 100644 --- a/doc/doc_ch/detection.md +++ b/doc/doc_ch/detection.md @@ -76,8 +76,8 @@ tar -xf ./pretrain_models/MobileNetV3_large_x0_5_pretrained.tar ./pretrain_model # 单机单卡训练 mv3_db 模型 python3 tools/train.py -c configs/det/det_mv3_db.yml \ -o Global.pretrain_weights=./pretrain_models/MobileNetV3_large_x0_5_pretrained/ -# 单机多卡训练,通过 --select_gpus 参数设置使用的GPU ID; -python3 -m paddle.distributed.launch --selected_gpus '0,1,2,3' tools/train.py -c configs/det/det_mv3_db.yml \ +# 单机多卡训练,通过 --gpus 参数设置使用的GPU ID;如果使用的paddle版本小于2.0rc1,请使用'--select_gpus'参数选择要使用的GPU +python3 -m paddle.distributed.launch --gpus '0,1,2,3' tools/train.py -c configs/det/det_mv3_db.yml \ -o Global.pretrain_weights=./pretrain_models/MobileNetV3_large_x0_5_pretrained/ ``` diff --git a/doc/doc_en/detection_en.md b/doc/doc_en/detection_en.md index 83e94934..5797126b 100644 --- a/doc/doc_en/detection_en.md +++ b/doc/doc_en/detection_en.md @@ -76,8 +76,10 @@ You can also use `-o` to change the training parameters without modifying the ym python3 tools/train.py -c configs/det/det_mv3_db.yml -o Optimizer.base_lr=0.0001 # multi-GPU training -# Set the GPU ID used by the '--select_gpus' parameter; -python3 -m paddle.distributed.launch --selected_gpus '0,1,2,3' tools/train.py -c configs/det/det_mv3_db.yml -o Optimizer.base_lr=0.0001 +# Set the GPU ID used by the '--gpus' parameter; If your paddle version less than 2.0rc1, please use '--selected_gpus' +python3 -m paddle.distributed.launch --gpus '0,1,2,3' tools/train.py -c configs/det/det_mv3_db.yml -o Optimizer.base_lr=0.0001 + + ``` #### load trained model and continue training diff --git a/train.sh b/train.sh index a0483e4d..c511c516 100644 --- a/train.sh +++ b/train.sh @@ -1 +1,5 @@ - python3 -m paddle.distributed.launch --selected_gpus '0,1,2,3,4,5,6,7' tools/train.py -c configs/rec/rec_mv3_none_bilstm_ctc.yml \ No newline at end of file +# for paddle.__version__ >= 2.0rc1 +python3 -m paddle.distributed.launch --gpus '0,1,2,3,4,5,6,7' tools/train.py -c configs/rec/rec_mv3_none_bilstm_ctc.yml + +# for paddle.__version__ < 2.0rc1 +# python3 -m paddle.distributed.launch --selected_gpus '0,1,2,3,4,5,6,7' tools/train.py -c configs/rec/rec_mv3_none_bilstm_ctc.yml From 4d504da6291f68ad08a3f94f308dc286057266af Mon Sep 17 00:00:00 2001 From: LDOUBLEV Date: Tue, 15 Dec 2020 17:38:00 +0800 Subject: [PATCH 3/4] update doc --- doc/doc_en/detection_en.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/doc_en/detection_en.md b/doc/doc_en/detection_en.md index 5797126b..530d7ac4 100644 --- a/doc/doc_en/detection_en.md +++ b/doc/doc_en/detection_en.md @@ -76,7 +76,7 @@ You can also use `-o` to change the training parameters without modifying the ym python3 tools/train.py -c configs/det/det_mv3_db.yml -o Optimizer.base_lr=0.0001 # multi-GPU training -# Set the GPU ID used by the '--gpus' parameter; If your paddle version less than 2.0rc1, please use '--selected_gpus' +# Set the GPU ID used by the '--gpus' parameter; If your paddle version has less than 2.0rc1, please use '--selected_gpus' python3 -m paddle.distributed.launch --gpus '0,1,2,3' tools/train.py -c configs/det/det_mv3_db.yml -o Optimizer.base_lr=0.0001 From 62eab69d9a13aa1ec18088b9934d2962207fa026 Mon Sep 17 00:00:00 2001 From: LDOUBLEV Date: Tue, 15 Dec 2020 18:59:40 +0800 Subject: [PATCH 4/4] update doc --- doc/doc_en/detection_en.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/doc_en/detection_en.md b/doc/doc_en/detection_en.md index 530d7ac4..6a2bda6b 100644 --- a/doc/doc_en/detection_en.md +++ b/doc/doc_en/detection_en.md @@ -76,7 +76,7 @@ You can also use `-o` to change the training parameters without modifying the ym python3 tools/train.py -c configs/det/det_mv3_db.yml -o Optimizer.base_lr=0.0001 # multi-GPU training -# Set the GPU ID used by the '--gpus' parameter; If your paddle version has less than 2.0rc1, please use '--selected_gpus' +# Set the GPU ID used by the '--gpus' parameter; If your paddle version is less than 2.0rc1, please use '--selected_gpus' python3 -m paddle.distributed.launch --gpus '0,1,2,3' tools/train.py -c configs/det/det_mv3_db.yml -o Optimizer.base_lr=0.0001