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

Fix Scaffold #339

Merged
merged 4 commits into from
Nov 6, 2023
Merged

Fix Scaffold #339

merged 4 commits into from
Nov 6, 2023

Conversation

hua-zi
Copy link
Contributor

@hua-zi hua-zi commented Nov 3, 2023

Batchnorm层 的参数没有梯度,self.model_parameters 和 self.model_gradients 的 长度不一样

重新实现一个model_grads(), 根据named_parameters()得到state_dict()形状的参数梯度,没有梯度的参数 的 梯度设为0

@dunzeng dunzeng merged commit 7564726 into SMILELab-FL:master Nov 6, 2023
1 check passed
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.

2 participants