tf.compat.v1.add_to_collection

Wrapper for Graph.add_to_collection() using the default graph.

See tf.Graph.add_to_collection for more details.

nameThe key for the collection. For example, the GraphKeys class contains many standard names for collections.
valueThe value to add to the collection.

eager compatibility

Collections are only supported in eager when variables are created inside an EagerVariableStore (e.g. as part of a layer or template).