code: def resnet18(**kwargs):
      """Constructs a ResNet-18 model."""
      model = ResNet(BasicBlock, [2, 2, 2, 2], **kwargs)
      return model
  
imports: import torch
  import torch.nn
  import torch.nn.functional
  from torch.autograd import Variable
  import math
  from functools import partial
label_desc: Use image node_id 4 for calling a global function with example usage: resnet18() and returns: model