get_group

paddle.distributed. get_group ( id=0 ) [source]

Get group instance by group id.

Parameters

id (int) – the group id. Default value is 0.

Returns

the group instance.

Return type

Group

Examples

...
gid = paddle.distributed.new_group([2,4,6])
paddle.distributed.get_group(gid.id)