I am trying to use PyTorch to get the outputs from intermediate layers of AlexNet/VGG:
alexnet_model = models.alexnet(pretrained=True)
modules = list((alexnet_model).children())[:-1*int(depth)]
alexnet_model = nn.Sequential(*modules)

What is odd is that I get the same output values (i.e. the same exact model) when depth=1 and depth=2, and then the same output values for depth=3 all the way to depth=10. I observe this same phenomenon for VGG too. However, I don’t observe this for ResNet, which gives me different output values (i.e. different models) for all depths [1, 10].
Any ideas about what might be going on?