code: def test_random_function_noshape_args(self):
      # Test if random_function helper works with args but without shape
      rng_R = random_state_type()
  
      # No shape, default args -> OK
      post_out, out = uniform(rng_R, size=None, ndim=2)
      f = compile.function(
          [
              compile.In(
                  rng_R,
                  value=np.random.RandomState(utt.fetch_seed()),
                  update=post_out,
                  mutable=True,
              )
          ],
          [out],
          accept_inplace=True,
      )
      (o,) = f()
  
      # No shape, args that have to be broadcasted -> OK
      low = tensor.TensorType(
          dtype="float64", broadcastable=(False, True, True)
      )()
      high = tensor.TensorType(
          dtype="float64", broadcastable=(True, True, True, False)
      )()
      post_out2, out2 = uniform(
          rng_R, size=None, ndim=2, low=low, high=high
      )
      self.assertEqual(out2.ndim, 4)
      self.assertEqual(out2.broadcastable, (True, False, True, False))
  
      g = compile.function(
          [
              low,
              high,
              compile.In(
                  rng_R,
                  value=np.random.RandomState(utt.fetch_seed()),
                  update=post_out2,
                  mutable=True,
              ),
          ],
          [out2],
          accept_inplace=True,
      )
      low_v = [[[3]], [[4]], [[-5]]]
      high_v = [[[[5, 8]]]]
      (o2,) = g(low_v, high_v)
      self.assertEqual(o2.shape, (1, 3, 1, 2))
  
imports: from __future__ import absolute_import, print_function, division
  import numpy
  import pickle
  from theano.tests import unittest_tools
  from theano.tensor.raw_random import *
  from theano.tensor import raw_random, ivector, dvector, iscalar, dcol, dtensor3
  from theano import tensor
  from theano import compile, config, gof
label_desc: Use image node_id 8 for calling the T_random_function obj's underlying member method code with example usage: obj.test_random_function_noshape_args() without return types