MCPcopy
hub / github.com/uber/petastorm / _tf_session

Function _tf_session

petastorm/tests/test_tf_utils.py:59–69  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

57
58@contextmanager
59def _tf_session():
60 with tf.Session() as sess:
61 sess.run([tf.global_variables_initializer(), tf.local_variables_initializer()])
62
63 coord = tf.train.Coordinator()
64 threads = tf.train.start_queue_runners(coord=coord, start=True)
65
66 yield sess
67
68 coord.request_stop()
69 coord.join(threads)
70
71
72def test_sanitize_field_tf_types():

Calls 2

runMethod · 0.80
joinMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…