Skip to content
This repository has been archived by the owner on Sep 18, 2024. It is now read-only.

fix model compression config validation #2033

Merged
merged 2 commits into from
Feb 14, 2020
Merged

Conversation

Cjkkkk
Copy link
Contributor

@Cjkkkk Cjkkkk commented Feb 11, 2020

fix model compression config validation.
rules:
only check op_types and op_names if they are in config file, skip checking otherwise.

@QuanluZhang QuanluZhang changed the base branch from master to v1.4 February 11, 2020 08:59
if layer.type not in config['op_types']:
# expand config if key `default` is in config['op_types']
if 'op_types' in config and 'default' in config['op_types']:
config['op_types'].extend(default_layers.weighted_modules)
Copy link
Contributor

Choose a reason for hiding this comment

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

better to remove 'default' after it is expanded.

Copy link
Contributor Author

@Cjkkkk Cjkkkk Feb 12, 2020

Choose a reason for hiding this comment

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

I think it is best to just skip checking 'default' in op_types.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

fixed.

@Cjkkkk Cjkkkk requested a review from chicm-ms February 13, 2020 04:35
@chicm-ms chicm-ms merged commit fb5ef93 into microsoft:v1.4 Feb 14, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants