mmrazor icon indicating copy to clipboard operation
mmrazor copied to clipboard

[Improvement] Update `SubnetValLoop`

Open twmht opened this issue 1 year ago • 3 comments

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:

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

After PR:

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

twmht avatar Feb 26 '23 12:02 twmht