code: def __init__(self):
      super().__init__()
      self.model = resnet18(pretrained=True)
      num_ftrs = self.model.fc.in_features
      # Here the size of each output sample is set to 37.
      self.model.fc = torch.nn.Linear(num_ftrs, 37)
      self.criterion = torch.nn.CrossEntropyLoss()
  
file_path: BigDL/python/nano/tutorial/training/pytorch-lightning/lightning_train_multi_instance.py
imports: import torch
  from torchvision import transforms
  from torchvision.datasets import OxfordIIITPet
  from torch.utils.data.dataloader import DataLoader
  import torch
  from torchvision.models import resnet18
  from bigdl.nano.pytorch import Trainer
  import pytorch_lightning
label_desc: Use image node_id 1 to create a new MyLightningModule object from inherited base classes: pl with example: obj = MyLightningModule()