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

Freezing Pruned weights smaller than 1e-6 #5

Open
yuezhixiong opened this issue May 7, 2020 · 3 comments
Open

Freezing Pruned weights smaller than 1e-6 #5

yuezhixiong opened this issue May 7, 2020 · 3 comments

Comments

@yuezhixiong
Copy link

yuezhixiong commented May 7, 2020

In main.py
#Freezing Pruned weights by making their gradients Zero
grad_tensor = np.where(tensor < EPS, 0, grad_tensor)

Does this also freeze the weights that have negative values? More than just weights with 0 values?

@xiaosaisworking
Copy link

I think it's really a bug. Once solving this problem, my experiment results can reach the original performance in the first iteration(pruning has not started). Hope to help you!

@JaminLi
Copy link

JaminLi commented Sep 28, 2020

I think it's really a bug. Once solving this problem, my experiment results can reach the original performance in the first iteration(pruning has not started). Hope to help you!

I also meet this problem, my experiment results can't reach the original performance. How can I solve this problem with the "grad_tensor = np.where(tensor < EPS, 0, grad_tensor)" , please?

@zdhNarsil
Copy link

@JaminLi I think it should be grad_tensor = np.where(tensor.abs() < EPS, 0, grad_tensor).

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

No branches or pull requests

4 participants