forked from OSSInnovation/mindspore
!6824 [AutoParallel]Add check for allreduce fusion
Merge pull request !6824 from lichen/add_limit_for_allreduce_fusion
This commit is contained in:
commit
794f07bdc5
|
@ -274,6 +274,9 @@ class _AutoParallelContext:
|
||||||
TypeError: If group is not a python str.
|
TypeError: If group is not a python str.
|
||||||
"""
|
"""
|
||||||
self.check_context_handle()
|
self.check_context_handle()
|
||||||
|
if not indices:
|
||||||
|
raise ValueError('indices can not be empty')
|
||||||
|
|
||||||
if isinstance(indices, (list)):
|
if isinstance(indices, (list)):
|
||||||
for index in indices:
|
for index in indices:
|
||||||
if not isinstance(index, int):
|
if not isinstance(index, int):
|
||||||
|
|
Loading…
Reference in New Issue