isl-org / isl-org/Open3D-ML

Is class numbering with gaps supported for training on custom datasets?

Open
#669 1 comment 1 reaction 0 assignees View on GitHub
question
Dominant language
Python
Stars
2.3k
Forks
365
Avg merge
4h 6m
Merged PRs (30d)
1

Description

### Checklist

- [X] I have searched for [similar issues](https://github.com/isl-org/Open3D-ML/issues).
- [X] I have tested with the [latest development wheel](http://www.open3d.org/docs/latest/getting_started.html#development-version-pip).
- [X] I have checked the [release documentation](http://www.open3d.org/docs/release/) and the [latest documentation](http://www.open3d.org/docs/latest/) (for `main` branch).

### My Question

Hi,

I have data following the standard Las classification, meaning that some indices are unused or reserved. If possible I would like to use this data directly and only configure dataset and pipeline to handle the class to index mapping.
I am fine-tuning a KP-Conv model with the output layer modified to fit our number of classes.

From the CustomDataset3D [label_to_index](https://github.com/isl-org/Open3D-ML/blob/b64b51445bf2fdb17f7de4fd7a1c383ac238a3dc/ml3d/datasets/customdataset.py#L115) - template I assume that a mapping from a arbitrary class number to the consecutive output-channel index is somehow supported.

When running the training pipeline, I get an index out of bounds error [here](https://github.com/isl-org/Open3D-ML/blob/b64b51445bf2fdb17f7de4fd7a1c383ac238a3dc/ml3d/torch/modules/losses/semseg_loss.py#L35), since the 'label' == 65 is greater than my number of classes.

It is not a big deal to write the processing to re-index the class numbers. I am just wondering: is this functionality is actually supported? And, I am missing something completely?

Thanks in advance for any support

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.