MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / TEST_F

Function TEST_F

src/opr/test/loop/elemwise_grad.cpp:61–68  ·  view source on GitHub ↗

y = x */

Source from the content-addressed store, hash-verified

59
60/* y = x */
61TEST_F(TestOprLoopElemwiseGrad, Identity) {
62 desc_maker = [this](LoopDesc& desc) {
63 auto x = desc.add_input(this->x);
64 desc.set_loop_condition(desc.get_counter_var() < 0);
65 desc.add_output(x, OutputMode::LAST);
66 };
67 check([](float) { return 1.f; });
68}
69
70/* y = sum(x, 1 <= i <= N) */
71TEST_F(TestOprLoopElemwiseGrad, UpdateWithSimpleSum) {

Callers

nothing calls this directly

Calls 8

get_counter_varMethod · 0.80
add_input_assignableMethod · 0.80
assignMethod · 0.80
renameMethod · 0.80
checkFunction · 0.50
powFunction · 0.50
add_inputMethod · 0.45
add_outputMethod · 0.45

Tested by

no test coverage detected