code: def _check_tuple_arg(
      arg, arg_name, force_integer=False, force_positive=False
  ):
      if not (
          check_scalar(arg, force_integer, force_positive)
          or (
              isinstance(arg, (tuple, list))
              and (
                  all(
                      check_scalar(elem, force_integer, force_positive)
                      for elem in arg
                  )
                  or (
                      isinstance(elem, (tuple, list))
                      and all(
                          check_scalar(
                              sub_elem, force_integer, force_positive
                          )
                          for sub_elem in elem
                      )
                  )
                  for elem in arg
              )
          )
      ):
          if force_integer:
              raise ivy.utils.exceptions.IvyException(
                  f"{arg_name} should be int, tuple of ints or tuple of int tuples"
              )
          else:
              raise ivy.utils.exceptions.IvyException(
                  f"{arg_name} should be scalar, tuple of scalars or tuple of scalar"
                  " tuples"
              )
  
imports: from typing import Optional, Union, Tuple, Iterable, Sequence, Callable, Any, Literal, List
  from numbers import Number
  from functools import partial
  import math
  import ivy
  from ivy.func_wrapper import handle_out_argument, handle_partial_mixed_function, to_native_arrays_and_back, inputs_to_native_shapes, handle_nestable, handle_array_like_without_promotion, handle_view, inputs_to_ivy_arrays, handle_array_function, handle_device, handle_backend_invalid
  from ivy.functional.ivy.general import _numel
  from ivy.utils.backend import current_backend
  from ivy.utils.exceptions import handle_exceptions
label_desc: Use image node_id 24 for calling a global function with example usage: _check_tuple_arg(arg, arg_name, force_integer, force_positive) without return types