yolov3_darknet_voc_diouloss.yml 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. architecture: YOLOv3
  2. use_gpu: true
  3. max_iters: 70000
  4. log_iter: 20
  5. save_dir: output
  6. snapshot_iter: 2000
  7. metric: VOC
  8. map_type: 11point
  9. pretrain_weights: https://paddle-imagenet-models-name.bj.bcebos.com/DarkNet53_pretrained.tar
  10. weights: output/yolov3_darknet_voc/model_final
  11. num_classes: 20
  12. use_fine_grained_loss: true
  13. YOLOv3:
  14. backbone: DarkNet
  15. yolo_head: YOLOv3Head
  16. DarkNet:
  17. norm_type: sync_bn
  18. norm_decay: 0.
  19. depth: 53
  20. YOLOv3Head:
  21. anchor_masks: [[6, 7, 8], [3, 4, 5], [0, 1, 2]]
  22. anchors: [[10, 13], [16, 30], [33, 23],
  23. [30, 61], [62, 45], [59, 119],
  24. [116, 90], [156, 198], [373, 326]]
  25. norm_decay: 0.
  26. yolo_loss: YOLOv3Loss
  27. nms:
  28. background_label: -1
  29. keep_top_k: 100
  30. nms_threshold: 0.45
  31. nms_top_k: 1000
  32. normalized: false
  33. score_threshold: 0.01
  34. YOLOv3Loss:
  35. ignore_thresh: 0.7
  36. label_smooth: false
  37. iou_loss: DiouLossYolo
  38. DiouLossYolo:
  39. loss_weight: 5
  40. LearningRate:
  41. base_lr: 0.001
  42. schedulers:
  43. - !PiecewiseDecay
  44. gamma: 0.1
  45. milestones:
  46. - 55000
  47. - 62000
  48. - !LinearWarmup
  49. start_factor: 0.
  50. steps: 1000
  51. OptimizerBuilder:
  52. optimizer:
  53. momentum: 0.9
  54. type: Momentum
  55. regularizer:
  56. factor: 0.0005
  57. type: L2
  58. _READER_: 'yolov3_reader.yml'
  59. TrainReader:
  60. inputs_def:
  61. fields: ['image', 'gt_bbox', 'gt_class', 'gt_score']
  62. num_max_boxes: 50
  63. dataset:
  64. !VOCDataSet
  65. dataset_dir: dataset/voc
  66. anno_path: trainval.txt
  67. use_default_label: true
  68. with_background: false
  69. EvalReader:
  70. inputs_def:
  71. fields: ['image', 'im_size', 'im_id', 'gt_bbox', 'gt_class', 'is_difficult']
  72. num_max_boxes: 50
  73. dataset:
  74. !VOCDataSet
  75. dataset_dir: dataset/voc
  76. anno_path: test.txt
  77. use_default_label: true
  78. with_background: false
  79. TestReader:
  80. dataset:
  81. !ImageFolder
  82. use_default_label: true
  83. with_background: false