code: def _run_forward(
      forward_func: Callable,
      inputs: Any,
      target: TargetType = None,
      additional_forward_args: Any = None,
  ) -> Tensor:
      forward_func_args = signature(forward_func).parameters
      if len(forward_func_args) == 0:
          output = forward_func()
          return (
              output
              if target is None
              else _select_targets(output, target)
          )
  
      # make everything a tuple so that it is easy to unpack without
      # using if-statements
      inputs = _format_inputs(inputs)
      additional_forward_args = _format_additional_forward_args(
          additional_forward_args
      )
  
      output = forward_func(
          *(*inputs, *additional_forward_args)
          if additional_forward_args is not None
          else inputs
      )
      return _select_targets(output, target)
  
imports: import typing
  from enum import Enum
  from functools import reduce
  from inspect import signature
  from typing import Any, Callable, cast, Dict, List, overload, Tuple, Union
  import numpy
  import torch
  from captum._utils.typing import BaselineType, Literal, TargetType, TensorOrTupleOfTensorsGeneric, TupleOrTensorOrBoolGeneric
  from torch import device, Tensor
  from torch.nn import Module
label_desc: Use image node_id 36 for calling a global function with example usage: _run_forward(forward_func, inputs, target, additional_forward_args) and returns: _select_targets, unknown