dmlcloud.all_gather_object

dmlcloud.all_gather_object(obj, group=None)

Gather objects from all ranks in the group.

This is a convenience wrapper around torch.distributed.all_gather_object.

Parameters:
  • obj (object) – The object to gather. Must be pickable.

  • group (ProcessGroup, optional) – The process group to work on. If None, the default process group will be used. Default is None.

Returns:

A list of objects gathered from all ranks.

Return type:

List[object]