diff --git a/src/operator/subgraph/build_subgraph.cc b/src/operator/subgraph/build_subgraph.cc index 413395c3b74f..f95f1f4e670b 100644 --- a/src/operator/subgraph/build_subgraph.cc +++ b/src/operator/subgraph/build_subgraph.cc @@ -276,10 +276,6 @@ bool LabelSubgraph(const nnvm::Graph& g, SubgraphSelectorV2Ptr subgraph_selector if (excluded_node_id != -1) { CHECK_LT(excluded_node_id, static_cast(simple_nodes.size())); - CHECK_NE(excluded_node_id, static_cast(snid)) - << "A cycle is found in the computational graph between nodes " - << simple_nodes[excluded_node_id]->node->attrs.name << " and " - << simple_nodes[snid]->node->attrs.name; excluded_nodes->insert(simple_nodes[excluded_node_id].get()); ResetNodeLabels(g, simple_nodes, subgraph_nodes); return false;