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

Function get_output_var_shape

src/core/test/graph/misc.cpp:88–94  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

86MGB_DEFINE_OPR_CLASS(
87 WorkspaceAllocTestOpr, cg::SingleCNOutshapePureByInshapeOprBase) // {
88 void get_output_var_shape(
89 const TensorShapeArray& inp_shape,
90 TensorShapeArray& out_shape) const override {
91 MGB_MARK_USED_VAR(inp_shape);
92 out_shape.at(0) = {2};
93 out_shape.at(1) = {3};
94 }
95
96 void scn_do_execute() override {
97 ASSERT_EQ(TensorShape{2}, output(0)->dev_tensor().shape());

Callers 6

infer_descMethod · 0.50
applyMethod · 0.50
performMethod · 0.50
get_output_var_shapeMethod · 0.50
performMethod · 0.50

Calls 1

atMethod · 0.45

Tested by

no test coverage detected