constants.py 733 B

1234567891011121314151617181920
  1. # Copyright (c) Microsoft Corporation.
  2. # SPDX-License-Identifier: Apache-2.0
  3. # DeepSpeed Team
  4. from datetime import timedelta
  5. #############################################
  6. # Torch distributed constants
  7. #############################################
  8. TORCH_DISTRIBUTED_DEFAULT_PORT = 29500
  9. # Default process group wide timeout, if applicable.
  10. # This only applies to the gloo and nccl backends
  11. # (only if NCCL_BLOCKING_WAIT or NCCL_ASYNC_ERROR_HANDLING is set to 1).
  12. # To make an attempt at backwards compatibility with THD, we use an
  13. # extraordinarily high default timeout, given that THD did not have timeouts.
  14. default_pg_timeout = timedelta(minutes=30)
  15. INFERENCE_GENERIC_MODE = 'generic'
  16. INFERENCE_SPECIALIZED_MODE = 'specialized'