def random(self, *shapes):
if all(isinstance(i, int) for i in shapes):
shapes = [shapes]
arrays = tuple(np.random.rand(*shape) for shape in shapes)
return arrays[0] if len(shapes) == 1 else arrays
def test_Identity(self):
t = tf.identity(self.random(3, 4))
After Change
else:
return np.random.rand(*shapes)
else:
return tuple(self.random(*shape) for shape in shapes)
def test_Identity(self):
t = tf.identity(self.random(3, 4))