code: def allreduce(
      value,
      name=None,
      average=None,
      prescale_factor=1.0,
      postscale_factor=1.0,
      op=None,
      compression=Compression.none,
  ):
      """
      Perform an allreduce on a tensor-compatible value.
  
      Arguments:
          value: A tensor-compatible value to reduce.
                 The shape of the input must be identical across all ranks.
          name: Optional name for the constants created by this operation.
          average:
              .. warning:: .. deprecated:: 0.19.0
  
                 Use `op` instead. Will be removed in v0.21.0.
  
          prescale_factor: Multiplicative factor to scale tensor before allreduce.
          postscale_factor: Multiplicative factor to scale tensor after allreduce.
          op: The reduction operation to combine tensors across different ranks.
              Defaults to Average if None is given.
          compression: Compression algorithm used to reduce the amount of data
                       sent and received by each worker node.  Defaults to not
                       using compression.
      """
      return _impl.allreduce(
          backend=K,
          value=value,
          name=name,
          average=average,
          prescale_factor=prescale_factor,
          postscale_factor=postscale_factor,
          op=op,
          compression=compression,
      )
  
imports: import inspect
  import warnings
  from packaging import version
  import tensorflow
  from tensorflow import keras
  from horovod.common.util import is_version_greater_equal_than
  from horovod.tensorflow import init
  from horovod.tensorflow import shutdown
  from horovod.tensorflow import is_initialized, start_timeline, stop_timeline
  from horovod.tensorflow import size, local_size, cross_size, rank, local_rank, cross_rank
  from horovod.tensorflow import mpi_threads_supported, mpi_enabled, mpi_built
  from horovod.tensorflow import gloo_enabled, gloo_built
  from horovod.tensorflow.mpi_ops import ProcessSet, global_process_set, add_process_set, remove_process_set
  from horovod.tensorflow import nccl_built, ddl_built, ccl_built, cuda_built, rocm_built
  from horovod.tensorflow import Average, Sum
  from horovod.tensorflow.compression import Compression
  import horovod._keras
  from horovod.tensorflow.keras import callbacks, elastic
label_desc: Use image node_id 3 for calling a global function with example usage: allreduce(value, name, average, prescale_factor, postscale_factor, op, compression) and returns: _impl