code: def init_net(net, init_type="normal", init_gain=0.02, gpu_ids=[]):
      if len(gpu_ids) > 0:
          assert torch.cuda.is_available()
          net.to(gpu_ids[0])
          net = torch.nn.DataParallel(net, gpu_ids)
      init_weights(net, init_type, gain=init_gain)
      return net
  
imports: import torch
  from torch.nn import init
label_desc: Use image node_id 2 for calling a global function with example usage: init_net(net, init_type, init_gain, gpu_ids) and returns: net