Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/MegEngine/MegEngine
/ clear_grad
Method
clear_grad
imperative/python/test/unit/jit/test_tracing.py:873–875 ·
view source on GitHub ↗
(self)
Source
from the content-addressed store, hash-verified
871
return
x
872
873
def
clear_grad(self):
874
self.a.grad = None
875
self.b.grad = None
876
877
@partial_trace
878
def
fwd_only(a, b):
Callers
15
test_advance_indexing
Function · 0.45
test_advance_indexing_with_subtensor
Function · 0.45
train
Function · 0.45
update_model
Function · 0.45
test_load_state_dict_no_cache
Function · 0.45
test_save_load
Function · 0.45
run_dtr_resnet1202
Function · 0.45
run
Function · 0.45
test_xornet_trace_dump
Function · 0.45
train
Function · 0.45
func
Function · 0.45
runner
Function · 0.45
Calls
no outgoing calls
Tested by
no test coverage detected