code: def is_training_name(name):
      
      # TODO: maybe simply check against TRAINABLE_VARIABLES and MODEL_VARIABLES?
      # TODO or use get_slot_names()
      name = get_op_tensor_name(name)[0]
      if name.endswith('/Adam') or name.endswith('/Adam_1'):
          return True
      if name.endswith('/Momentum'):
          return True
      if name.endswith('/Adadelta') or name.endswith('/Adadelta_1'):
          return True
      if name.endswith('/RMSProp') or name.endswith('/RMSProp_1'):
          return True
      if name.endswith('/Adagrad'):
          return True
      if name.startswith('EMA/') or '/EMA/' in name:  # all the moving average summaries
          return True
      if name.startswith('AccumGrad') or name.endswith('/AccumGrad'):
          return True
      if name.startswith('apply_gradients'):
          return True
      return False
docs: **Guess** if this variable is only used in training.
      Only used internally to avoid too many logging. Do not use it.