Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Sin3DM/Sin3DM
/ zero_grad
Method
zero_grad
src/diffusion/fp16_util.py:173–174 ·
view source on GitHub ↗
(self)
Source
from the content-addressed store, hash-verified
171
self.model.convert_to_fp16()
172
173
def
zero_grad(self):
174
zero_grad(self.model_params)
175
176
def
backward(self, loss: th.Tensor):
177
if
self.use_fp16:
Callers
2
forward_backward
Method · 0.80
update_network
Method · 0.80
Calls
1
zero_grad
Function · 0.85
Tested by
no test coverage detected