Megvii-BaseDetection / YOLOX

YOLOX is a high-performance anchor-free YOLO, exceeding yolov3~v5 with MegEngine, ONNX, TensorRT, ncnn, and OpenVINO supported. Documentation: https://yolox.readthedocs.io/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to set background image in training ?

sz2three opened this issue · comments

I have two classes ( classA:1, classB:2) in my custom images. Now there are some other images without any bboxes, should I use these images as background images?
And How to do the settings (For example, how to define the class index ? should it be 0 ? )

Thank you.

In coco format, json files have the following dictionaries dict_keys(['images', 'type', 'annotations', 'categories']) . For background images without any target objects in them, you can define the image properties in images dictionary and leave the annotations part empty for that image id. You don't need to set a new class id for background images.

@hcmea Thank you so much for your reply. Will YOLOX use these images withou any bboxes in training for some operations?

@le02146 In my application I added background images to my training data as well to help model discriminate background images from target objects. In my case there was only one target object.