code: def train():
      model.train()
      optimizer.zero_grad()
      pos_z, neg_z, summary = model(data.x, data.edge_index)
      loss = model.loss(pos_z, neg_z, summary)
      loss.backward()
      optimizer.step()
      return loss.item()
  
file_path: pytorch_geometric/examples/infomax_transductive.py
imports: import os.path
  import torch
  from torch_geometric.datasets import Planetoid
  from torch_geometric.nn import DeepGraphInfomax, GCNConv
label_desc: Use image node_id 2 for calling a global function with example usage: train() and returns: loss