code: def gamma_cases():
      def wrap(op: ops.Operation, alpha, dtype, shape, seed):
          return op(
              seed=seed,
              shape=shape,
              alpha=constant_op.constant(alpha, dtype=dtype),
              dtype=dtype,
          )
  
      for dtype in np.float16, np.float32, np.float64:
          for alpha in (
              [[0.5, 1.0, 2.0]],
              [[0.5, 0.5], [0.8, 0.2], [0.25, 0.75]],
          ):
              yield (
                  "gamma",
                  functools.partial(
                      wrap,
                      stateless.stateless_random_gamma,
                      alpha,
                      dtype,
                      (10,) + tuple(np.shape(alpha)),
                  ),
                  functools.partial(
                      wrap, random_ops.random_gamma, alpha, dtype, (10,)
                  ),
              )
  
imports: import functools
  from absl.testing import parameterized
  import numpy
  from tensorflow.python.compat import compat
  from tensorflow.python.eager import context
  from tensorflow.python.eager import def_function
  from tensorflow.python.framework import config
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import random_seed
  from tensorflow.python.framework import test_util
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import array_ops_stack
  from tensorflow.python.ops import gen_stateless_random_ops_v2
  from tensorflow.python.ops import math_ops
  from tensorflow.python.ops import random_ops
  from tensorflow.python.ops import stateless_random_ops
  from tensorflow.python.platform import test
label_desc: Use image node_id 6 for calling a global function with example usage: gamma_cases() and returns: op