Hi,
For vgg-16 available in torchvision.models when you call list(vgg16_model.children())[:-1] it will remove whole nn.Sequential defined as following:
Sequential(
  (0): Linear(in_features=25088, out_features=4096, bias=True)
  (1): ReLU(inplace=True)
  (2): Dropout(p=0.5, inplace=False)
  (3): Linear(in_features=4096, out_features=4096, bias=True)
  (4): ReLU(inplace=True)
  (5): Dropout(p=0.5, inplace=False)
  (6): Linear(in_features=4096, out_features=1000, bias=True)

So it will also remove layer generating your feature vector (4096-d). You have to remove layers from nn.Sequential block given above. Like,
vgg16_model = models.vgg16(pretrained=True)
vgg16_model.classifier = vgg16_model.classifier[:-1] # vgg16_model.classifier is nn.Sequential block.