DynamicMap_Benchmark icon indicating copy to clipboard operation
DynamicMap_Benchmark copied to clipboard

Incorrect label mapping in extract_semkitti.py

Open Sacha562 opened this issue 9 months ago • 1 comments

Hi,

In the KITTI dataset, only the lower parts of the int32s are used as labels.

I would suggest the following change (add & 0xFFFF) in extract_semkitti.py:

intensity[np.isin(labels & 0xFFFF, [252, 253, 254, 255, 256, 257, 258, 259])] = 1

This is also done in the SemanticKITTI API (evaluate_mos.py):

label = np.fromfile(label_file, dtype=np.int32)
label = label.reshape((-1))  # reshape to vector
label = label & 0xFFFF       # get lower half for semantics
if FLAGS.limit is not None:
label = label[:FLAGS.limit]  # limit to desired length
label = remap_lut[label]       # remap to xentropy format

Sacha562 avatar Apr 23 '25 15:04 Sacha562

https://github.com/KTH-RPL/DynamicMap_Benchmark/blob/a80a9a6fe7630953b826c616a24bc2fcf20b2889/scripts/py/utils/init.py#L36

I think it is correct here.

Kin-Zhang avatar Apr 23 '25 17:04 Kin-Zhang

This issue is stale because it has been open for 14 days with no activity. It will be closed if no further activity occurs.

github-actions[bot] avatar May 12 '25 11:05 github-actions[bot]