class_docstr: This is a medium test due to the moments computation taking some time.
class_docstr_tok: ["This","is","a","medium","test","due","to","the","moments","computation","taking","some","time","."]
docstr: CSE = constant subexpression eliminator.
  
  SetIsStateful() should prevent two identical random ops from getting
  merged.
docstr_tok: ["CSE","=","constant","subexpression","eliminator",".","SetIsStateful","(",")","should","prevent","two","identical","random","ops","from","getting","merged","."]
code: def testNoCSE(self):
      """CSE = constant subexpression eliminator.
  
      SetIsStateful() should prevent two identical random ops from getting
      merged.
      """
      for dtype in dtypes.float16, dtypes.float32, dtypes.float64:
          with self.cached_session():
              rnd1 = random_ops.random_gamma([24], 2.0, dtype=dtype)
              rnd2 = random_ops.random_gamma([24], 2.0, dtype=dtype)
              diff = rnd2 - rnd1
              self.assertGreater(np.linalg.norm(diff.eval()), 0.1)
  
imports: import numpy
  from tensorflow.python.eager import context
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import errors
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import random_seed
  from tensorflow.python.framework import test_util
  from tensorflow.python.kernel_tests.random import util
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import math_ops
  from tensorflow.python.ops import random_ops
  from tensorflow.python.platform import test
  from tensorflow.python.platform import tf_logging
label_desc: Use image node_id 14 for calling the RandomGammaTest obj's underlying member method code with example usage: obj.testNoCSE() without return types