"vscode:/vscode.git/clone" did not exist on "6735a3ae3df75b2eadf774360567e5a144e359f0"
Unverified Commit 105a40f5 authored by Woosuk Kwon's avatar Woosuk Kwon Committed by GitHub
Browse files

[Minor] Fix false warning when TP=1 (#2674)

parent bbe9bd96
...@@ -29,6 +29,10 @@ def init_custom_ar() -> None: ...@@ -29,6 +29,10 @@ def init_custom_ar() -> None:
return return
rank = get_tensor_model_parallel_rank() rank = get_tensor_model_parallel_rank()
world_size = get_tensor_model_parallel_world_size() world_size = get_tensor_model_parallel_world_size()
if world_size == 1:
# No need to initialize custom allreduce for single GPU case.
return
if world_size not in _SUPPORTED_WORLD_SIZES: if world_size not in _SUPPORTED_WORLD_SIZES:
logger.warn( logger.warn(
"Custom allreduce is disabled due to an unsupported world size: " "Custom allreduce is disabled due to an unsupported world size: "
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment