How to fuse BasicWriter semantic standard classes "UNLABELLED" and "BACKGROUND" to one class?

Hey there,

I noticed that my semantic labels contain two semantic classes for the “Default” class, which both get generated automatically. The UNLABELLED class is used, when Props simply have no label assigned and the BACKGROUND class represents the space where there is realy nothing. Is it possible to fuse those two classes together, as I don’t want to separate them and I want both together as my “Default” class. Do I need to write a custom Writer for this?

I initialize my BasicWriter like this:

writer = rep.WriterRegistry.get("BasicWriter")
    writer.initialize( output_dir="output_dir", rgb=True, semantic_segmentation=True, colorize_semantic_segmentation=False, semantic_types=['Label'])

Thanks in advance.

Hi @Braveblacklion , you can create your own writer, following the example of BasicWriter
At basicwriter line 413 semantic_seg_data = data[annotator]["data"], you can change to

semantic_seg_data = data[annotator]["data"]
semantic_seg_data[semantic_seg_data == 1] = 0

And change the id_to_labels

id_to_labels = data[annotator]["info"]["idToLabels"]
del id_to_labels[0]
del id_to_labels[1]
id_to_labels[0] = "DEFAULT