On a similar case I am not realizing that how are these different:
Method (1):
class new_m(torch.nn.Module):
def __init__(self):
    super(new_m, self).__init__()
    Model = models.mobilenet_v2(args).cuda()
    self.network1=Model.features
    self.network2=Model.classifier
def forward(self, x):
    for ii,model in enumerate(self.network1):
        x = model(x)
    x=self.network4(x)

`
Gives correct result,
whereas
Method (2):
class new_m(torch.nn.Module): 
def __init__(self):
 super(new_m, self).__init__()
 Model = models.mobilenet_v2(args).cuda()
self.network1=list(Model.features)
 self.network2=Model.classifier
def forward(self, x):
    for ii,model in enumerate(self.network1):
       ` x = model(x)`

    x=self.network4(x)

Doesn’t give the correct result. Which has only one change at Model.features
Why is listing the layers create the problem?