code: def eval(self, input_dict):
      assert "y_pred" in input_dict and "y_true" in input_dict
  
      y_pred, y_true = input_dict["y_pred"], input_dict["y_true"]
  
      if not isinstance(y_pred, torch.Tensor):
          y_pred = torch.from_numpy(y_pred)
      if not isinstance(y_true, torch.Tensor):
          y_true = torch.from_numpy(y_true)
  
      assert y_true.numel() == y_pred.numel()
      assert y_true.dim() == y_pred.dim() == 1
  
      return {"acc": int((y_true == y_pred).sum()) / y_true.numel()}
  
imports: from typing import Optional, Union, Dict
  import os
  import shutil
  import os.path
  import torch
  import numpy
  from ogb.utils.url import decide_download, download_url, extract_zip, makedirs
  from ogb.lsc.utils import split_test
label_desc: Use image node_id 1 for calling the MAG240MEvaluator obj's underlying member method code with example usage: obj.eval(input_dict) and returns: dict