open-mmlab / labelbee-client

Out-of-the-box Annotation Toolbox
Apache License 2.0
382 stars 51 forks source link

category id is different in different project when export annotation results #18

Closed xiefeifeihu closed 2 years ago

xiefeifeihu commented 2 years ago

Bug1:不同的项目下设置的attribute相同(在json里指定id也无效),导出coco标注时发现category的id顺序各不相同; Bug2:且id跳过了1,只有0、2、3、4等。 Bug3:导出文件里应该是categories,而不应该是category

Windows和Ubuntu下的client结果相同。

顺序错乱会导致在预先分配好的数据集中标注时无法使用。

Windows和Ubuntu下的client结果相同。

attribute: [ { "id": 1, "key": "AAA", "value": "AAA" }, { "id": 2, "key": "BBB", "value": "BBB" } ]

各图片都已标注完整的属性,除了0(No Attribute)。 微信图片_20220329111551

project A: "category": [ { "id": 0, "name": "", "supercategory": "" }, { "id": 2, "name": "AAA", "supercategory": "" }, { "id": 3, "name": "BBB", "supercategory": "" }......

priject B: "category": [ { "id": 0, "name": "", "supercategory": "" }, { "id": 2, "name": "BBB", "supercategory": "" }, { "id": 3, "name": "AAA", "supercategory": "" }......

微信图片_20220329110704

Glenfiddish commented 2 years ago

不同的项目下设置的attribute相同(在json里指定id也无效),导出coco标注时发现category的id顺序各不相同;且id跳过了1,只有0、2、3、4等。

顺序错乱会导致在预先分配好的数据集中标注时无法使用。

能给一个出期待的输入和输出例子吗?

xiefeifeihu commented 2 years ago

期望的输入输出:若attribute设置中指定了id,则按id导出。若不指定id,则由系统自动决定。 若设置attribute的id时违反规则,系统自动修正,并给出提示。

Kerwin-L commented 2 years ago

期望的输入输出:若attribute设置中指定了id,则按id导出。若不指定id,则由系统自动决定。 若设置attribute的id时违反规则,系统自动修正,并给出提示。

这边还是按照配置中属性数组数据来生成 id,只要是相同配置,导出 coco 格式的 categories 会统一。attribute 内设置 id 的方式后续我们再考虑如何提供更多的自定义,这个 issue 暂时先关闭,可下载 v0.1.2 版本体验使用