code: def accuracy(logits, labels):
      _, indices = torch.max(logits, dim=1)
      correct = torch.sum(indices == labels)
      return correct.item() * 1.0 / len(labels)
  
file_path: dgl/examples/pytorch/hardgat/train.py
imports: import argparse
  import time
  import dgl
  import numpy
  import torch
  import torch.nn.functional
  from dgl.data import CiteseerGraphDataset, CoraGraphDataset, PubmedGraphDataset, register_data_args
  from hgao import HardGAT
  from utils import EarlyStopping
label_desc: Use image node_id 1 for calling a global function with example usage: accuracy(logits, labels) and returns: unknown