/third_party/mindspore/tests/ut/python/parallel/ |
D | test_conv2d.py | 27 strategy1=None, strategy2=None): argument 30 … pad_mode=pad_mode, stride=stride, dilation=dilation, group=group).shard(strategy1) 61 strategy1 = ((8, 1, 1, 1), (1, 1, 1, 1)) 63 …net = Net(_w1, out_channel=8, kernel_size=2, pad_mode="same", stride=1, strategy1=strategy1, strat… 69 strategy1 = ((8, 1, 1, 1), (1, 1, 1, 1)) 72 strategy1=strategy1, strategy2=strategy2) 79 strategy1 = ((8, 1, 1, 1), (1, 1, 1, 1)) 82 strategy1=strategy1, strategy2=strategy2) 88 strategy1 = ((8, 1, 1, 1), (1, 1, 1, 1)) 91 strategy1=strategy1, strategy2=strategy2) [all …]
|
D | test_maxpool_avgpool.py | 27 strategy1=None, strategy2=None): argument 30 pad_mode=pad_mode, stride=stride).shard(strategy1) 42 strategy1=None, strategy2=None): argument 45 pad_mode=pad_mode, stride=stride).shard(strategy1) 72 strategy1 = ((8, 1, 1, 1), (1, 1, 1, 1)) 75 strategy1=strategy1, strategy2=strategy2) 81 strategy1 = ((2, 2, 1, 1), (2, 2, 1, 1)) 84 strategy1=strategy1, strategy2=strategy2) 90 strategy1 = ((2, 2, 1, 1), (2, 2, 1, 1)) 93 strategy1=strategy1, strategy2=strategy2) [all …]
|
D | test_conv2d_transpose.py | 27 strategy1=None, strategy2=None): argument 30 pad_mode=pad_mode, stride=stride).shard(strategy1) 42 strategy1=None, strategy2=None): argument 45 pad_mode=pad_mode, stride=stride).shard(strategy1) 74 strategy1 = ((8, 1, 1, 1), (1, 1, 1, 1)) 76 …net = Net(_w1, out_channel=8, kernel_size=2, pad_mode="same", stride=1, strategy1=strategy1, strat… 82 strategy1 = ((2, 2, 1, 1), (2, 2, 1, 1)) 84 …net = Net(_w1, out_channel=8, kernel_size=2, pad_mode="same", stride=1, strategy1=strategy1, strat… 90 strategy1 = ((2, 1, 1, 4), (1, 1, 1, 1)) 93 strategy1=strategy1, strategy2=strategy2) [all …]
|
D | test_layer_norm_further.py | 28 strategy1=None, strategy2=None, strategy3=None): argument 32 self.mul = P.Mul().shard(strategy1) 52 strategy1=None, strategy2=None, strategy3=None): argument 56 self.mul = P.Mul().shard(strategy1) 76 strategy1=None, strategy2=None, strategy3=None): argument 80 self.mul = P.Mul().shard(strategy1) 100 strategy1=None, strategy2=None, strategy3=None): argument 104 self.mul = P.Mul().shard(strategy1) 122 strategy1=None, strategy2=None, strategy3=None): argument 126 self.mul = P.Mul().shard(strategy1) [all …]
|
D | test_gathernd_further.py | 48 def __init__(self, w1_shape, indices_shape, strategy1=None, strategy2=None, strategy3=None): argument 50 self.mul = P.Mul().shard(strategy1) 64 def __init__(self, w1_shape, indices_shape, strategy1=None, strategy2=None, strategy3=None): argument 66 self.mul = P.Mul().shard(strategy1) 79 def __init__(self, w1_shape, indices_shape, strategy1=None, strategy2=None, strategy3=None): argument 81 self.mul = P.Mul().shard(strategy1) 115 strategy1 = ((8, 1, 1), (8, 1, 1)) 118 net = Net(w1_shape, indices_shape, strategy1, strategy2, strategy3) 127 strategy1 = ((8, 1, 1), (8, 1, 1)) 130 net = Net(w1_shape, indices_shape, strategy1, strategy2, strategy3) [all …]
|
D | test_element_wise_function.py | 58 def __init__(self, strategy1, strategy2): argument 60 self.matmul = P.MatMul().shard(strategy1) 62 self.matmul2 = P.MatMul().shard(strategy1) 71 strategy1 = ((2, 2), (2, 2)) 73 net = GradWrap(NetWithLoss(Net(strategy1, strategy2))) 84 def __init__(self, strategy1, strategy2): argument 86 self.matmul = P.MatMul().shard(strategy1) 88 self.matmul2 = P.MatMul().shard(strategy1) 97 strategy1 = ((2, 2), (2, 2)) 99 net = GradWrap(NetWithLoss(Net(strategy1, strategy2))) [all …]
|
D | test_uniform_candidate_sampler.py | 28 strategy1=None): argument 32 if strategy1: 33 self.sampler.shard(strategy1) 53 strategy1=None): argument 60 if strategy1: 61 self.sampler.shard(strategy1) 87 strategy1 = ((4, 1),) 89 remove_accidential=False, strategy1=strategy1) 95 strategy1 = ((1, 4),) 97 remove_accidential=False, strategy1=strategy1) [all …]
|
D | test_batchnorm.py | 26 strategy1=None, strategy2=None): argument 29 pad_mode=pad_mode, stride=stride).shard(strategy1) 56 strategy1 = ((8, 1, 1, 1), (1, 1, 1, 1)) 58 …net = Net(_w1, out_channel=8, kernel_size=2, pad_mode="same", stride=1, strategy1=strategy1, strat… 64 strategy1 = ((2, 2, 1, 1), (2, 2, 1, 1)) 66 …net = Net(_w1, out_channel=8, kernel_size=2, pad_mode="same", stride=1, strategy1=strategy1, strat… 72 strategy1 = ((2, 2, 2, 2), (2, 2, 1, 1)) 74 …net = Net(_w1, out_channel=8, kernel_size=2, pad_mode="same", stride=2, strategy1=strategy1, strat… 79 def __init__(self, strategy1=None, strategy2=None): argument 82 self.bn.bn_train.shard(strategy1) [all …]
|
D | test_reduce_method_info.py | 85 def __init__(self, strategy1, strategy2, strategy3): argument 87 self.mul1 = P.Mul().shard(strategy1) 98 strategy1 = ((1, 1, 8), (1, 1, 8)) 101 net = GradWrap(NetWithLoss(Net(strategy1, strategy2, strategy3))) 112 def __init__(self, strategy1, strategy2, strategy3): argument 114 self.mul1 = P.Mul().shard(strategy1) 125 strategy1 = ((1, 1, 4, 2), (1, 1, 4, 2)) 128 net = GradWrap(NetWithLoss(Net(strategy1, strategy2, strategy3))) 139 def __init__(self, strategy1, strategy2, strategy3): argument 141 self.mul1 = P.Mul().shard(strategy1) [all …]
|
D | test_manual_embedding_lookup.py | 34 strategy1=None, argument 43 self.gatherv2 = P.EmbeddingLookup().shard(strategy1) 80 strategy1 = ((2, 1), (1, 2)) 83 net = Net(strategy1, strategy2, strategy3) 89 strategy1 = ((4, 1), (1, 4)) 92 net = Net(strategy1, strategy2, strategy3, split_tuple=(10, 20, 30, 4), param_shape=(64, 8)) 98 strategy1 = ((4, 8), (1, 4)) 101 net = Net(strategy1, strategy2, strategy3, split_tuple=(10, 20, 30, 4), param_shape=(64, 8)) 107 strategy1 = ((2, 1), (1, 2)) 110 …net = Net(strategy1, strategy2, strategy3, split_string="manual_split_with_offset", split_tuple=((… [all …]
|
D | test_manual_gatherv2.py | 27 strategy1=None, argument 36 self.gatherv2 = P.Gather().shard(strategy1) 73 strategy1 = ((2, 1), (1, 2)) 76 net = Net(strategy1, strategy2, strategy3) 82 strategy1 = ((4, 1), (1, 4)) 85 net = Net(strategy1, strategy2, strategy3, split_tuple=(10, 20, 30, 4), param_shape=(64, 8)) 91 strategy1 = ((4, 8), (1, 4)) 94 net = Net(strategy1, strategy2, strategy3, split_tuple=(10, 20, 30, 4), param_shape=(64, 8)) 100 strategy1 = ((2, 1), (1, 2)) 103 …net = Net(strategy1, strategy2, strategy3, split_string="manual_split_with_offset", split_tuple=((… [all …]
|
D | test_print.py | 26 strategy1=None, strategy2=None): argument 29 pad_mode=pad_mode, stride=stride).shard(strategy1) 59 strategy1 = ((8, 1, 1, 1), (1, 1, 1, 1)) 61 …net = Net(_w1, out_channel=8, kernel_size=2, pad_mode="same", stride=1, strategy1=strategy1, strat… 68 strategy1 = ((2, 2, 1, 1), (2, 2, 1, 1)) 70 …net = Net(_w1, out_channel=8, kernel_size=2, pad_mode="same", stride=1, strategy1=strategy1, strat… 77 strategy1 = ((2, 2, 2, 2), (2, 2, 1, 1)) 79 …net = Net(_w1, out_channel=8, kernel_size=2, pad_mode="same", stride=2, strategy1=strategy1, strat… 84 def __init__(self, strategy1=None, strategy2=None): argument 87 self.bn.bn_train.shard(strategy1) [all …]
|
D | test_comparison_function_info.py | 58 def __init__(self, strategy1, strategy2): argument 60 self.matmul = P.MatMul().shard(strategy1) 69 strategy1 = ((2, 2), (2, 2)) 71 net = GradWrap(NetWithLoss(Net(strategy1, strategy2))) 81 def __init__(self, strategy1, strategy2): argument 83 self.matmul = P.MatMul().shard(strategy1) 92 strategy1 = ((2, 2), (2, 2)) 94 net = GradWrap(NetWithLoss(Net(strategy1, strategy2))) 104 def __init__(self, strategy1, strategy2): argument 106 self.matmul = P.MatMul().shard(strategy1) [all …]
|
D | test_stridedslice.py | 26 …def __init__(self, weight, w2, begin, end, strides, strategy1=None, strategy2=None, is_parameter=T… argument 28 self.mul = P.Mul().shard(strategy1) 48 def __init__(self, weight2, begin, end, strides, strategy1=None, strategy2=None): argument 50 self.mul = P.Mul().shard(strategy1) 80 strategy1 = ((2, 2, 2), (2, 2, 2)) 82 … net = Net(_w1, _w2, (0, 0, 0), (128, 64, 32), (1, 1, 1), strategy1, strategy2, is_parameter=True) 89 strategy1 = ((2, 2, 2), (2, 2, 2)) 91 … net = Net(_w1, _w2, (0, 0, 0), (128, 64, 32), (1, 1, 2), strategy1, strategy2, is_parameter=True) 98 strategy1 = ((2, 2, 2), (2, 2, 2)) 100 …net = Net(_w1, _w2, (0, 0, 0), (128, 64, 32), (1, 1, 1), strategy1, strategy2, is_parameter=True, … [all …]
|
D | test_onehot.py | 57 def __init__(self, strategy1, strategy2): argument 59 self.matmul = P.MatMul().shard(strategy1) 68 def compile_graph(strategy1, strategy2, strategy3, strategy4, auto=False, onthot_axis=-1): argument 69 …net = GradWrap(_VirtualDatasetCell(NetWithLoss(Net(strategy1, strategy2), strategy3, strategy4, ax… 85 strategy1 = ((2, 4), (4, 2)) 89 compile_graph(strategy1, strategy2, strategy3, strategy4) 94 strategy1 = ((2, 4), (4, 2)) 98 compile_graph(strategy1, strategy2, strategy3, strategy4) 103 strategy1 = ((2, 4), (4, 2)) 108 compile_graph(strategy1, strategy2, strategy3, strategy4) [all …]
|
D | test_unsortedsegmentsum.py | 35 def __init__(self, strategy1, strategy2, num_segments): argument 37 self.merge_op = P.UnsortedSegmentSum().shard((strategy1, strategy2)) 65 def compile_graph(x, y, segments, strategy1, strategy2, auto=False): argument 70 net = GradWrap(NetWithLoss(Net(strategy1, strategy2, segments))) 81 strategy1 = (8,) 83 compile_graph(x, y, num_segments, strategy1, strategy2) 91 strategy1 = (1,) 93 compile_graph(x, y, num_segments, strategy1, strategy2) 101 strategy1 = (4, 1) 103 compile_graph(x, y, num_segments, strategy1, strategy2) [all …]
|
D | test_resizebilinear.py | 29 strategy1=None, strategy2=None): argument 32 pad_mode=pad_mode, stride=stride).shard(strategy1) 47 strategy1=None, strategy2=None): argument 50 pad_mode=pad_mode, stride=stride).shard(strategy1) 64 strategy1=None): argument 67 pad_mode=pad_mode, stride=stride).shard(strategy1) 92 strategy1 = ((8, 1, 1, 1), (1, 1, 1, 1)) 95 strategy1=strategy1, strategy2=strategy2) 101 strategy1 = ((2, 2, 1, 1), (2, 2, 1, 1)) 104 strategy1=strategy1, strategy2=strategy2) [all …]
|
D | test_arithmetic.py | 57 def __init__(self, strategy1, strategy2): argument 59 self.matmul = P.MatMul().shard(strategy1) 69 strategy1 = ((2, 2), (2, 2)) 71 net = GradWrap(NetWithLoss(Net(strategy1, strategy2))) 81 def __init__(self, strategy1, strategy2): argument 83 self.matmul = P.MatMul().shard(strategy1) 93 strategy1 = ((2, 2), (2, 2)) 95 net = GradWrap(NetWithLoss(Net(strategy1, strategy2))) 105 def __init__(self, strategy1, strategy2): argument 107 self.matmul = P.MatMul().shard(strategy1) [all …]
|
D | test_unsortedsegmentmax.py | 35 def __init__(self, strategy1, strategy2, num_segments): argument 38 self.merge_op = P.UnsortedSegmentMax().shard((strategy1, strategy2)) 66 def compile_graph(x, y, segments, strategy1, strategy2, auto=False): argument 67 net = GradWrap(NetWithLoss(Net(strategy1, strategy2, segments))) 82 strategy1 = (8,) 84 compile_graph(x, y, num_segments, strategy1, strategy2) 92 strategy1 = (1,) 94 compile_graph(x, y, num_segments, strategy1, strategy2) 102 strategy1 = (4, 1) 104 compile_graph(x, y, num_segments, strategy1, strategy2) [all …]
|
D | test_unsortedsegmentmin.py | 35 def __init__(self, strategy1, strategy2, num_segments): argument 38 self.merge_op = P.UnsortedSegmentMin().shard((strategy1, strategy2)) 66 def compile_graph(x, y, segments, strategy1, strategy2, auto=False): argument 67 net = GradWrap(NetWithLoss(Net(strategy1, strategy2, segments))) 82 strategy1 = (8,) 84 compile_graph(x, y, num_segments, strategy1, strategy2) 92 strategy1 = (1,) 94 compile_graph(x, y, num_segments, strategy1, strategy2) 102 strategy1 = (4, 1) 104 compile_graph(x, y, num_segments, strategy1, strategy2) [all …]
|
D | test_tile.py | 25 def __init__(self, weight, weight2, strategy1=None, strategy2=None, is_parameter=True): argument 27 self.mul = P.Mul().shard(strategy1) 44 def __init__(self, weight2, strategy1=None, strategy2=None): argument 46 self.mul = P.Mul().shard(strategy1) 56 def __init__(self, weight, strategy1=None, strategy2=None, is_parameter=True): argument 58 self.mul = P.Mul().shard(strategy1) 91 strategy1 = ((2, 2, 2), (2, 2, 2)) 93 net = Net(_w1, _w2, strategy1, strategy2, is_parameter=True) 99 strategy1 = ((2, 2, 2), (2, 2, 2)) 101 net = Net(_w1, _w2, strategy1, strategy2, is_parameter=True) [all …]
|
D | test_o2_level.py | 48 …def __init__(self, weight, w2, begin, end, strides, strategy1=None, strategy2=None, is_parameter=T… argument 50 self.mul = P.Mul().shard(strategy1) 71 def __init__(self, weight2, begin, end, strides, strategy1=None, strategy2=None): argument 73 self.mul = P.Mul().shard(strategy1) 106 strategy1 = ((2, 2, 2), (2, 2, 2)) 109 strategy1, strategy2, is_parameter=True) 117 strategy1 = ((2, 2, 2), (2, 2, 2)) 120 strategy1, strategy2, is_parameter=True) 128 strategy1 = ((2, 2, 2), (2, 2, 2)) 131 strategy1, strategy2, is_parameter=True, mask=1) [all …]
|
D | test_slice.py | 26 def __init__(self, weight, w2, begin, end, strategy1=None, strategy2=None, is_parameter=True): argument 28 self.mul = P.Mul().shard(strategy1) 47 def __init__(self, weight2, begin, end, strategy1=None, strategy2=None): argument 49 self.mul = P.Mul().shard(strategy1) 78 strategy1 = ((2, 2, 2), (2, 2, 2)) 80 net = Net(_w1, _w2, (0, 0, 0), (128, 64, 32), strategy1, strategy2, is_parameter=True) 86 strategy1 = ((1, 4, 1), (1, 4, 2)) 88 net = Net(_w1, _w2, (0, 0, 0), (128, 64, 32), strategy1, strategy2) 94 strategy1 = ((1, 4, 1), (1, 4, 2)) 96 net = Net(_w1, _w2, (0, 0, 0), (128, 64, 32), strategy1, strategy2, is_parameter=False) [all …]
|
D | test_concat.py | 24 def __init__(self, weight, weight2, strategy1=None, strategy2=None, is_parameter=True): argument 26 self.concat = P.Concat(axis=0).shard(strategy1) 41 def __init__(self, weight, strategy1=None, strategy2=None, axis=0): argument 43 self.mul = P.Mul().shard(strategy1) 54 def __init__(self, weight, weight2, weight3, strategy1=None, strategy2=None, is_parameter=True): argument 56 self.concat = P.Concat(axis=0).shard(strategy1) 93 strategy1 = ((1, 4, 2), (1, 4, 2)) 95 net = Net(_w1, _w2, strategy1, strategy2, is_parameter=True) 101 strategy1 = ((1, 2, 2), (1, 2, 2)) 103 net = Net(_w1, _w2, strategy1, strategy2, is_parameter=True) [all …]
|
D | test_parameter_multi_users.py | 25 def __init__(self, mul_weight, strategy1=None, strategy2=None): argument 27 self.mul = P.Mul().shard(strategy1) 38 def __init__(self, mul_weight, strategy1=None, strategy2=None): argument 40 self.mul = P.Mul().shard(strategy1) 51 def __init__(self, mul_weight, strategy1=None, strategy2=None): argument 53 self.mul = P.MatMul().shard(strategy1) 79 strategy1 = ((16, 1), (16, 1)) 81 net = Net(_w, strategy1, strategy2) 87 strategy1 = ((16, 1), (16, 1)) 89 net = Net(_w, strategy1, strategy2) [all …]
|