code: def integer_array_indices(
      shape, result_shape=array_shapes(), dtype="int"
  ):
      # type: (Shape, SearchStrategy[Shape], np.dtype) -> st.SearchStrategy[Tuple[np.ndarray, ...]]
      """Return a search strategy for tuples of integer-arrays that, when used
      to index into an array of shape ``shape``, given an array whose shape
      was drawn from ``result_shape``.
  
      Examples from this strategy shrink towards the tuple of index-arrays::
  
          len(shape) * (np.zeros(drawn_result_shape, dtype), )
  
      * ``shape`` a tuple of integers that indicates the shape of the array,
        whose indices are being generated.
      * ``result_shape`` a strategy for generating tuples of integers, which
        describe the shape of the resulting index arrays. The default is
        :func:`~hypothesis.extra.numpy.array_shapes`.  The shape drawn from
        this strategy determines the shape of the array that will be produced
        when the corresponding example from ``integer_array_indices`` is used
        as an index.
      * ``dtype`` the integer data type of the generated index-arrays. Negative
        integer indices can be generated if a signed integer type is specified.
  
      Recall that an array can be indexed using a tuple of integer-arrays to
      access its members in an arbitrary order, producing an array with an
      arbitrary shape. For example:
  
      .. code-block:: pycon
  
          >>> from numpy import array
          >>> x = array([-0, -1, -2, -3, -4])
          >>> ind = (array([[4, 0], [0, 1]]),)  # a tuple containing a 2D integer-array
          >>> x[ind]  # the resulting array is commensurate with the indexing array(s)
          array([[-4,  0],
                 [0, -1]])
  
      Note that this strategy does not accommodate all variations of so-called
      'advanced indexing', as prescribed by NumPy's nomenclature.  Combinations
      of basic and advanced indexes are too complex to usefully define in a
      standard strategy; we leave application-specific strategies to the user.
      Advanced-boolean indexing can be defined as ``arrays(shape=..., dtype=bool)``,
      and is similarly left to the user.
      """
      check_type(tuple, shape, "shape")
      check_argument(
          shape
          and all(
              isinstance(x, integer_types) and x > 0 for x in shape
          ),
          "shape=%r must be a non-empty tuple of integers > 0"
          % (shape,),
      )
      check_type(SearchStrategy, result_shape, "result_shape")
      check_argument(
          np.issubdtype(dtype, np.integer),
          "dtype=%r must be an integer dtype" % (dtype,),
      )
      signed = np.issubdtype(dtype, np.signedinteger)
  
      def array_for(index_shape, size):
          return arrays(
              dtype=dtype,
              shape=index_shape,
              elements=st.integers(-size if signed else 0, size - 1),
          )
  
      return result_shape.flatmap(
          lambda index_shape: st.tuples(
              *[array_for(index_shape, size) for size in shape]
          )
      )
  
imports: from __future__ import absolute_import, division, print_function
  import math
  import re
  from collections import namedtuple
  import numpy
  import hypothesis.internal.conjecture.utils
  import hypothesis.strategies._internal.core
  from hypothesis import Verbosity, assume
  from hypothesis._settings import note_deprecation
  from hypothesis.errors import InvalidArgument
  from hypothesis.internal.compat import PY2, hrange, integer_types, quiet_raise, string_types
  from hypothesis.internal.coverage import check_function
  from hypothesis.internal.reflection import proxies, reserved_means_kwonly_star
  from hypothesis.internal.validation import check_type, check_valid_interval
  from hypothesis.reporting import current_verbosity
  from hypothesis.strategies._internal import SearchStrategy
  from hypothesis.utils.conventions import UniqueIdentifier, not_set
label_desc: Use image node_id 27 for calling a global function with example usage: integer_array_indices(shape, result_shape, dtype) and returns: result_shape, arrays