class_docstr: A helper class to enable `ORTModel` instances to prepare IO binding  with dynamic shaped outputs for an inference session and transfer
  tensors from ONNX Runtime to other frameworks on device. It helps reduce memory copy between the host and device.
class_docstr_tok: ["A","helper","class","to","enable","`","ORTModel","`","instances","to","prepare","IO","binding","with","dynamic","shaped","outputs","for","an","inference","session","and","transfer","tensors","from","ONNX","Runtime","to","other","frameworks","on","device",".","It","helps","reduce","memory","copy","between","the","host","and","device","."]
code: def to_pytorch_via_numpy(ort_value: OrtValue) -> torch.Tensor:
      ort_device = ort_value.device_name().lower()
      return torch.tensor(ort_value.numpy()).to(ort_device)
  
imports: import logging
  import traceback
  from typing import TYPE_CHECKING
  import numpy
  import torch
  import onnxruntime
  from onnxruntime.capi.onnxruntime_inference_collection import OrtValue
  from onnxruntime.transformers.io_binding_helper import TypeHelper
  from ..utils import is_cupy_available, is_onnxruntime_training_available
label_desc: Use image node_id 3 for calling the IOBindingHelper obj's underlying member method code with example usage: obj.to_pytorch_via_numpy(ort_value) and returns: torch