TensorFlow: "Attempting to use uninitialized value" in variable initialization
You also need to initialise the local variables hidden in the tf.metrics.recall
method.
For example, this piece of code would work:
init_g = tf.global_variables_initializer()
init_l = tf.local_variables_initializer()
with tf.Session() as sess:
sess.run(init_g)
sess.run(init_l)