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

EfficientAD 师生网络可以降低训练显存占用吗? #18

Open
StarShang opened this issue Jan 30, 2024 · 0 comments
Open

EfficientAD 师生网络可以降低训练显存占用吗? #18

StarShang opened this issue Jan 30, 2024 · 0 comments

Comments

@StarShang
Copy link

StarShang commented Jan 30, 2024

我看efficientAD里面的师生网络在训练的时候 占用了大量显存,为了降低显存,可以把前向传播前两次student网络的梯度计算属性置为false吗? 我写了一个demo代码 像下面这样:
32362d8d080c837d7500d6909ee66e0
为了 在pytorch训练这个师生网络的时候 不占显存 , 把红框中的改为绿框中的,也就是本来前向传播三次student网络,现在只保留最后一次的梯度计算属性,这样有问题吗?

@StarShang StarShang changed the title 师生网络显存 EfficientAD 师生网络可以降低训练显存占用吗? Jan 30, 2024
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

1 participant