code: def poisson_cases():
      def wrap(
          op: ops.Operation, lam, lam_dtype, out_dtype, shape, seed
      ):
          return op(
              seed=seed,
              shape=shape,
              lam=constant_op.constant(lam_dtype(lam), dtype=lam_dtype),
              dtype=out_dtype,
          )
  
      for lam_dtype in (
          np.float16,
          np.float32,
          np.float64,
          np.int32,
          np.int64,
      ):
          for out_dtype in (
              np.float16,
              np.float32,
              np.float64,
              np.int32,
              np.int64,
          ):
              for lam in (
                  [[5.5, 1.0, 2.0]],
                  [[7.5, 10.5], [3.8, 8.2], [1.25, 9.75]],
              ):
                  yield (
                      "poisson",
                      functools.partial(
                          wrap,
                          stateless.stateless_random_poisson,
                          lam,
                          lam_dtype,
                          out_dtype,
                          (10,) + tuple(np.shape(lam)),
                      ),
                      functools.partial(
                          wrap,
                          random_ops.random_poisson,
                          lam,
                          lam_dtype,
                          out_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 7 for calling a global function with example usage: poisson_cases() and returns: op