/frameworks/ml/nn/common/operations/ |
D | Activation.cpp | 55 int numElements = getNumberOfElements(inputShape); in reluFloat() 91 int numElements = getNumberOfElements(inputShape); in tanhFloat16() 101 int numElements = getNumberOfElements(inputShape); in tanhFloat32() 112 int numElements = getNumberOfElements(inputShape); in logisticFloat() 126 int numElements = getNumberOfElements(inputShape); in reluXQuant8() 166 int numElements = getNumberOfElements(inputShape); in tanhQuant8() 196 int numElements = getNumberOfElements(inputShape); in logisticQuant8() 221 int numElements = getNumberOfElements(inputShape); in reluXQuant8Signed() 261 int numElements = getNumberOfElements(inputShape); in tanhQuant8Signed() 290 int numElements = getNumberOfElements(inputShape); in logisticQuant8Signed() [all …]
|
D | HeatmapMaxKeypoint.cpp | 189 std::vector<float> heatmap_float32(getNumberOfElements(heatmapShape)); in heatmapMaxKeypointQuant() 191 std::vector<float> boxes_float32(getNumberOfElements(boxesShape)); in heatmapMaxKeypointQuant() 193 std::vector<float> outputScore_float32(getNumberOfElements(outputScoreShape)); in heatmapMaxKeypointQuant() 194 std::vector<float> outputKeypoint_float32(getNumberOfElements(outputKeypointShape)); in heatmapMaxKeypointQuant() 211 std::vector<float> heatmap_float32(getNumberOfElements(heatmapShape)); in heatmapMaxKeypointQuant() 213 std::vector<float> boxes_float32(getNumberOfElements(boxesShape)); in heatmapMaxKeypointQuant() 215 std::vector<float> outputScore_float32(getNumberOfElements(outputScoreShape)); in heatmapMaxKeypointQuant() 216 std::vector<float> outputKeypoint_float32(getNumberOfElements(outputKeypointShape)); in heatmapMaxKeypointQuant() 311 std::vector<float> heatmap_float32(getNumberOfElements(heatmapShape)); in execute() 313 std::vector<float> boxes_float32(getNumberOfElements(boxesShape)); in execute() [all …]
|
D | SVDF.cpp | 116 std::vector<float> inputDataFloat32(getNumberOfElements(input_->shape())); in Eval() 118 std::vector<float> inputStateDataFloat32(getNumberOfElements(state_in_->shape())); in Eval() 121 std::vector<float> biasDataFloat32(getNumberOfElements(bias_->shape())); in Eval() 127 getNumberOfElements(weights_feature_->shape())); in Eval() 130 std::vector<float> weightsTimeDataFloat32(getNumberOfElements(weights_time_->shape())); in Eval() 133 std::vector<float> outputDataFloat32(getNumberOfElements(output_->shape())); in Eval() 134 std::vector<float> outputStateDataFloat32(getNumberOfElements(state_out_->shape())); in Eval()
|
D | L2Normalization.cpp | 51 const uint32_t outerSize = getNumberOfElements(inputShape, 0, axis); in l2normFloat32Impl() 54 getNumberOfElements(inputShape, axis + 1, getNumberOfDimensions(inputShape)); in l2normFloat32Impl() 78 const uint32_t outerSize = getNumberOfElements(inputShape, 0, axis); in l2normQuant8Impl() 81 getNumberOfElements(inputShape, axis + 1, getNumberOfDimensions(inputShape)); in l2normQuant8Impl() 110 const uint32_t outerSize = getNumberOfElements(inputShape, 0, axis); in l2normQuant8SignedImpl() 113 getNumberOfElements(inputShape, axis + 1, getNumberOfDimensions(inputShape)); in l2normQuant8SignedImpl() 157 std::vector<float> inputDataFloat32(getNumberOfElements(inputShape)); in l2normFloat16() 159 std::vector<float> outputDataFloat32(getNumberOfElements(outputShape)); in l2normFloat16() 190 const int32_t outerSize = getNumberOfElements(inputShape, 0, axis); in l2normQuant8Signed()
|
D | SimpleMath.cpp | 37 std::vector<float> inputDataFloat32(getNumberOfElements(inputShape)); in meanFloat16() 40 std::vector<float> outputDataFloat32(getNumberOfElements(outputShape)); in meanFloat16() 59 U* tempSumBuffer = new (std::nothrow) U[getNumberOfElements(outputShape)]; in meanGeneric()
|
D | Softmax.cpp | 53 const uint32_t outerSize = getNumberOfElements(inputShape, 0, axis); in softmaxSlowFloat32() 56 getNumberOfElements(inputShape, axis + 1, getNumberOfDimensions(inputShape)); in softmaxSlowFloat32() 101 std::vector<float> inputData_float32(getNumberOfElements(inputShape)); in softmaxFloat16() 103 std::vector<float> outputData_float32(getNumberOfElements(outputShape)); in softmaxFloat16() 128 const uint32_t outerSize = getNumberOfElements(inputShape, 0, axis); in softmaxQuant8Impl() 131 getNumberOfElements(inputShape, axis + 1, getNumberOfDimensions(inputShape)); in softmaxQuant8Impl() 279 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in execute()
|
D | FullyConnected.cpp | 66 uint32_t input_n_elements = getNumberOfElements(inputShape); in fullyConnectedFloat32() 90 std::vector<float> inputDataFloat32(getNumberOfElements(inputShape)); in fullyConnectedFloat16() 92 std::vector<float> weightsDataFloat32(getNumberOfElements(weightsShape)); in fullyConnectedFloat16() 94 std::vector<float> biasDataFloat32(getNumberOfElements(biasShape)); in fullyConnectedFloat16() 97 std::vector<float> outputDataFloat32(getNumberOfElements(outputShape)); in fullyConnectedFloat16() 200 uint32_t input_n_elements = getNumberOfElements(input); in validateShapes() 303 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in execute()
|
D | Pooling.cpp | 152 std::vector<float> inputDataFloat32(getNumberOfElements(inputShape)); in averagePoolNhwc() 153 std::vector<float> outputDataFloat32(getNumberOfElements(outputShape)); in averagePoolNhwc() 198 std::vector<float> inputDataFloat32(getNumberOfElements(inputShape)); in l2PoolNhwc() 199 std::vector<float> outputDataFloat32(getNumberOfElements(outputShape)); in l2PoolNhwc() 242 std::vector<float> inputData_float32(getNumberOfElements(inputShape)); in maxPoolNhwc() 243 std::vector<float> outputData_float32(getNumberOfElements(outputShape)); in maxPoolNhwc() 395 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in executeAveragePool() 410 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in executeL2Pool() 423 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in executeMaxPool()
|
D | GenerateProposals.cpp | 70 const float* roiDataEnd = roiData + getNumberOfElements(roiShape); in bboxTransformFloat32() 114 std::vector<float> roi_float32(getNumberOfElements(roiShape)); in bboxTransformFloat16() 116 std::vector<float> delta_float32(getNumberOfElements(bboxDeltasShape)); in bboxTransformFloat16() 118 std::vector<float> imageInfo_float32(getNumberOfElements(imageInfoDataShape)); in bboxTransformFloat16() 120 std::vector<float> output_float32(getNumberOfElements(outputShape)); in bboxTransformFloat16() 134 std::vector<float> roi_float32(getNumberOfElements(roiShape)); in bboxTransformQuant() 136 std::vector<float> delta_float32(getNumberOfElements(bboxDeltasShape)); in bboxTransformQuant() 139 std::vector<float> imageInfo_float32(getNumberOfElements(imageInfoDataShape)); in bboxTransformQuant() 142 std::vector<float> output_float32(getNumberOfElements(outputShape)); in bboxTransformQuant() 156 std::vector<float> roi_float32(getNumberOfElements(roiShape)); in bboxTransformQuant() [all …]
|
D | Quantize.cpp | 45 uint32_t size = getNumberOfElements(outputShape); in quantizeToQuant8() 57 uint32_t size = getNumberOfElements(outputShape); in quantizeToQuant8Signed() 98 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in execute()
|
D | BidirectionalSequenceLSTM.cpp | 477 getNumberOfElements(fw_activation_state_->shape())); in Eval() 478 fw_output_cell_state.resize(getNumberOfElements(fw_cell_state_->shape())); in Eval() 483 std::vector<float> fw_scratch_buffer(getNumberOfElements(fw_scratch_shape_)); in Eval() 529 getNumberOfElements(bw_activation_state_->shape())); in Eval() 530 bw_output_cell_state.resize(getNumberOfElements(bw_cell_state_->shape())); in Eval() 535 std::vector<float> bw_scratch_buffer(getNumberOfElements(bw_scratch_shape_)); in Eval() 601 getNumberOfElements(fw_activation_state_->shape())); in Eval() 602 fw_output_cell_state.resize(getNumberOfElements(fw_cell_state_->shape())); in Eval() 607 std::vector<_Float16> fw_scratch_buffer(getNumberOfElements(fw_scratch_shape_)); in Eval() 654 getNumberOfElements(bw_activation_state_->shape())); in Eval() [all …]
|
D | ArgMinMax.cpp | 35 const int outerSize = getNumberOfElements(inputShape, 0, axis); in argMinMaxImpl() 38 getNumberOfElements(inputShape, axis + 1, getNumberOfDimensions(inputShape)); in argMinMaxImpl()
|
D | LocalResponseNormalization.cpp | 55 const uint32_t outerSize = getNumberOfElements(inputShape, 0, axis); in localResponseNormFloat32Impl() 58 getNumberOfElements(inputShape, axis + 1, getNumberOfDimensions(inputShape)); in localResponseNormFloat32Impl() 110 std::vector<float> inputDataFloat32(getNumberOfElements(inputShape)); in localResponseNorm() 112 std::vector<float> outputDataFloat32(getNumberOfElements(outputShape)); in localResponseNorm()
|
D | Elu.cpp | 48 int numElements = getNumberOfElements(inputShape); in eluFloat() 80 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in execute()
|
D | Dequantize.cpp | 40 const int numElements = getNumberOfElements(inputShape); in compute() 61 const int numElements = getNumberOfElements(inputShape); in computePerChannel() 117 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in execute()
|
D | Gather.cpp | 45 const auto outerSize = getNumberOfElements(inputShape, 0, axis); in eval() 48 getNumberOfElements(inputShape, axis + 1, getNumberOfDimensions(inputShape)); in eval() 49 const auto indicesCount = getNumberOfElements(indicesShape); in eval()
|
D | TransposeConv2D.cpp | 135 memset(outputData, 0, getNumberOfElements(outputShape) * sizeof(float)); in transposeConvNhwc() 190 uint32_t tempBufferByteSize = getNumberOfElements(outputShape) * sizeof(int32_t); in transposeConvNhwc() 282 std::vector<float> inputData_float32(getNumberOfElements(inputShape)); in transposeConvNhwc() 283 std::vector<float> filterData_float32(getNumberOfElements(filterShape)); in transposeConvNhwc() 284 std::vector<float> biasData_float32(getNumberOfElements(biasShape)); in transposeConvNhwc() 285 std::vector<float> outputData_float32(getNumberOfElements(outputShape)); in transposeConvNhwc() 326 uint32_t tempBufferByteSize = getNumberOfElements(outputShape) * sizeof(int32_t); in transposeConvQuant8PerChannelNhwc() 543 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in execute()
|
D | LogSoftmax.cpp | 44 const uint32_t outerSize = getNumberOfElements(shape, 0, axis); in compute() 46 const uint32_t innerSize = getNumberOfElements(shape, axis + 1, getNumberOfDimensions(shape)); in compute()
|
D | ChannelShuffle.cpp | 43 const uint32_t outerSize = getNumberOfElements(inputShape, 0, axis); in eval() 46 getNumberOfElements(inputShape, axis + 1, getNumberOfDimensions(inputShape)); in eval()
|
D | Concatenation.cpp | 114 const auto currentSize = getNumberOfElements(context->getInputShape(i)); in concatenation() 128 std::vector<uint8_t> output_uint8(getNumberOfElements(context->getOutputShape(kOutputTensor))); in concatenation() 209 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in execute()
|
D | Broadcast.cpp | 80 std::vector<float> in1_float32(getNumberOfElements(shape1)); in binaryOperationFloat16() 82 std::vector<float> in2_float32(getNumberOfElements(shape2)); in binaryOperationFloat16() 84 std::vector<float> out_float32(getNumberOfElements(shapeOut)); in binaryOperationFloat16() 323 uint32_t numOutputElements = getNumberOfElements(shapeOut); in subFloat32() 491 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in executeAdd() 541 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in executeMul() 591 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in executeSub() 641 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in executeDiv()
|
D | GroupedConv2D.cpp | 293 std::vector<float> inputData_float32(getNumberOfElements(inputShape)); in groupedConvFloat16() 294 std::vector<float> filterData_float32(getNumberOfElements(filterShape)); in groupedConvFloat16() 295 std::vector<float> biasData_float32(getNumberOfElements(biasShape)); in groupedConvFloat16() 296 std::vector<float> outputData_float32(getNumberOfElements(outputShape)); in groupedConvFloat16()
|
D | QuantizedLSTM.cpp | 383 std::vector<uint8_t> weights(getNumberOfElements(weightsShape)); in eval() 388 std::vector<int32_t> bias(getNumberOfElements(biasShape)); in eval() 398 std::vector<uint8_t> concatTemp(getNumberOfElements(concatTempShape)); in eval() 399 std::vector<int16_t> activationTemp(getNumberOfElements(activationTempShape)); in eval()
|
D | Conv2D.cpp | 259 std::vector<uint8_t> unsignedInput(getNumberOfElements(inputShape)); in convNhwc() 263 std::vector<uint8_t> unsignedFilter(getNumberOfElements(filterShape)); in convNhwc() 267 std::vector<uint8_t> unsignedOutput(getNumberOfElements(outputShape)); in convNhwc() 288 std::vector<float> inputData_float32(getNumberOfElements(inputShape)); in convNhwc() 289 std::vector<float> filterData_float32(getNumberOfElements(filterShape)); in convNhwc() 290 std::vector<float> biasData_float32(getNumberOfElements(biasShape)); in convNhwc() 291 std::vector<float> outputData_float32(getNumberOfElements(outputShape)); in convNhwc() 669 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in execute()
|
/frameworks/ml/nn/tools/test_generator/test_harness/ |
D | TestHarness.cpp | 62 uint32_t getNumberOfElements(const TestOperand& op) { in getNumberOfElements() function 73 uint32_t len = getNumberOfElements(op), numErrors = 0, numSkip = 0; in expectNear() 119 uint32_t len = getNumberOfElements(op), numErrors = 0; in expectBooleanNearlyEqual() 157 const uint32_t outputLength = getNumberOfElements(outputOperand); in expectMultinomialDistributionWithinTolerance() 164 const uint32_t inputLength = getNumberOfElements(inputOperand); in expectMultinomialDistributionWithinTolerance() 707 const uint32_t numberOfElements = getNumberOfElements(converted); in convertOperandToFloat32() 796 const uint32_t numberOfElements = getNumberOfElements(*op); in setDataFromFloat32Buffer()
|