Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bugfix - ignore subsets of near-zero-ratio #187

Merged
merged 5 commits into from
Mar 26, 2021

Conversation

jihyeonyi
Copy link

@jihyeonyi jihyeonyi commented Mar 25, 2021

Summary

When dataset size is 5 and split ratio is [train=0.1, val=0.9, test=0.0], the splitter splits the dataset into [1, 3, 1] instead of [1, 4, 0].
This is a special case of incorrect partitioning due to the inexact round function of python.
So I fix this bug by ignoring subsets with a near-zero ratio.

How to test

Checklist

License

  • I submit my code changes under the same MIT License that covers the project.
    Feel free to contact the maintainers if that's a concern.
  • I have updated the license header for each file (see an example below)
# Copyright (C) 2020 Intel Corporation
#
# SPDX-License-Identifier: MIT

@jihyeonyi jihyeonyi added the BUG Something isn't working label Mar 25, 2021
Copy link
Author

@jihyeonyi jihyeonyi left a comment

Choose a reason for hiding this comment

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

Thank you for the modification.
It looks better.

@zhiltsov-max zhiltsov-max merged commit 246fdf5 into develop Mar 26, 2021
@zhiltsov-max zhiltsov-max deleted the kate/splitter-handling-zero-ratio branch March 26, 2021 09:55
zhiltsov-max pushed a commit that referenced this pull request Mar 31, 2021
* bugfix - ignore subsets of near-zero-ratio (#187)

* Ignore subsets of near-zero-ratio in splitter

Co-authored-by: Maxim Zhiltsov <[email protected]>

* Fix validator imbalance threshold (#190)

* Validator threshold adjustment + style correction

Co-authored-by: Maxim Zhiltsov <[email protected]>

* Allow undeclared label attributes on CVAT format (#192)

* Add saving and parsing of attributes in label categories in Datumaro format

* Support common label attributes in CVAT format, add an option to ignore undeclared attributes

* Add logging for parsed parameters in plugins

* update changelog

* Fix export of masks with holes (#188)

* Fix export of masks with holes in polygons (background class should not introduce a new instance)

* update changelog

* Format fixes in COCO and VOC (#195)

* Allow splitting and merging of image directories in COCO export

* Avoid producing conflicting attributes in VOC segmentation

Co-authored-by: Jihyeon Yi <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
BUG Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants