Skip to content

Commit

Permalink
Raise error if no operators are found in GraphTuner
Browse files Browse the repository at this point in the history
  • Loading branch information
tkonolige committed Jul 27, 2020
1 parent abc52aa commit 5828501
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions python/tvm/autotvm/graph_tuner/base_graph_tuner.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,9 @@ def __init__(self, graph, input_shapes, records, target_ops,

self._graph = graph
self._in_nodes_dict = get_in_nodes(self._node_list, self._target_ops, input_shapes.keys())
if len(self._in_nodes_dict) == 0:
raise RuntimeError("Could not find any input nodes with whose "
"operator is one of %s" % self._target_ops)
self._out_nodes_dict = get_out_nodes(self._in_nodes_dict)
self._fetch_cfg()
self._opt_out_op = OPT_OUT_OP
Expand Down

0 comments on commit 5828501

Please sign in to comment.