mmdetection icon indicating copy to clipboard operation
mmdetection copied to clipboard

[Feature] [3.x] May I ask the reason why the color palette value based on the model?

Open sanbuphy opened this issue 2 years ago • 2 comments

What's the feature?

I see this : https://github.com/open-mmlab/mmdetection/blob/3.x/mmdet/apis/inference.py#L33

        palette (str): Color palette used for visualization. If palette
            is stored in checkpoint, use checkpoint's palette first, otherwise
            use externally passed palette. Currently, supports 'coco', 'voc',
            'citys' and 'random'. Defaults to coco.

If I want to change the config palette I get an error, because the palette use checkpoint's palette first. I don't quite understand the reason for this design , i want to use config palette to override the model palette, is it possible?

Any other context?

No response

sanbuphy avatar Nov 13 '22 02:11 sanbuphy

Thanks for your kind suggestion. We will try to fix the orders. Do you think the orders below works for you?

  1. config, if it has
  2. model state_dict
  3. dataset

ZwwWayne avatar Nov 14 '22 01:11 ZwwWayne

Thanks for your kind suggestion. We will try to fix the orders. Do you think the orders below works for you?

  1. config, if it has
  2. model state_dict
  3. dataset

Thanks a lot. Yes, I think this order is more intuitive.

sanbuphy avatar Nov 14 '22 01:11 sanbuphy