Skip to content

A set of tools for converting a darknet dataset to COCO format working with YOLOX

License

Notifications You must be signed in to change notification settings

lixiangMindSpore/YOLO2COCO

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

59 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

darknet格式数据→COCO

  • darknet训练数据目录结构(详情参见dataset/darknet):

    darknet
    ├── class.names
    ├── gen_config.data
    ├── gen_train.txt
    ├── gen_valid.txt
    └── images
        ├── train
        └── valid
    
  • 转换

    python darknet2coco.py --data_path dataset/darknet/gen_config.data

YOLOV5格式数据→COCO

  • YOLOV5训练格式目录结构(详情参见dataset/YOLOV5):

    YOLOV5
    ├── classes.txt
    ├── xxxx
    │   ├── images
    │   └── labels
    ├── train.txt
    └── val.txt
    
  • 转换

    python yolov5_2_coco.py --dir_path dataset/YOLOV5

可视化COCO格式标注格式

python coco_visual.py --vis_num 1 \
                      --json_path dataset/YOLOV5_COCO_format/annotations/instances_train2017.json \
                      --img_dir dataset/YOLOV5_COCO_format/train2017

相关资料

About

A set of tools for converting a darknet dataset to COCO format working with YOLOX

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%