code: def to_onnxrt_input(
      ort_input_names, input_names, input_dict, input_list
  ):
      odict = {}
      for k in reversed(input_names):
          val = None
          if k in input_dict:
              val = input_dict[k].cpu().numpy()
          elif len(input_list) > 0:
              val = input_list.pop().cpu().numpy()
          if k in ort_input_names and val is not None:
              odict[k] = val
      return odict
  
imports: import os
  from contextlib import nullcontext
  from enum import Enum
  from typing import Callable, Dict, Optional, Type
  import onnx
  import torch
  import torch.nn
  import torch.nn.functional
  from nemo.utils import CastToFloat, CastToFloatAll, logging
label_desc: Use image node_id 6 for calling a global function with example usage: to_onnxrt_input(ort_input_names, input_names, input_dict, input_list) and returns: odict