ctrnet_config.py 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. # Enhanced CenterNet
  2. ctrnet_cfg = {
  3. 'ctrnet_s':{
  4. # ---------------- Model config ----------------
  5. ## Backbone
  6. 'bk_pretrained': True,
  7. 'bk_pretrained_mae': False,
  8. 'bk_act': 'silu',
  9. 'bk_norm': 'BN',
  10. 'bk_depthwise': False,
  11. 'width': 0.50,
  12. 'depth': 0.34,
  13. 'ratio': 2.0,
  14. 'stride': 32,
  15. 'max_stride': 32,
  16. 'out_stride': 4,
  17. ## Neck
  18. 'neck': 'sppf',
  19. 'neck_expand_ratio': 0.5,
  20. 'pooling_size': 5,
  21. 'neck_act': 'silu',
  22. 'neck_norm': 'BN',
  23. 'neck_depthwise': False,
  24. ## Decoder
  25. 'dec_act': 'silu',
  26. 'dec_norm': 'BN',
  27. 'dec_depthwise': False,
  28. ## Head
  29. 'head': 'decoupled_head',
  30. 'num_cls_head': 2,
  31. 'num_reg_head': 2,
  32. 'head_act': 'silu',
  33. 'head_norm': 'BN',
  34. 'head_depthwise': False,
  35. # ---------------- Train config ----------------
  36. ## input
  37. 'multi_scale': [0.5, 1.0], # 320 -> 640
  38. 'trans_type': 'yolov5_s',
  39. # ---------------- Assignment config ----------------
  40. ## Matcher
  41. 'matcher': "aligned_simota",
  42. 'matcher_hpy': {'main' : {'soft_center_radius': 3.0,
  43. 'topk_candidates': 1}, # one-to-one assignment
  44. 'aux' : {'soft_center_radius': 3.0,
  45. 'topk_candidates': 13}, # one-to-many assignment
  46. },
  47. # ---------------- Loss config ----------------
  48. ## loss weight
  49. 'loss_cls_weight': 1.0,
  50. 'loss_box_weight': 2.0,
  51. # ---------------- Train config ----------------
  52. 'trainer_type': 'rtcdet',
  53. },
  54. }