code: def accuracy(output, target, topk=(1,)):
      pred = output.topk(max(topk), 1, True, True)[1].t()
      correct = pred.eq(target.view(1, -1).expand_as(pred))
      return [
          float(
              correct[:k]
              .reshape(-1)
              .float()
              .sum(0, keepdim=True)
              .cpu()
              .numpy()
          )
          for k in topk
      ]
  
file_path: NeMo/examples/multimodal/vision_language_foundation/clip/megatron_clip_imagenet_zeroshot.py
imports: import torch
  import torch.nn.functional
  from omegaconf.omegaconf import OmegaConf, open_dict
  from tqdm import tqdm
  from nemo.collections.multimodal.data.clip.clip_dataset import build_imagenet_validation_dataloader
  from nemo.collections.multimodal.models.vision_language_foundation.clip.megatron_clip_models import MegatronCLIPModel
  from nemo.collections.multimodal.parts.utils import setup_trainer_and_model_for_inference
  from nemo.collections.nlp.modules.common.megatron.utils import average_losses_across_data_parallel_group
  from nemo.collections.nlp.parts.utils_funcs import torch_dtype_from_precision
  from nemo.core.config import hydra_runner
  from nemo.utils import logging
  from nemo.utils.get_rank import is_global_rank_zero
label_desc: Use image node_id 1 for calling a global function with example usage: accuracy(output, target, topk) and returns: unknown