code: def __init__(self, requires_grad=False):
      super(Vgg16, self).__init__()
      vgg_pretrained_features = models.vgg16(
          weights=VGG16_Weights.IMAGENET1K_V1
      ).features
      self.slice1 = torch.nn.Sequential()
      self.slice2 = torch.nn.Sequential()
      self.slice3 = torch.nn.Sequential()
      self.slice4 = torch.nn.Sequential()
      for x in range(4):
          self.slice1.add_module(str(x), vgg_pretrained_features[x])
      for x in range(4, 9):
          self.slice2.add_module(str(x), vgg_pretrained_features[x])
      for x in range(9, 16):
          self.slice3.add_module(str(x), vgg_pretrained_features[x])
      for x in range(16, 23):
          self.slice4.add_module(str(x), vgg_pretrained_features[x])
      if not requires_grad:
          for param in self.parameters():
              param.requires_grad = False
  
file_path: ignite/examples/fast_neural_style/vgg.py
imports: from collections import namedtuple
  import torch
  from torchvision import models
  from torchvision.models.vgg import VGG16_Weights
label_desc: Use image node_id 1 to create a new Vgg16 object from inherited base classes: torch.nn with example: obj = Vgg16(requires_grad)