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

Fix seed when test apoz pruner #4580

Merged
merged 3 commits into from
Feb 28, 2022
Merged

Fix seed when test apoz pruner #4580

merged 3 commits into from
Feb 28, 2022

Conversation

J-shang
Copy link
Contributor

@J-shang J-shang commented Feb 24, 2022

Description

Based on pruning by the threshold, we may have this situation, metrics = [0, 0, 1, 1, 2, 2], pruning 50%, then threshold=1 and 4 position will be masked, the real sparsity is 66.7%.

Apoz is easy to have repeated values in metrics when layer weight size is small.

To fix this issue by fixing seed.

TODO: Pruner needs to handle the metric equal to threshold more carefully.

@J-shang J-shang closed this Feb 28, 2022
@J-shang J-shang reopened this Feb 28, 2022
@J-shang J-shang merged commit 268215a into microsoft:master Feb 28, 2022
@J-shang J-shang mentioned this pull request Mar 23, 2022
51 tasks
@J-shang J-shang deleted the fix-ut branch April 19, 2022 02:18
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