tf.GraphKeys function

Reprinted: https://www.w3cschool.cn/tensorflow_python/tensorflow_python-ne7t2ezd.html

GraphKeys class

Definition: tensorflow / Python / Framework / ops.py .

See Guidelines: constructing a map> Graphic collection

Standard name of the graphic collection.

Various known standard library names to collect and retrieve the value associated with the graphic. For example, if not specified, the default variable optimization tf.Optimizer subclass collected tf.GraphKeys.TRAINABLE_VARIABLES, but may be explicitly transferred list of variables.

It defines the following key criteria:

  • GLOBAL_VARIABLES: Default Variable collection of objects in a distributed environment shared (model variables are a subset thereof) Reference:. Tf.global_variables general, all TRAINABLE_VARIABLES variables are in MODEL_VARIABLES, all MODEL_VARIABLES variables are in GLOBAL_VARIABLES..
  • LOCAL_VARIABLES:. Subset of object local variable for each computer usually temporary variables, such as counters Note: Use tf.contrib.framework.local_variable added to this collection.
  • MODEL_VARIABLES: models for reasoning subset variable object (feedforward) Note: Use tf.contrib.framework.model_variable added to this collection.
  • TRAINABLE_VARIABLES: a subset of the variable object by the optimizer training.
  • SUMMARIES: Summary tensor objects created in the diagram.
  • QUEUE_RUNNERS: QueueRunner for generating an input to the object is calculated.
  • MOVING_AVERAGE_VARIABLES: a subset of the variable objects, it will also keep moving average.
  • REGULARIZATION_LOSSES: normalized loss collected during image construction.

It defines the following standard keys, but their collection is not like other auto-fill it:

  • WEIGHTS
  • BIASES
  • ACTIVATIONS

Guess you like

Origin blog.csdn.net/qq_38409301/article/details/94207050