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.

mask_rcnn_regnetx-3.2GF_fpn_1x_coco.py 2.0 kB

2 years ago
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. _base_ = [
  2. '../_base_/models/mask_rcnn_r50_fpn.py',
  3. '../_base_/datasets/coco_instance.py',
  4. '../_base_/schedules/schedule_1x.py', '../_base_/default_runtime.py'
  5. ]
  6. model = dict(
  7. backbone=dict(
  8. _delete_=True,
  9. type='RegNet',
  10. arch='regnetx_3.2gf',
  11. out_indices=(0, 1, 2, 3),
  12. frozen_stages=1,
  13. norm_cfg=dict(type='BN', requires_grad=True),
  14. norm_eval=True,
  15. style='pytorch',
  16. init_cfg=dict(
  17. type='Pretrained', checkpoint='open-mmlab://regnetx_3.2gf')),
  18. neck=dict(
  19. type='FPN',
  20. in_channels=[96, 192, 432, 1008],
  21. out_channels=256,
  22. num_outs=5))
  23. img_norm_cfg = dict(
  24. # The mean and std are used in PyCls when training RegNets
  25. mean=[103.53, 116.28, 123.675],
  26. std=[57.375, 57.12, 58.395],
  27. to_rgb=False)
  28. train_pipeline = [
  29. # Images are converted to float32 directly after loading in PyCls
  30. dict(type='LoadImageFromFile'),
  31. dict(type='LoadAnnotations', with_bbox=True, with_mask=True),
  32. dict(type='Resize', img_scale=(1333, 800), keep_ratio=True),
  33. dict(type='RandomFlip', flip_ratio=0.5),
  34. dict(type='Normalize', **img_norm_cfg),
  35. dict(type='Pad', size_divisor=32),
  36. dict(type='DefaultFormatBundle'),
  37. dict(type='Collect', keys=['img', 'gt_bboxes', 'gt_labels', 'gt_masks']),
  38. ]
  39. test_pipeline = [
  40. dict(type='LoadImageFromFile'),
  41. dict(
  42. type='MultiScaleFlipAug',
  43. img_scale=(1333, 800),
  44. flip=False,
  45. transforms=[
  46. dict(type='Resize', keep_ratio=True),
  47. dict(type='RandomFlip'),
  48. dict(type='Normalize', **img_norm_cfg),
  49. dict(type='Pad', size_divisor=32),
  50. dict(type='ImageToTensor', keys=['img']),
  51. dict(type='Collect', keys=['img']),
  52. ])
  53. ]
  54. data = dict(
  55. train=dict(pipeline=train_pipeline),
  56. val=dict(pipeline=test_pipeline),
  57. test=dict(pipeline=test_pipeline))
  58. optimizer = dict(type='SGD', lr=0.02, momentum=0.9, weight_decay=0.00005)

No Description

Contributors (3)