ryouchinsa / Rectlabel-support

RectLabel is an offline image annotation tool for object detection and segmentation.
https://rectlabel.com
515 stars 73 forks source link

Hyphen in object names causes Alert on "Export COCO JSON file" #256

Open areyasouka opened 5 months ago

areyasouka commented 5 months ago

Adding an object name/category with a hyphen or dash "-" triggers an Alert when "Export COCO JSON file":

image

ryouchinsa commented 5 months ago

Thanks for writing the issue.

If at lease one object name uses attributes, ’-‘ is used as a separator so that ‘-‘ in the object name and attribute name is replaced with ‘_’. 4T-Truck is converted to 4T_Truck when you selected the object name.

If you do not have to use attributes, please remove all attributes from attributes table. In this case, 4T-Truck can be used as it is. https://rectlabel.com/settings/#attributes

Update: Please check off all attributes on the objects tab.

attributes

areyasouka commented 5 months ago

Looks like the Object Name is truncated after the hyphens after "Open folder": "Drill-Jumbo" (pascal .xml) -> "Drill" (RectLabel) image

ryouchinsa commented 5 months ago

Thanks for the detailed information.

Looking at your objects table, how did you set up the objects table?

areyasouka commented 5 months ago

Originally Object Name was manually typed and saved. Then later loaded from individual xml files for each image on "Open folder". Thanks for your help.

ryouchinsa commented 5 months ago

If you typed Drill-Jumbo on the objects table at first, when did RectLabel change the Drill-Jumbo to Drill on the objects table? To reproduce the problem, we have to know the detailed steps.

  1. Those xml files are annotated by another tool.
  2. You typed the object name on the objects table on RectLabel.
  3. You opened the images/xmls folders on RectLabel.

Update: How about removing all object names on the objects table, and Export menu -> Import object names from all xml files? We think the objects table will be configured correctly including Drill-Jumbo.