def METHOD_NAME(tensor, name=None):
  """An op which sums an input tensor over all the MPI processes.
  The reduction operation is keyed by the name of the op. The tensor type and
  shape must be the same on all MPI processes for a given name. The reduction
  will not start until all processes are ready to send and receive the tensor.
  Returns:
    A tensor of the same shape and type as `tensor`, summed across all
    processes.
  """
  return gen_mpi_ops.mpi_allreduce(tensor, name=name)