import tensorflow as tf
a = tf.Variable(tf.random_uniform(shape=[10, 10]))
with tf.Session() as sess:
#必须调用,否则a没办法初始化值
sess.run(tf.global_variables_initializer())
print sess.run(a)
import tensorflow as tf
a = tf.Variable(tf.random_uniform(shape=[10, 10]))
with tf.Session() as sess:
#必须调用,否则a没办法初始化值
sess.run(tf.global_variables_initializer())
print sess.run(a)