Shengcao-Cao / CMT

[CVPR 2023] CMT: Contrastive Mean Teacher for Domain Adaptive Object Detectors
Apache License 2.0
38 stars 6 forks source link

Why the input format is RGB and not the default BGR? #10

Closed Henryluoluoluo closed 7 months ago

Henryluoluoluo commented 7 months ago

In faster_rcnn_VGG_cross_city.yaml the input format is RGB. I trained on my own data set and found that this parameter has a great impact on the experimental results.

  UNSUP_LOSS_WEIGHT: 1.0
  SUP_LOSS_WEIGHT: 1.0
  DIS_TYPE: "vgg4" #["concate","p2","multi"]
TEST:
  EVAL_PERIOD: 1000
INPUT:
  FORMAT: "RGB"
Shengcao-Cao commented 7 months ago

Hello @Henryluoluoluo ,

This is because the pre-trained VGG backbone expects RGB inputs rather than BGR. Also, the normalization parameters are for RGB:

  PIXEL_MEAN: [123.675, 116.280, 103.530]
  PIXEL_STD: [58.395, 57.120, 57.375]

Best, Shengcao