Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

Commit

Permalink
modifying pre/post-partition declaration
Browse files Browse the repository at this point in the history
  • Loading branch information
mseth10 committed Aug 16, 2019
1 parent 6667bce commit df67ed0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/c_api/c_api_symbolic.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1200,11 +1200,11 @@ int MXOptimizeForBackend(SymbolHandle sym_handle,
for (auto property : subgraph_prop_list) {
nnvm::Graph g = orig_g;
property->SetAttr("graph", g);
property->PrePartition();
property->PrePartition(g);
g.attrs["subgraph_property"] = std::make_shared<nnvm::any>(property);
g = ApplyPass(std::move(g), "BuildSubgraph");
g.attrs.erase("subgraph_property");
property->PostPartition();
property->PostPartition(g);
property->RemoveAttr("graph");
s->outputs = g.outputs;
}
Expand Down
4 changes: 2 additions & 2 deletions src/operator/subgraph/subgraph_property.h
Original file line number Diff line number Diff line change
Expand Up @@ -221,9 +221,9 @@ class SubgraphProperty {
return nullptr;
}

virtual PrePartition() {}
virtual void PrePartition(const nnvm::Graph g) {}

virtual PostPartition() {}
virtual void PostPartition(const nnvm::Graph g) {}

virtual SubgraphSelectorV2Ptr CreateSubgraphSelectorV2() const {
auto v1_ptr = CreateSubgraphSelector();
Expand Down

0 comments on commit df67ed0

Please sign in to comment.