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

Fix v2 level pruner default config bug #4245

Merged

Conversation

Fiascolsy
Copy link
Contributor

This could let v2 level pruner work with config_list['op_types'] = 'default'

RandomWalkAlpha and others added 30 commits September 15, 2021 06:10
for config in config_list:
if 'op_types' in config:
if 'default' in config['op_types']:
from ..base.compressor import 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.

put this import to the top

for config in config_list:
if 'op_types' in config:
if 'default' in config['op_types']:
config['op_types'] = 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.

please using config['op_types'].remove('default') and config['op_types'].extend(weighted_modules) to avoid:
config = {'op_types': ['default', 'customized_layer']}

@QuanluZhang QuanluZhang merged commit abb4dfd into microsoft:master Oct 13, 2021
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.

4 participants