You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

yolov3_mobilenetv2_320_300e_coco.py 1.8 kB

2 years ago
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. _base_ = ['./yolov3_mobilenetv2_mstrain-416_300e_coco.py']
  2. # yapf:disable
  3. model = dict(
  4. bbox_head=dict(
  5. anchor_generator=dict(
  6. base_sizes=[[(220, 125), (128, 222), (264, 266)],
  7. [(35, 87), (102, 96), (60, 170)],
  8. [(10, 15), (24, 36), (72, 42)]])))
  9. # yapf:enable
  10. # dataset settings
  11. img_norm_cfg = dict(
  12. mean=[123.675, 116.28, 103.53], std=[58.395, 57.12, 57.375], to_rgb=True)
  13. train_pipeline = [
  14. dict(type='LoadImageFromFile', to_float32=True),
  15. dict(type='LoadAnnotations', with_bbox=True),
  16. dict(type='PhotoMetricDistortion'),
  17. dict(
  18. type='Expand',
  19. mean=img_norm_cfg['mean'],
  20. to_rgb=img_norm_cfg['to_rgb'],
  21. ratio_range=(1, 2)),
  22. dict(
  23. type='MinIoURandomCrop',
  24. min_ious=(0.4, 0.5, 0.6, 0.7, 0.8, 0.9),
  25. min_crop_size=0.3),
  26. dict(type='Resize', img_scale=(320, 320), keep_ratio=True),
  27. dict(type='RandomFlip', flip_ratio=0.5),
  28. dict(type='Normalize', **img_norm_cfg),
  29. dict(type='Pad', size_divisor=32),
  30. dict(type='DefaultFormatBundle'),
  31. dict(type='Collect', keys=['img', 'gt_bboxes', 'gt_labels'])
  32. ]
  33. test_pipeline = [
  34. dict(type='LoadImageFromFile'),
  35. dict(
  36. type='MultiScaleFlipAug',
  37. img_scale=(320, 320),
  38. flip=False,
  39. transforms=[
  40. dict(type='Resize', keep_ratio=True),
  41. dict(type='RandomFlip'),
  42. dict(type='Normalize', **img_norm_cfg),
  43. dict(type='Pad', size_divisor=32),
  44. dict(type='DefaultFormatBundle'),
  45. dict(type='Collect', keys=['img'])
  46. ])
  47. ]
  48. data = dict(
  49. train=dict(dataset=dict(pipeline=train_pipeline)),
  50. val=dict(pipeline=test_pipeline),
  51. test=dict(pipeline=test_pipeline))

No Description

Contributors (1)