Skip to content

Commit

Permalink
fix cpp test
Browse files Browse the repository at this point in the history
  • Loading branch information
masahi committed Jan 14, 2021
1 parent edc0ed8 commit f0bf54c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion python/tvm/relay/op/op.py
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ def register_shape_func(op_name, data_dependant, shape_func=None, level=10):
op_name : str
The name of the op.
data_dependant : bool
data_dependant : bool or list of bool
Whether the shape function depends on input data.
shape_func : function (attrs: Attrs, inputs: List[Tensor], out_ndims: List[IndexExpr])
Expand Down
4 changes: 3 additions & 1 deletion tests/cpp/relay_build_module_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,9 @@ TEST(Relay, BuildModule) {
}
auto fgeneric = GenericFunc::Get("test.strategy_generic").set_default(*fs);
(*reg)("add", "FTVMStrategy", fgeneric, 10);
(*reg)("add", "TShapeDataDependant", {0}, 10);
Array<Integer> dep;
dep.push_back(0);
(*reg)("add", "TShapeDataDependant", dep, 10);
// build
auto pfb = tvm::runtime::Registry::Get("relay.build_module._BuildModule");
tvm::runtime::Module build_mod = (*pfb)();
Expand Down

0 comments on commit f0bf54c

Please sign in to comment.