Skip to content

Commit

Permalink
Add docstring
Browse files Browse the repository at this point in the history
Signed-off-by: Jan Lasek <janek.lasek@gmail.com>
  • Loading branch information
janekl committed Dec 23, 2024
1 parent 0c1e9be commit e24a4dd
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion nemo/collections/llm/recipes/run/executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,15 @@

@run.cli.factory
def torchrun(devices: Optional[int] = None) -> run.Config[run.LocalExecutor]:
"""Local executor using torchrun."""
"""
Local executor using torchrun.
Args:
devices (Optional[int]): Number of devices to use. If None, it will use all available CUDA devices.
Returns:
run.Config[run.LocalExecutor]: Configuration for the local executor using torchrun.
"""
env_vars = {
"TORCH_NCCL_AVOID_RECORD_STREAMS": "1",
}
Expand Down

0 comments on commit e24a4dd

Please sign in to comment.