import tensorflow as tf tf.enable_eager_execution() # to check the content tf.convert_to_tensor([[1,2]]) # no equivalent to empty but placeholders: tf.placeholder(tf.float32, shape=(5,3)) tf.ones((5,3)) tf.zeros((5,3)) tf.random_uniform((5,3)) tf.random_normal((5,3)) tf.get_shape(tf.random_normal((5,3))) # static tf.shape(tf.random_normal((5,3))) # dynamic tf.matmul(tf.random_normal((5,3)), tf.random_uniform((3,4))) tf.reshape(tf.random_normal((5,3)), (3,5)) tf.transpose(tf.random_normal((5,3)), (1,0)) tf.concat([tf.random_normal((5,3)), tf.random_uniform((5,4))], 1) tf.stack([tf.random_normal((5,4)), tf.random_uniform((5,4))], 1) tf.expand_dims(tf.ones((5,3)),1) tf.squeeze(tf.ones((5,1,3)),1) tf.range(0,10) tf.reduce_max(tf.random_uniform((5,3))) tf.reduce_max(tf.random_uniform((5,3)),axis=1) tf.math.maximum(tf.random_uniform((5,3)), tf.random_normal((5,3)))