class_docstr: Test cases for stateful random-number generator operators.
class_docstr_tok: ["Test","cases","for","stateful","random-number","generator","operators","."]
docstr: Compares against known outputs for specific counter and key inputs.
docstr_tok: ["Compares","against","known","outputs","for","specific","counter","and","key","inputs","."]
code: def _compareToKnownOutputs(self, g, counter, key, expect):
      """Compares against known outputs for specific counter and key inputs."""
  
      def uint32s_to_uint64(a, b):
          return b << 32 | a
  
      def uint32s_to_uint64s(ls):
          return [
              uint32s_to_uint64(ls[2 * i], ls[2 * i + 1])
              for i in range(len(ls) // 2)
          ]
  
      ctr_len = len(counter)
      counter = uint32s_to_uint64s(counter)
      key = uint32s_to_uint64s(key)
      state = counter + key
      g.reset(state)
      got = g.uniform_full_int(shape=(ctr_len,), dtype=dtypes.uint32)
      self.assertAllEqual(expect, got)
      g.reset(state)
      got = g.uniform_full_int(
          shape=(ctr_len // 2,), dtype=dtypes.uint64
      )
      self.assertAllEqual(uint32s_to_uint64s(expect), got)
  
imports: import itertools
  import os
  from absl.testing import parameterized
  import numpy
  from tensorflow.compiler.tests import xla_test
  from tensorflow.python.client import device_lib
  from tensorflow.python.eager import def_function
  from tensorflow.python.framework import config
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import errors_impl
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import test_util
  from tensorflow.python.kernel_tests.random import util
  from tensorflow.python.ops import gen_stateful_random_ops
  from tensorflow.python.ops import random_ops_util
  from tensorflow.python.ops import stateful_random_ops
  from tensorflow.python.ops import variables
  from tensorflow.python.platform import flags
  from tensorflow.python.platform import test
label_desc: Use image node_id 3 for calling the StatefulRandomOpsTest obj's underlying member method code with example usage: obj._compareToKnownOutputs(g, counter, key, expect) and returns: unknown, unknown