sr_telescope.yml 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. Global:
  2. use_gpu: true
  3. epoch_num: 100
  4. log_smooth_window: 20
  5. print_batch_step: 10
  6. save_model_dir: ./output/sr/sr_telescope/
  7. save_epoch_step: 3
  8. # evaluation is run every 2000 iterations
  9. eval_batch_step: [0, 1000]
  10. cal_metric_during_train: False
  11. pretrained_model:
  12. checkpoints:
  13. save_inference_dir: ./output/sr/sr_telescope/infer
  14. use_visualdl: False
  15. infer_img: doc/imgs_words_en/word_52.png
  16. # for data or label process
  17. character_dict_path:
  18. max_text_length: 100
  19. infer_mode: False
  20. use_space_char: False
  21. save_res_path: ./output/sr/predicts_telescope.txt
  22. Optimizer:
  23. name: Adam
  24. beta1: 0.5
  25. beta2: 0.999
  26. clip_norm: 0.25
  27. lr:
  28. learning_rate: 0.0001
  29. Architecture:
  30. model_type: sr
  31. algorithm: Telescope
  32. Transform:
  33. name: TBSRN
  34. STN: True
  35. infer_mode: False
  36. Loss:
  37. name: TelescopeLoss
  38. confuse_dict_path: ./ppocr/utils/dict/confuse.pkl
  39. PostProcess:
  40. name: None
  41. Metric:
  42. name: SRMetric
  43. main_indicator: all
  44. Train:
  45. dataset:
  46. name: LMDBDataSetSR
  47. data_dir: ./train_data/TextZoom/train
  48. transforms:
  49. - SRResize:
  50. imgH: 32
  51. imgW: 128
  52. down_sample_scale: 2
  53. - KeepKeys:
  54. keep_keys: ['img_lr', 'img_hr', 'label'] # dataloader will return list in this order
  55. loader:
  56. shuffle: False
  57. batch_size_per_card: 16
  58. drop_last: True
  59. num_workers: 4
  60. Eval:
  61. dataset:
  62. name: LMDBDataSetSR
  63. data_dir: ./train_data/TextZoom/test
  64. transforms:
  65. - SRResize:
  66. imgH: 32
  67. imgW: 128
  68. down_sample_scale: 2
  69. - KeepKeys:
  70. keep_keys: ['img_lr', 'img_hr', 'label'] # dataloader will return list in this order
  71. loader:
  72. shuffle: False
  73. drop_last: False
  74. batch_size_per_card: 16
  75. num_workers: 4