MCPcopy Index your code
hub / github.com/tensorpack/tensorpack / f

Method f

tensorpack/callbacks/graph.py:96–102  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

94 name = 'UPDATE_OPS' if collection == tf.GraphKeys.UPDATE_OPS else collection
95
96 def f():
97 ops = tf.get_collection(collection)
98 if ops:
99 logger.info("Applying collection {} of {} ops.".format(name, len(ops)))
100 return tf.group(*ops, name='update_ops')
101 else:
102 return tf.no_op(name='empty_update_ops')
103
104 super(RunUpdateOps, self).__init__(
105 f, run_before=False, run_as_trigger=False, run_step=True)

Callers 1

_get_value_to_setMethod · 0.45

Calls 3

get_collectionMethod · 0.80
formatMethod · 0.80
groupMethod · 0.80

Tested by

no test coverage detected