mask-rcnn_r50-caffe_fpn_ms-poly-1x_coco.py 942 B

12345678910111213141516171819202122232425262728293031
  1. _base_ = './mask-rcnn_r50_fpn_1x_coco.py'
  2. model = dict(
  3. # use caffe img_norm
  4. data_preprocessor=dict(
  5. mean=[103.530, 116.280, 123.675],
  6. std=[1.0, 1.0, 1.0],
  7. bgr_to_rgb=False),
  8. backbone=dict(
  9. norm_cfg=dict(requires_grad=False),
  10. style='caffe',
  11. init_cfg=dict(
  12. type='Pretrained',
  13. checkpoint='open-mmlab://detectron2/resnet50_caffe')))
  14. train_pipeline = [
  15. dict(type='LoadImageFromFile', backend_args={{_base_.backend_args}}),
  16. dict(
  17. type='LoadAnnotations',
  18. with_bbox=True,
  19. with_mask=True,
  20. poly2mask=False),
  21. dict(
  22. type='RandomChoiceResize',
  23. scales=[(1333, 640), (1333, 672), (1333, 704), (1333, 736),
  24. (1333, 768), (1333, 800)],
  25. keep_ratio=True),
  26. dict(type='RandomFlip', prob=0.5),
  27. dict(type='PackDetInputs')
  28. ]
  29. train_dataloader = dict(dataset=dict(pipeline=train_pipeline))