Skip to content

Commit

Permalink
Update on "[FX] Fix submodule naming for subgraph split"
Browse files Browse the repository at this point in the history
Submodules copied into a partition were using only the last atom in the qualified name, which caused problems when different Modules with the same last atom are put into the same Partition. Use the full qualname with underscores instead

Differential Revision: [D24925283](https://our.internmc.facebook.com/intern/diff/D24925283)

[ghstack-poisoned]
  • Loading branch information
James Reed committed Nov 12, 2020
1 parent 03b17af commit 85ddd4b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/test_fx_experimental.py
Original file line number Diff line number Diff line change
Expand Up @@ -538,7 +538,7 @@ def test_subgraph_trivial_resnet(self):
m = resnet18()
traced = symbolic_trace(m)
a = torch.rand(64, 3, 7, 7)
module_with_submodules = split_module(traced,m,lambda node: 0)
module_with_submodules = split_module(traced, m, lambda node: 0)
module_with_submodules(a)

def test_traceable_function_with_nonstandard_name(self):
Expand Down

0 comments on commit 85ddd4b

Please sign in to comment.