coco-eval-free and training with custom category

博客介绍了支持Nanodet项目的自定义类别COCO评估及训练方法。给出了相关项目链接,说明了在多个文件中修改代码以实现自定义类别多目标分类的COCO评估,如在coco.py、coco_detection.py、cocoeval.py中修改特定行代码,最后作者希望得到关注。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

coco-eval-free and training with custom category 
supporting Nanodet projects:

https://github.com/RangiLyu/nanodet/blob/main/nanodet/evaluator/coco_detection.py

coco eval by custom category to multi object classification

if category is two, then id index is [0,1], as following:
modified two lines in coco.py to training on line, while not change to label
117th line added

        # 2 classes label
        
        lablist=ann['labels']
        
        twolist=np.array([1 if i !=0 else i for i in lablist])
        
126th line modified

        gt_labels=twolist
        
original line: gt_labels=ann['labels']
modified the 26th line in coco_detection.py
self.cat_ids = [0, 1] ##Custom category index

original line: self.cat_ids = dataset.cat_ids
modified the 81th line in cocoeval.py
self.params.catIds = [0,1] #sorted(cocoGt.getCatIds())

original line: self.params.catIds = sorted(cocoGt.getCatIds())

If I can help you, please give me a star

my github: https://github.com/eeric/coco-eval-free

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值