PaddlePaddle / PaddleOCR

Awesome multilingual OCR toolkits based on PaddlePaddle (practical ultra lightweight OCR system, support 80+ languages recognition, provide data annotation and synthesis tools, support training and deployment among server, mobile, embedded and IoT devices)
https://paddlepaddle.github.io/PaddleOCR/
Apache License 2.0
42.75k stars 7.68k forks source link

python tools/train.py 无异常运行,直接退出 #2543

Closed Cyuliang closed 3 years ago

Cyuliang commented 3 years ago

(base) PS C:\Users\cc\Documents\Python\paddlepaddle-PaddleOCR-release-2.0\PaddleOCR> python tools/train.py -c configs/det/det_r50_vd_db.yml C:\Users\cc\Anaconda3\lib\site-packages\win32\lib\pywintypes.py:3: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses import imp [2021/04/18 12:10:27] root INFO: Architecture : [2021/04/18 12:10:27] root INFO: Backbone : [2021/04/18 12:10:27] root INFO: layers : 50 [2021/04/18 12:10:27] root INFO: name : ResNet [2021/04/18 12:10:27] root INFO: Head : [2021/04/18 12:10:27] root INFO: k : 50 [2021/04/18 12:10:27] root INFO: name : DBHead [2021/04/18 12:10:27] root INFO: Neck : [2021/04/18 12:10:27] root INFO: name : DBFPN [2021/04/18 12:10:27] root INFO: out_channels : 256 [2021/04/18 12:10:27] root INFO: Transform : None [2021/04/18 12:10:27] root INFO: algorithm : DB [2021/04/18 12:10:27] root INFO: model_type : det [2021/04/18 12:10:27] root INFO: Eval : [2021/04/18 12:10:27] root INFO: dataset : [2021/04/18 12:10:27] root INFO: data_dir : C:\Users\cc\Documents\Python\paddlepaddle-PaddleOCR-release-2.0\PaddleOCR\train_image\ [2021/04/18 12:10:27] root INFO: label_file_list : ['C:\Users\cc\Documents\Python\paddlepaddle-PaddleOCR-release-2.0\PaddleOCR\train_image\06\Label_eval.txt'] [2021/04/18 12:10:27] root INFO: name : SimpleDataSet [2021/04/18 12:10:27] root INFO: transforms : [2021/04/18 12:10:27] root INFO: DecodeImage : [2021/04/18 12:10:27] root INFO: channel_first : False [2021/04/18 12:10:27] root INFO: img_mode : BGR [2021/04/18 12:10:27] root INFO: DetLabelEncode : None [2021/04/18 12:10:27] root INFO: DetResizeForTest : [2021/04/18 12:10:27] root INFO: image_shape : [1440, 1080] [2021/04/18 12:10:27] root INFO: NormalizeImage : [2021/04/18 12:10:27] root INFO: mean : [0.485, 0.456, 0.406] [2021/04/18 12:10:27] root INFO: order : hwc [2021/04/18 12:10:27] root INFO: scale : 1./255. [2021/04/18 12:10:27] root INFO: std : [0.229, 0.224, 0.225] [2021/04/18 12:10:27] root INFO: ToCHWImage : None [2021/04/18 12:10:27] root INFO: KeepKeys : [2021/04/18 12:10:27] root INFO: keep_keys : ['image', 'shape', 'polys', 'ignore_tags'] [2021/04/18 12:10:27] root INFO: loader : [2021/04/18 12:10:27] root INFO: batch_size_per_card : 1 [2021/04/18 12:10:27] root INFO: drop_last : False [2021/04/18 12:10:27] root INFO: num_workers : 8 [2021/04/18 12:10:27] root INFO: shuffle : False [2021/04/18 12:10:27] root INFO: Global : [2021/04/18 12:10:27] root INFO: cal_metric_during_train : False [2021/04/18 12:10:27] root INFO: checkpoints : None [2021/04/18 12:10:27] root INFO: debug : False [2021/04/18 12:10:27] root INFO: distributed : False [2021/04/18 12:10:27] root INFO: epoch_num : 20 [2021/04/18 12:10:27] root INFO: eval_batch_step : [0, 2000] [2021/04/18 12:10:27] root INFO: infer_img : doc/imgs_en/img_10.jpg [2021/04/18 12:10:27] root INFO: load_static_weights : True [2021/04/18 12:10:27] root INFO: log_smooth_window : 20 [2021/04/18 12:10:27] root INFO: pretrained_model : C:\Users\cc\Documents\Python\paddlepaddle-PaddleOCR-release-2.0\PaddleOCR\model\ResNet50_vd_ssld_pretrained\ [2021/04/18 12:10:27] root INFO: print_batch_step : 10 [2021/04/18 12:10:27] root INFO: save_epoch_step : 1200 [2021/04/18 12:10:27] root INFO: save_inference_dir : None [2021/04/18 12:10:27] root INFO: save_model_dir : ./output/det_r50_vd/ [2021/04/18 12:10:27] root INFO: save_res_path : ./output/det_db/predicts_db.txt [2021/04/18 12:10:27] root INFO: use_gpu : True [2021/04/18 12:10:27] root INFO: use_visualdl : False [2021/04/18 12:10:27] root INFO: Loss : [2021/04/18 12:10:27] root INFO: alpha : 5 [2021/04/18 12:10:27] root INFO: balance_loss : True [2021/04/18 12:10:27] root INFO: beta : 10 [2021/04/18 12:10:27] root INFO: main_loss_type : DiceLoss [2021/04/18 12:10:27] root INFO: name : DBLoss [2021/04/18 12:10:27] root INFO: ohem_ratio : 3 [2021/04/18 12:10:27] root INFO: Metric : [2021/04/18 12:10:27] root INFO: main_indicator : hmean [2021/04/18 12:10:27] root INFO: name : DetMetric [2021/04/18 12:10:27] root INFO: Optimizer : [2021/04/18 12:10:27] root INFO: beta1 : 0.9 [2021/04/18 12:10:27] root INFO: beta2 : 0.999 [2021/04/18 12:10:27] root INFO: lr : [2021/04/18 12:10:27] root INFO: learning_rate : 0.001 [2021/04/18 12:10:27] root INFO: name : Adam [2021/04/18 12:10:27] root INFO: regularizer : [2021/04/18 12:10:27] root INFO: factor : 0 [2021/04/18 12:10:27] root INFO: name : L2 [2021/04/18 12:10:27] root INFO: PostProcess : [2021/04/18 12:10:27] root INFO: box_thresh : 0.7 [2021/04/18 12:10:27] root INFO: max_candidates : 1000 [2021/04/18 12:10:27] root INFO: name : DBPostProcess [2021/04/18 12:10:27] root INFO: thresh : 0.3 [2021/04/18 12:10:27] root INFO: unclip_ratio : 1.5 [2021/04/18 12:10:27] root INFO: Train : [2021/04/18 12:10:27] root INFO: dataset : [2021/04/18 12:10:27] root INFO: data_dir : C:\Users\cc\Documents\Python\paddlepaddle-PaddleOCR-release-2.0\PaddleOCR\train_image\ [2021/04/18 12:10:27] root INFO: label_file_list : ['C:\Users\cc\Documents\Python\paddlepaddle-PaddleOCR-release-2.0\PaddleOCR\train_image\06\Label.txt'] [2021/04/18 12:10:27] root INFO: name : SimpleDataSet [2021/04/18 12:10:27] root INFO: ratio_list : [1.0] [2021/04/18 12:10:27] root INFO: transforms : [2021/04/18 12:10:27] root INFO: DecodeImage : [2021/04/18 12:10:27] root INFO: channel_first : False [2021/04/18 12:10:27] root INFO: img_mode : BGR [2021/04/18 12:10:27] root INFO: DetLabelEncode : None [2021/04/18 12:10:27] root INFO: IaaAugment : [2021/04/18 12:10:27] root INFO: augmenter_args : [2021/04/18 12:10:27] root INFO: args : [2021/04/18 12:10:27] root INFO: p : 0.5 [2021/04/18 12:10:27] root INFO: type : Fliplr [2021/04/18 12:10:27] root INFO: args : [2021/04/18 12:10:27] root INFO: rotate : [-10, 10] [2021/04/18 12:10:27] root INFO: type : Affine [2021/04/18 12:10:27] root INFO: args : [2021/04/18 12:10:27] root INFO: size : [0.5, 3] [2021/04/18 12:10:27] root INFO: type : Resize [2021/04/18 12:10:27] root INFO: EastRandomCropData : [2021/04/18 12:10:27] root INFO: keep_ratio : True [2021/04/18 12:10:27] root INFO: max_tries : 50 [2021/04/18 12:10:27] root INFO: size : [640, 640] [2021/04/18 12:10:27] root INFO: MakeBorderMap : [2021/04/18 12:10:27] root INFO: shrink_ratio : 0.4 [2021/04/18 12:10:27] root INFO: thresh_max : 0.7 [2021/04/18 12:10:27] root INFO: thresh_min : 0.3 [2021/04/18 12:10:27] root INFO: MakeShrinkMap : [2021/04/18 12:10:27] root INFO: min_text_size : 8 [2021/04/18 12:10:27] root INFO: shrink_ratio : 0.4 [2021/04/18 12:10:27] root INFO: NormalizeImage : [2021/04/18 12:10:27] root INFO: mean : [0.485, 0.456, 0.406] [2021/04/18 12:10:27] root INFO: order : hwc [2021/04/18 12:10:27] root INFO: scale : 1./255. [2021/04/18 12:10:27] root INFO: std : [0.229, 0.224, 0.225] [2021/04/18 12:10:27] root INFO: ToCHWImage : None [2021/04/18 12:10:27] root INFO: KeepKeys : [2021/04/18 12:10:27] root INFO: keep_keys : ['image', 'threshold_map', 'threshold_mask', 'shrink_map', 'shrink_mask'] [2021/04/18 12:10:27] root INFO: loader : [2021/04/18 12:10:27] root INFO: batch_size_per_card : 1 [2021/04/18 12:10:27] root INFO: drop_last : False [2021/04/18 12:10:27] root INFO: num_workers : 8 [2021/04/18 12:10:27] root INFO: shuffle : True [2021/04/18 12:10:27] root INFO: train with paddle 2.0.2 and device CUDAPlace(0) [2021/04/18 12:10:27] root INFO: Initialize indexs of datasets:['C:\Users\cc\Documents\Python\paddlepaddle-PaddleOCR-release-2.0\PaddleOCR\train_image\06\Label.txt'] [2021/04/18 12:10:27] root INFO: Initialize indexs of datasets:['C:\Users\cc\Documents\Python\paddlepaddle-PaddleOCR-release-2.0\PaddleOCR\train_image\06\Label_eval.txt'] W0418 12:10:27.218447 10212 device_context.cc:362] Please NOTE: device: 0, GPU Compute Capability: 7.5, Driver API Version: 11.2, Runtime API Version: 10.2 W0418 12:10:27.228422 10212 device_context.cc:372] device: 0, cuDNN Version: 7.6. (base) PS C:\Users\cc\Documents\Python\paddlepaddle-PaddleOCR-release-2.0\PaddleOCR>

是什么原因导致这样问题?

mikeshi80 commented 3 years ago

大概率是你使用了 CUDA 11, 详见https://github.com/PaddlePaddle/PaddleOCR/issues/2274

paddle-bot-old[bot] commented 3 years ago

Since you haven\'t replied for more than 3 months, we have closed this issue/pr. If the problem is not solved or there is a follow-up one, please reopen it at any time and we will continue to follow up. It is recommended to pull and try the latest code first. 由于您超过三个月未回复,我们将关闭这个issue/pr。 若问题未解决或有后续问题,请随时重新打开(建议先拉取最新代码进行尝试),我们会继续跟进。