Home
last modified time | relevance | path

Searched refs:predict (Results 1 – 25 of 268) sorted by relevance

1234567891011

/third_party/mindspore/tests/
Dops_common.py226 predict = self.network(x1)[self.output_index]
227 return predict
230 predict = self.network(x1, x2)[self.output_index]
231 return predict
234 predict = self.network(x1, x2, x3)[self.output_index]
235 return predict
238 predict = self.network(x1, x2, x3, x4)[self.output_index]
239 return predict
242 predict = self.network(x1, x2, x3, x4, x5)[self.output_index]
243 return predict
[all …]
/third_party/mindspore/tests/st/ops/gpu/
Dtest_bce_with_logits_loss.py31 def construct(self, predict, target, weight, pos_weight): argument
32 return self.loss(predict, target, weight, pos_weight)
42 predict = Tensor(np.array([[-0.8, 1.2, 0.7], [-0.1, -0.4, 0.7]]).astype(np.float32))
46 output = loss(predict, target, weight, pos_weight)
52 predict = Tensor(np.array([[-0.8, 1.2, 0.7], [-0.1, -0.4, 0.7]]).astype(np.float32))
56 output = loss(predict, target, weight, pos_weight)
63 predict = Tensor(np.array([[-0.8, 1.2, 0.7], [-0.1, -0.4, 0.7]]).astype(np.float16))
67 output = loss(predict, target, weight, pos_weight)
79 predict = Tensor(np.arange(6).reshape(2, 3).astype(np.float32))
83 output = loss(predict, target, weight, pos_weight)
[all …]
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/gpu/cuda_impl/
Dbce_with_logits_loss_impl.cu58 __global__ void BCEWithLogitsLossMain(size_t size, const T *predict, const T *target, const T *shap… in BCEWithLogitsLossMain() argument
61 T max_value = -predict[pos]; in BCEWithLogitsLossMain()
64 output[pos] = (static_cast<T>(1) - target[pos]) * predict[pos] + in BCEWithLogitsLossMain()
65 log_weight * (log(exp(-max_value) + exp(-predict[pos] - max_value)) + max_value); in BCEWithLogitsLossMain()
71 __global__ void BCEWithLogitsLossMain(size_t size, const half *predict, const half *target, in BCEWithLogitsLossMain() argument
74 half max_value = -predict[pos]; in BCEWithLogitsLossMain()
77 output[pos] = (static_cast<half>(1) - target[pos]) * predict[pos] + in BCEWithLogitsLossMain()
78 … log_weight * (hlog(hexp(-max_value) + hexp(-predict[pos] - max_value)) + max_value); in BCEWithLogitsLossMain()
92 void CalBCEWithLogitsLoss(const size_t input_size, const T *predict, const T *target, const size_t … in CalBCEWithLogitsLoss() argument
104 …ogitsLossMain<<<GET_BLOCKS(input_size), GET_THREADS, 0, cuda_stream>>>(input_size, predict, target, in CalBCEWithLogitsLoss()
[all …]
/third_party/mindspore/tests/ut/python/parallel/
Dtest_full_batch.py32 def __init__(self, predict, label, length=3): argument
34 self.predict = predict
46 return self.predict, self.label
76 predict = Tensor(np.ones([256, 128]), dtype=ms.float32)
78 dataset = Dataset(predict, label, 2)
102 predict = Tensor(np.ones([256, 128]), dtype=ms.float32)
104 dataset = Dataset(predict, label, 2)
Dtest_dataset_interface.py34 def __init__(self, predict, label, length=3): argument
36 self.predict = predict
48 return self.predict, self.label
78 predict = Tensor(np.ones([32, 128]), dtype=ms.float32)
80 dataset = Dataset(predict, label, 2)
127 predict = Tensor(np.ones([32 * device_num, 128]), dtype=ms.float32)
132 train_net(predict, sens)
171 predict = Tensor(np.ones([32 * device_num, 128]), dtype=ms.float32)
174 net(predict)
Dtest_bool_grad.py31 def __init__(self, predict, label, length=3): argument
33 self.predict = predict
45 return self.predict, self.label
70 predict = Tensor(np.ones([32, 64]), dtype=ms.float32)
72 dataset = Dataset(predict, label, 2)
Dtest_prelu_cell.py35 def __init__(self, predict, label, length=3, input_num=2): argument
37 self.predict = predict
51 return (self.predict, self.label)
52 return (self.predict,)
106 predict = Tensor(np.ones([32, 256]), dtype=ms.float32)
108 dataset = Dataset(predict, label, 2)
Dtest_transpose.py30 def __init__(self, predict, label, length=3): argument
32 self.predict = predict
44 return self.predict, self.label
78 predict = Tensor(np.ones([32, 128]), dtype=ms.float32)
80 dataset = Dataset(predict, label, 2)
Dtest_auto_parallel_double_subgraphs.py54 predict = self.net(x)
55 loss1 = self.sum(predict, -1)
56 loss2 = self.mean(predict, -1)
67 predict = self.network(x)[self.output_index]
68 return predict
130 def __init__(self, predict, label, length=3): argument
131 self.predict = predict
143 return self.predict
Dtest_one_dev.py38 def __init__(self, predict, label, length=3): argument
40 self.predict = predict
52 return self.predict, self.label
109 predict = Tensor(np.ones([32, 128]), dtype=ms.float32)
111 dataset = Dataset(predict, label, 2)
Dtest_reshape.py43 def __init__(self, predict, label, length=3, input_num=2): argument
45 self.predict = predict
59 return (self.predict, self.label)
60 return (self.predict,)
92 predict = Tensor(np.ones([32, 512, 7, 7]), dtype=ms.float32)
94 dataset = Dataset(predict, label, 2)
190 predict = self.network(x)
191 return self.loss(predict)
431 predict = Tensor(np.ones([batch_size, 512, 7, 7]), dtype=ms.float32)
433 dataset = Dataset(predict, label, 2, input_num=1)
[all …]
Dtest_loss_scale.py114 def __init__(self, predict, label, length=3): argument
116 self.predict = predict
128 return self.predict, self.label
183 predict = Tensor(np.ones([64, 64]), dtype=ms.float32)
185 dataset = DatasetLenet(predict, label)
196 predict = Tensor(np.ones([64, 64]), dtype=ms.float32)
198 dataset = DatasetLenet(predict, label)
Dtest_batchnorm_batch_parallel.py40 def __init__(self, predict, label, length=3): argument
42 self.predict = predict
54 return self.predict, self.label
131 predict = Tensor(np.ones([batch_size, 3, 224, 224]), dtype=ms.float32)
134 dataset = DatasetLenet(predict, label, 2)
Dtest_auto_parallel_onehot.py38 def __init__(self, predict, label, length=3): argument
40 self.predict = predict
52 return self.predict, self.label
65 predict = self.network(x, y, b)
66 return self.loss(predict)
Dtest_parallel_transformer.py77 predict, _, _ = self.network(x1, x2, x3, x4, x5)
78 predict = P.Reshape()(predict, (-1, F.shape(predict)[-1]))
79 return self.loss(predict, y, mask)
93 predict, _, _ = self.network(x1, x2, x3, x4, x5)
94 return self.loss(predict)
348 predict, _ = self.network(x1, x2)
349 return self.loss(predict)
384 predict, _, _ = self.network(x1, x2, x3, x4)
385 return self.loss(predict)
424 predict, _ = self.network(x1)
[all …]
Dtest_broadcast_dict.py58 predict = Tensor(np.ones([64, 512]).astype(np.float32) * 0.01)
59 _ = network(predict)
73 predict = Tensor(np.ones([64, 512]).astype(np.float32) * 0.01)
74 _ = network(predict)
Dtest_bias_add.py40 def __init__(self, predict, label, length=3): argument
41 self.predict = predict
53 return self.predict, self.label
Dtest_topk.py27 def __init__(self, predict, label, length=3): argument
29 self.predict = predict
41 return self.predict, self.label
Dtest_gathernd.py27 def __init__(self, predict, label, length=3): argument
29 self.predict = predict
41 return self.predict, self.label
/third_party/mindspore/tests/ut/python/model/
Dtest_lenet.py53 predict = Tensor(np.ones([1, 1, 32, 32]).astype(np.float32) * 0.01)
56 _cell_graph_executor.compile(net, predict, label)
60 predict = Tensor(np.ones([1, 1, 32, 32]).astype(np.float32) * 0.01)
63 _cell_graph_executor.compile(net, predict)
67 predict = Tensor(np.ones([1, 1, 32, 32]).astype(np.float32) * 0.01)
71 _cell_graph_executor.compile(net, predict, label)
/third_party/mindspore/tests/ut/python/communication/
Dtest_data_parallel_lenet.py59 def __init__(self, predict, label, length=3): argument
60 self.predict = predict
72 return self.predict, self.label
84 predict = Tensor(np.ones([1, 1, 32, 32]).astype(np.float32) * 0.01)
86 DatasetLenet(predict, label, 2)
/third_party/flutter/skia/third_party/externals/libwebp/src/enc/
Dpredictor_enc.c150 static uint8_t NearLosslessComponent(uint8_t value, uint8_t predict, in NearLosslessComponent() argument
152 const int residual = (value - predict) & 0xff; in NearLosslessComponent()
153 const int boundary_residual = (boundary - predict) & 0xff; in NearLosslessComponent()
189 static uint32_t NearLossless(uint32_t value, uint32_t predict, in NearLossless() argument
197 return VP8LSubPixels(value, predict); in NearLossless()
205 a = NearLosslessDiff((value >> 24) & 0xff, (predict >> 24) & 0xff); in NearLossless()
207 a = NearLosslessComponent(value >> 24, predict >> 24, 0xff, quantization); in NearLossless()
209 g = NearLosslessComponent((value >> 8) & 0xff, (predict >> 8) & 0xff, 0xff, in NearLossless()
214 new_green = ((predict >> 8) + g) & 0xff; in NearLossless()
221 (predict >> 16) & 0xff, 0xff - new_green, in NearLossless()
[all …]
/third_party/skia/third_party/externals/libwebp/src/enc/
Dpredictor_enc.c150 static uint8_t NearLosslessComponent(uint8_t value, uint8_t predict, in NearLosslessComponent() argument
152 const int residual = (value - predict) & 0xff; in NearLosslessComponent()
153 const int boundary_residual = (boundary - predict) & 0xff; in NearLosslessComponent()
189 static uint32_t NearLossless(uint32_t value, uint32_t predict, in NearLossless() argument
197 return VP8LSubPixels(value, predict); in NearLossless()
205 a = NearLosslessDiff((value >> 24) & 0xff, (predict >> 24) & 0xff); in NearLossless()
207 a = NearLosslessComponent(value >> 24, predict >> 24, 0xff, quantization); in NearLossless()
209 g = NearLosslessComponent((value >> 8) & 0xff, (predict >> 8) & 0xff, 0xff, in NearLossless()
214 new_green = ((predict >> 8) + g) & 0xff; in NearLossless()
221 (predict >> 16) & 0xff, 0xff - new_green, in NearLossless()
[all …]
/third_party/mindspore/mindspore/core/ops/grad/
Dsoft_margin_loss_grad.cc32 …auto predict = CheckAndConvertUtils::ConvertShapePtrToShapeMap(input_args[kInputIndex0]->BuildShap… in SoftMarginLossGradInferShape() local
35 …CheckAndConvertUtils::Check("logits shape", predict, kEqual, "labels shape", label, op_name, Value… in SoftMarginLossGradInferShape()
37 …CheckAndConvertUtils::Check("logits shape", predict, kEqual, "dout shape", dout, op_name, ValueErr… in SoftMarginLossGradInferShape()
39 return std::make_shared<abstract::Shape>(predict); in SoftMarginLossGradInferShape()
/third_party/mindspore/tests/ut/python/pynative_mode/
Dtest_pynative_model.py60 predict = self.network(x)
61 return self.loss(predict, label)
79 predict = Tensor(np.ones([1, 64]).astype(np.float32))
82 out = net.construct(predict, label)
100 predict = self.network(x)
101 return self.loss(predict, label)

1234567891011