You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
W1122 02:51:59.620342 14268 gpu_resources.cc:149] device: 0, cuDNN Version: 8.9.
[2023/11/22 02:52:00] ppocr INFO: train dataloader has 18 iters
[2023/11/22 02:52:00] ppocr INFO: valid dataloader has 18 iters
[2023/11/22 02:52:00] ppocr INFO: train from scratch
[2023/11/22 02:52:00] ppocr INFO: During the training process, after the 0th iteration, an evaluation is run every 2000 iterations
Exception in thread Thread-1 (_thread_loop):
Traceback (most recent call last):
File "/home/zen/.local/lib/python3.10/site-packages/paddle/io/dataloader/dataloader_iter.py", line 693, in _get_data
data = self._data_queue.get(timeout=self._timeout)
File "/usr/lib/python3.10/multiprocessing/queues.py", line 114, in get
raise Empty
_queue.Empty
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3.10/threading.py", line 1016, in _bootstrap_inner
self.run()
File "/usr/lib/python3.10/threading.py", line 953, in run
self._target(*self._args, **self._kwargs)
File "/home/zen/.local/lib/python3.10/site-packages/paddle/io/dataloader/dataloader_iter.py", line 604, in _thread_loop
batch = self._get_data()
File "/home/zen/.local/lib/python3.10/site-packages/paddle/io/dataloader/dataloader_iter.py", line 708, in _get_data
raise RuntimeError(
RuntimeError: DataLoader 1 workers exit unexpectedly, pids: 14294
Traceback (most recent call last):
File "/mnt/c/training-ktp/PaddleOCR/tools/train.py", line 227, in <module>
main(config, device, logger, vdl_writer)
File "/mnt/c/training-ktp/PaddleOCR/tools/train.py", line 198, in main
program.train(config, train_dataloader, valid_dataloader, device, model,
File "/mnt/c/training-ktp/PaddleOCR/tools/program.py", line 269, in train
for idx, batch in enumerate(train_dataloader):
File "/home/zen/.local/lib/python3.10/site-packages/paddle/io/dataloader/dataloader_iter.py", line 825, in __next__
self._reader.read_next_list()[0]
SystemError: (Fatal) Blocking queue is killed because the data reader raises an exception.
[Hint: Expected killed_ != true, but received killed_:1 == true:1.] (at ../paddle/fluid/operators/reader/blocking_queue.h:175)
我们提供了AceIssueSolver来帮助你解答问题,你是否想要它来解答(请填写yes/no)?/We provide AceIssueSolver to solve issues, do you want it? (Please write yes/no): what's this
请尽量不要包含图片在问题中/Please try to not include the image in the issue.
rec_icdar15_train.yml:
Global:
use_gpu: trueepoch_num: 72log_smooth_window: 20print_batch_step: 10save_model_dir: ./output/rec/ic15/save_epoch_step: 3# evaluation is run every 2000 iterationseval_batch_step: [0, 2000]cal_metric_during_train: Truepretrained_model:
checkpoints:
save_inference_dir: ./use_visualdl: Falseinfer_img: doc/imgs_words_en/word_10.png# for data or label processcharacter_dict_path: ktp_dictionary.txtmax_text_length: 25infer_mode: Falseuse_space_char: Falsesave_res_path: ./output/rec/predicts_ic15.txtOptimizer:
name: Adambeta1: 0.9beta2: 0.999lr:
learning_rate: 0.001# Start with a slightly higher learning rateregularizer:
name: 'L2'factor: 1e-5# Introduce a small amount of regularization to prevent overfittingArchitecture:
model_type: recalgorithm: CRNNTransform:
Backbone:
name: MobileNetV3scale: 0.75# Increase the scale for potentially better feature extractionmodel_name: largeNeck:
name: SequenceEncoderencoder_type: rnnhidden_size: 128# Increase the hidden size for capturing more complex patternsHead:
name: CTCHeadfc_decay: 0.00004# Introduce some decay in the fully connected layerLoss:
name: CTCLossPostProcess:
name: CTCLabelDecodeMetric:
name: RecMetricmain_indicator: accTrain:
dataset:
name: SimpleDataSetdata_dir: /mnt/c/training-ktp/label_file_list: ["/mnt/c/training-ktp/ktpannotations.txt"]transforms:
- DecodeImage: # load imageimg_mode: BGRchannel_first: False
- RecAug: # Data augmentation
- CTCLabelEncode: # Class handling label
- RecResizeImg:
image_shape: [3, 32, 128] # Dynamic shape can be considered based on your dataset
- KeepKeys:
keep_keys: ['image', 'label', 'length'] loader:
shuffle: Truebatch_size_per_card: 2# Adjusted for memory constraints and to be a power of 2drop_last: Truenum_workers: 1# Adjust based on your CPUuse_shared_memory: False # Enable shared memory for faster data loadingEval:
dataset:
name: SimpleDataSetdata_dir: /mnt/c/training-ktp/label_file_list: ["/mnt/c/training-ktp/ktpannotations.txt"]transforms:
- DecodeImage: # load imageimg_mode: BGRchannel_first: False
- CTCLabelEncode: # Class handling label
- RecResizeImg:
image_shape: [3, 32, 128] # Match the training image shape
- KeepKeys:
keep_keys: ['image', 'label', 'length'] loader:
shuffle: Falsedrop_last: Falsebatch_size_per_card: 2# Consistent with the training batch sizenum_workers: 1# Can be lower than training if resources are limiteduse_shared_memory: False # Enable shared memory for faster data loading
This discussion was converted from issue #11288 on June 10, 2024 07:48.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
请提供下述完整信息以便快速定位问题/Please provide the following information to quickly locate the problem
python3 PaddleOCR/tools/train.py -c rec_icdar15_train.yml
我们提供了AceIssueSolver来帮助你解答问题,你是否想要它来解答(请填写yes/no)?/We provide AceIssueSolver to solve issues, do you want it? (Please write yes/no): what's this
请尽量不要包含图片在问题中/Please try to not include the image in the issue.
rec_icdar15_train.yml:
Folder/File structure:
ktp annotation file are having value like this:
Beta Was this translation helpful? Give feedback.
All reactions