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

add exclude config validate in compressor #3815

Merged
merged 11 commits into from
Jul 12, 2021

Conversation

J-shang
Copy link
Contributor

@J-shang J-shang commented Jun 11, 2021

No description provided.

@J-shang J-shang marked this pull request as draft June 15, 2021 00:52
@J-shang J-shang marked this pull request as ready for review June 23, 2021 01:19
@zheng-ningxin
Copy link
Contributor

Do we have a documentation to describe the config interface of the pruner? Shall we give an example/unit test?

@@ -3,8 +3,9 @@

import logging
import copy
from nni.utils import OptimizeMode
Copy link
Contributor

Choose a reason for hiding this comment

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

What is OptimizeMode for? seems not used?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes, seems a mistake, remove it.

}], model, _logger)

schema.validate(config_list)
for config in config_list:
if 'exclude' not in config and 'sparsity' not in config:
Copy link
Contributor

Choose a reason for hiding this comment

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

Only when both sparsity and op_types/op_names exists, this config is validate, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes, and you reminded me this way is not elegant, modify it.

@QuanluZhang QuanluZhang closed this Jul 9, 2021
@QuanluZhang QuanluZhang reopened this Jul 9, 2021
@QuanluZhang
Copy link
Contributor

@J-shang please fix pipeline errors

@J-shang
Copy link
Contributor Author

J-shang commented Jul 12, 2021

Do we have a documentation to describe the config interface of the pruner? Shall we give an example/unit test?

Yes, we have doc and ut, and add an exclude usecase in the example.

@zheng-ningxin zheng-ningxin merged commit 68644f5 into microsoft:master Jul 12, 2021
@J-shang J-shang deleted the fix-exclude branch August 5, 2021 12:09
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

3 participants