Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions torch/distributed/_tensor/device_mesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,7 @@ def init_device_mesh(
>>> # xdoctest: +SKIP
>>> from torch.distributed._tensor.device_mesh import init_device_mesh
>>>
>>> one_d_mesh = init_device_mesh("cuda", mesh_shape=(8,))
>>> two_d_mesh = init_device_mesh("cuda", mesh_shape=(2, 8), mesh_dim_names=("dp", "tp"))
"""
if mesh_dim_names is not None and len(mesh_shape) != len(mesh_dim_names):
Expand Down