MCPcopy Create free account
hub / github.com/alibaba/MNN / onGrad

Method onGrad

tools/train/source/grad/ZeroGrad.cpp:19–24  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

17 mType = LINEAR;
18 }
19 virtual std::vector<Express::VARP> onGrad(Express::EXPRP expr,
20 const std::vector<Express::VARP>& backwardOutput) override {
21 std::vector<Express::VARP> result(1, nullptr);
22 result[0] = backwardOutput[0];
23 return result;
24 }
25};
26static void _create() {
27 static ZeroGrad _c;

Callers 15

gradCommonMethod · 0.45
runMethod · 0.45
checkResultMethod · 0.45
checkResultMethod · 0.45
runMethod · 0.45
runMethod · 0.45
runMethod · 0.45
runMethod · 0.45
runMethod · 0.45
runMethod · 0.45
runMethod · 0.45
runMethod · 0.45

Calls

no outgoing calls

Tested by 14

runMethod · 0.36
checkResultMethod · 0.36
checkResultMethod · 0.36
runMethod · 0.36
runMethod · 0.36
runMethod · 0.36
runMethod · 0.36
runMethod · 0.36
runMethod · 0.36
runMethod · 0.36
runMethod · 0.36
runMethod · 0.36