code: def benchmark(self, img):
      input_size = self.image_size
      if self.crop is not None:
          nimg = img[
              self.crop[1] : self.crop[3],
              self.crop[0] : self.crop[2],
              :,
          ]
          if (
              nimg.shape[0] != input_size[1]
              or nimg.shape[1] != input_size[0]
          ):
              nimg = cv2.resize(nimg, input_size)
          img = nimg
      blob = cv2.dnn.blobFromImage(
          img,
          1.0 / self.input_std,
          input_size,
          (self.input_mean, self.input_mean, self.input_mean),
          swapRB=True,
      )
      costs = []
      for _ in range(50):
          ta = datetime.datetime.now()
          net_out = self.session.run(
              self.output_names, {self.input_name: blob}
          )[0]
          tb = datetime.datetime.now()
          cost = (tb - ta).total_seconds()
          costs.append(cost)
      costs = sorted(costs)
      cost = costs[5]
      return net_out, cost
  
file_path: insightface/recognition/arcface_torch/onnx_helper.py
imports: from __future__ import division
  import datetime
  import os
  import os.path
  import glob
  import numpy
  import cv2
  import sys
  import onnxruntime
  import onnx
  import argparse
  from onnx import numpy_helper
  from insightface.data import get_image
label_desc: Use image node_id 6 for calling the ArcFaceORT obj's underlying member method code with example usage: obj.benchmark(img) and returns: net_out,  cost