By using nn.Sequential, invoking __call__ method of an nn.Model object in PyTorch can call more than two forward functions.
However, current implementation of inference engine does not consider such cases.
This PR fixes this behavior by changing the type of subroutine_node attribute of InferenceEngine from Dict[gast.Call, gast.FunctionDef] to Dict[gast.Call, List[gast.FunctionDef]].
By using
nn.Sequential
, invoking__call__
method of annn.Model
object in PyTorch can call more than twoforward
functions. However, current implementation of inference engine does not consider such cases. This PR fixes this behavior by changing the type ofsubroutine_node
attribute ofInferenceEngine
fromDict[gast.Call, gast.FunctionDef]
toDict[gast.Call, List[gast.FunctionDef]]
.