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

[Improvement] Update SubnetValLoop #465

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

twmht
Copy link
Contributor

@twmht twmht commented Feb 26, 2023

Thanks for your contribution and we appreciate it a lot. The following instructions would make your pull request more healthy and more easily get feedback. If you do not understand some items, don't worry, just make the pull request and seek help from maintainers.

Motivation

set_max_subnet or set_min_subnet was not found in dev-1.x, so we need to have a fix for that.

and also we need to have the feature to define what kind of subnet we want to evaluate.

In addition, we can specify None to resource estimator since its typing is Optional.

Modification

  1. Fix set_max_subnet or set_min_subnet not found exception
  2. Add the fleibility to define custom subnet kinds
  3. Support to specifiy None with ResorceEstimator
  4. Add UnitTest

BC-breaking (Optional)

Does the modification introduce changes that break the backward compatibility of the downstream repositories?
If so, please describe how it breaks the compatibility and how the downstream projects should modify their code to keep compatibility with this PR.

Use cases (Optional)

If this PR introduces a new feature, it is better to list some use cases here and update the documentation.

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 tests 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.

@gaoyang07 gaoyang07 self-requested a review February 27, 2023 03:06
Copy link
Contributor

@gaoyang07 gaoyang07 left a comment

Choose a reason for hiding this comment

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

Merge the latest dev-1.x to solve the conflict.

mmrazor/engine/runner/subnet_val_loop.py Outdated Show resolved Hide resolved
tests/test_engine/test_runner/test_subnet_val_loop.py Outdated Show resolved Hide resolved
mmrazor/engine/runner/subnet_val_loop.py Show resolved Hide resolved
@gaoyang07
Copy link
Contributor

Fix lint.

@twmht twmht force-pushed the fix_nas branch 2 times, most recently from 88bbb69 to 266de9f Compare March 11, 2023 13:42
@codecov
Copy link

codecov bot commented Mar 11, 2023

Codecov Report

Patch coverage: 38.88% and project coverage change: +0.17 🎉

Comparison is base (9446b30) 79.32% compared to head (266de9f) 79.49%.

❗ Current head 266de9f differs from pull request most recent head b5bd199. Consider uploading reports for the commit b5bd199 to get more accurate results

Additional details and impacted files
@@             Coverage Diff             @@
##           dev-1.x     #465      +/-   ##
===========================================
+ Coverage    79.32%   79.49%   +0.17%     
===========================================
  Files          280      280              
  Lines        14096    14094       -2     
  Branches      2155     2156       +1     
===========================================
+ Hits         11181    11204      +23     
+ Misses        2452     2422      -30     
- Partials       463      468       +5     
Flag Coverage Δ
unittests 79.49% <38.88%> (+0.17%) ⬆️

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

Impacted Files Coverage Δ
mmrazor/engine/runner/subnet_val_loop.py 72.91% <38.88%> (+48.91%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@twmht twmht force-pushed the fix_nas branch 2 times, most recently from 77a59a9 to f4cdfe5 Compare March 14, 2023 13:31
@twmht
Copy link
Contributor Author

twmht commented Mar 14, 2023

@gaoyang07

The failed test seems not related to this PR?

@gaoyang07 gaoyang07 changed the title Fix bug and improve subnet val loop [Improvement] Update SubnetValLoop Mar 22, 2023
1.Fix set_max_subnet or set_min_subnet not found exception
2 Add the fleibility to define custom subnet kinds
3.Support to specifiy None with ResorceEstimator

Signed-off-by: Ming-Hsuan-Tu <qrnnis2623891@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.

None yet

2 participants