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

Fix bug when using ClassBalancedDataset #555

Merged
merged 8 commits into from
Nov 26, 2021

Conversation

Ezra-Yu
Copy link
Collaborator

@Ezra-Yu Ezra-Yu commented Nov 24, 2021

Motivation

Fix bug when using dataset wrapper, refer to #514

Modification

Please briefly describe what modification is made in this PR.

Checklist

Before PR:

  • Pre-commit or other linting tools are used to fix the potential lint issues.
  • Bug fixes are fully covered by unit tests, the case that causes the bug should be added in the unit tests.
  • The modification is covered by complete unit tests. If not, please add more unit test to ensure the correctness.
  • The documentation has been modified accordingly, like docstring or example tutorials.

After PR:

  • If the modification has potential influence on downstream or other related projects, this PR should be tested with those projects, like MMDet or MMSeg.
  • CLA has been signed and all committers have signed the CLA in this PR.

@Ezra-Yu Ezra-Yu changed the title Fix bug when using dataset warpper Fix bug when using ClassBalancedDataset Nov 24, 2021
@Ezra-Yu Ezra-Yu requested a review from mzr1996 November 24, 2021 12:00
@codecov
Copy link

codecov bot commented Nov 24, 2021

Codecov Report

Merging #555 (c695350) into master (2266a59) will increase coverage by 0.03%.
The diff coverage is 88.88%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #555      +/-   ##
==========================================
+ Coverage   79.88%   79.91%   +0.03%     
==========================================
  Files         107      107              
  Lines        6095     6100       +5     
  Branches      988      988              
==========================================
+ Hits         4869     4875       +6     
+ Misses       1094     1093       -1     
  Partials      132      132              
Flag Coverage Δ
unittests 79.91% <88.88%> (+0.03%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
mmcls/datasets/multi_label.py 78.94% <66.66%> (+0.56%) ⬆️
mmcls/datasets/base_dataset.py 93.18% <100.00%> (+1.22%) ⬆️
mmcls/datasets/imagenet21k.py 82.43% <100.00%> (+0.74%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2266a59...c695350. Read the comment docs.

mmcls/datasets/base_dataset.py Outdated Show resolved Hide resolved
@Ezra-Yu Ezra-Yu requested a review from mzr1996 November 25, 2021 10:05
Copy link
Member

@mzr1996 mzr1996 left a comment

Choose a reason for hiding this comment

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

LGTM

@mzr1996 mzr1996 merged commit 4b2128f into open-mmlab:master Nov 26, 2021
@Ezra-Yu Ezra-Yu deleted the fix-dataset-warpper branch July 18, 2022 08:45
mzr1996 pushed a commit to mzr1996/mmpretrain that referenced this pull request Nov 24, 2022
* fix dataset wrapper bug and add unit tests

* fix dataset wrapper bug and add unit tests

* update unit tests

* fix lint

* align interface to mmdet

* update unit tests
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