Skip to content

Check class_id validity in DetectionDataset#1536

Merged
Louis-Dupont merged 11 commits into
masterfrom
feature/SG-868-add_exception_when_classid_not_valid
Oct 17, 2023
Merged

Check class_id validity in DetectionDataset#1536
Louis-Dupont merged 11 commits into
masterfrom
feature/SG-868-add_exception_when_classid_not_valid

Conversation

@Louis-Dupont

@Louis-Dupont Louis-Dupont commented Oct 16, 2023

Copy link
Copy Markdown
Contributor

2 checks were added to make sure class_id is in the range of (0, num_classes-1)

  • DetectionDataset: added a check when loading annotations and raise an exception if this happens
  • YoloDarknetDataset: add a check when parsing.

@Louis-Dupont
Louis-Dupont marked this pull request as ready for review October 17, 2023 07:36
Comment thread src/super_gradients/training/datasets/detection_datasets/detection_dataset.py Outdated

@BloodAxe BloodAxe left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Louis-Dupont
Louis-Dupont merged commit db39011 into master Oct 17, 2023
@Louis-Dupont
Louis-Dupont deleted the feature/SG-868-add_exception_when_classid_not_valid branch October 17, 2023 13:41
Louis-Dupont added a commit that referenced this pull request Oct 17, 2023
* first draft

* fix

* fix

* fix detectiondataset

* Ensure that `checkpoint_num_classes` is propagated from YAML to model (#1533)

* Ensure that `checkpoint_num_classes` is propagated from YAML to models.get()

* Red checkpoint_num_classes via get_params

* Fixed a bug in export() that prevented to export model for BS>1 (#1530)

* Remove unnecessary files (#1540)

* remove check on base class

---------

Co-authored-by: Eugene Khvedchenya <ekhvedchenya@gmail.com>
Louis-Dupont added a commit that referenced this pull request Oct 18, 2023
* first draft

* fix

* fix

* fix detectiondataset

* Ensure that `checkpoint_num_classes` is propagated from YAML to model (#1533)

* Ensure that `checkpoint_num_classes` is propagated from YAML to models.get()

* Red checkpoint_num_classes via get_params

* Fixed a bug in export() that prevented to export model for BS>1 (#1530)

* Remove unnecessary files (#1540)

* remove check on base class

---------

Co-authored-by: Eugene Khvedchenya <ekhvedchenya@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants