class_docstr: Base class of solver.
class_docstr_tok: ["Base","class","of","solver","."]
docstr: Get the training operator.
docstr_tok: ["Get","the","training","operator","."]
code: def get_train_op(self, loss, global_step=None):
      """Get the training operator."""
      apply_gradient_op = self.get_apply_gradients_op(loss, global_step)
  
      # model average
      self.var_avg(global_step)
  
      # model average after apply gradients
      with tf.control_dependencies([apply_gradient_op]):
          update_ops = tf.get_collection(tf.GraphKeys.UPDATE_OPS)
          train_op = tf.group(*update_ops)
  
      utils.log_vars("moving vars", tf.moving_average_variables())
      return train_op
  
imports: import abc
  import math
  import delta.compat
  import tensorflow_addons
  from absl import logging
  from delta import utils
  from delta.utils import optimizer
  from delta.utils.register import registers
label_desc: Use image node_id 14 for calling the Solver obj's underlying member method code with example usage: obj.get_train_op(loss, global_step) and returns: train_op