/packages/modules/NeuralNetworks/common/operations/ |
D | Reshape.cpp | 34 bool copyData(const void* inputData, const Shape& inputShape, void* outputData, in copyData() argument 38 memcpy(outputData, inputData, count); in copyData() 44 T* outputData, const Shape& outputShape) { in depthToSpaceGeneric() argument 47 outputData, convertShapeToDims(outputShape)); in depthToSpaceGeneric() 51 int32_t blockSize, float* outputData, 54 int32_t blockSize, _Float16* outputData, 57 int32_t blockSize, uint8_t* outputData, 60 int32_t blockSize, int8_t* outputData, 65 T* outputData, const Shape& outputShape) { in spaceToDepthGeneric() argument 68 outputData, convertShapeToDims(outputShape)); in spaceToDepthGeneric() [all …]
|
D | Activation.cpp | 53 bool reluFloat(const T* inputData, const Shape& inputShape, T* outputData, const Shape& outputShape, in reluFloat() argument 57 for (int i = 0; i < numElements; i++, inputData++, outputData++) { in reluFloat() 58 *outputData = static_cast<T>( in reluFloat() 63 template bool reluFloat<float>(const float* inputData, const Shape& inputShape, float* outputData, 66 _Float16* outputData, const Shape& outputShape, float reluMin, 70 bool relu1Float(const T* inputData, const Shape& inputShape, T* outputData, in relu1Float() argument 72 return reluFloat(inputData, inputShape, outputData, outputShape, -1.f, 1.f); in relu1Float() 74 template bool relu1Float<float>(const float* inputData, const Shape& inputShape, float* outputData, 77 _Float16* outputData, const Shape& outputShape); 80 bool relu6Float(const T* inputData, const Shape& inputShape, T* outputData, in relu6Float() argument [all …]
|
D | Pooling.cpp | 142 float* outputData, const Shape& outputShape) { in averagePoolNhwc() argument 147 convertShapeToTflshape(outputShape), outputData); in averagePoolNhwc() 152 _Float16* outputData, const Shape& outputShape) { in averagePoolNhwc() argument 160 convertFloat32ToFloat16(outputDataFloat32, outputData); in averagePoolNhwc() 165 uint8_t* outputData, const Shape& outputShape) { in averagePoolNhwc() argument 170 convertShapeToTflshape(outputShape), outputData); in averagePoolNhwc() 175 int8_t* outputData, const Shape& outputShape) { in averagePoolNhwc() argument 183 outputData); in averagePoolNhwc() 188 float* outputData, const Shape& outputShape) { in l2PoolNhwc() argument 193 convertShapeToTflshape(outputShape), outputData); in l2PoolNhwc() [all …]
|
D | L2Normalization.cpp | 49 float* outputData, const Shape& outputShape) { in l2normFloat32Impl() argument 59 float* outputBeg = outputData + outer * axisSize * innerSize; in l2normFloat32Impl() 77 uint8_t* outputData, const Shape& outputShape) { in l2normQuant8Impl() argument 86 uint8_t* outputBeg = outputData + outer * axisSize * innerSize; in l2normQuant8Impl() 109 int8_t* outputData, const Shape& outputShape) { in l2normQuant8SignedImpl() argument 118 int8_t* outputBeg = outputData + outer * axisSize * innerSize; in l2normQuant8SignedImpl() 139 bool l2normFloat32(const float* inputData, const Shape& inputShape, int32_t axis, float* outputData, in l2normFloat32() argument 148 convertShapeToTflshape(outputShape), outputData); in l2normFloat32() 151 return l2normFloat32Impl(inputData, inputShape, axis, outputData, outputShape); in l2normFloat32() 156 _Float16* outputData, const Shape& outputShape) { in l2normFloat16() argument [all …]
|
D | SimpleMath.cpp | 34 const Shape& axisShape, bool keepDims, _Float16* outputData, in meanFloat16() argument 43 convertFloat32ToFloat16(outputDataFloat32, outputData); in meanFloat16() 49 bool keepDims, T* outputData, const Shape& outputShape) { in meanGeneric() argument 67 getNumberOfDimensions(inputShape), outputData, in meanGeneric() 79 float* outputData, const Shape& outputShape); 82 bool keepDims, uint8_t* outputData, 86 bool keepDims, int8_t* outputData,
|
D | Softmax.cpp | 54 int32_t axis, float* outputData, const Shape& outputShape) { in softmaxSlowFloat32() argument 63 float* outputBeg = outputData + outer * axisSize * innerSize; in softmaxSlowFloat32() 86 float* outputData, const Shape& outputShape) { in softmaxFloat32() argument 94 convertShapeToTflshape(outputShape), outputData); in softmaxFloat32() 97 return softmaxSlowFloat32(inputData, inputShape, beta, axis, outputData, outputShape); in softmaxFloat32() 102 int32_t axis, _Float16* outputData, const Shape& outputShape) { in softmaxFloat16() argument 110 convertFloat32ToFloat16(outputData_float32, outputData); in softmaxFloat16() 118 T* outputData, const Shape& outputShape) { in softmaxQuant8Impl() argument 138 T* outputBeg = outputData + outer * axisSize * innerSize; in softmaxQuant8Impl() 204 T* outputData, const Shape& outputShape) { in softmaxQuant8() argument [all …]
|
D | GroupedConv2D.cpp | 50 int32_t numGroups, int32_t activation, float* outputData, in groupedConvFloat32() argument 59 float* outPtr = outputData; in groupedConvFloat32() 108 int32_t numGroups, int32_t activation, T* outputData, in groupedConvQuant8() argument 131 T* outPtr = outputData; in groupedConvQuant8() 187 int32_t numGroups, int32_t activation, int8_t* outputData, 196 int32_t numGroups, int32_t activation, uint8_t* outputData, 206 int32_t activation, T* outputData, const Shape& outputShape) { in groupedConvQuant8PerChannel() argument 235 T* outPtr = outputData; in groupedConvQuant8PerChannel() 290 int32_t activation, _Float16* outputData, const Shape& outputShape) { in groupedConvFloat16() argument 306 convertFloat32ToFloat16(outputData_float32, outputData); in groupedConvFloat16() [all …]
|
D | LocalResponseNormalization.cpp | 53 int32_t axis, float* outputData, in localResponseNormFloat32Impl() argument 62 float* outputBase = outputData + outer * axisSize * innerSize; in localResponseNormFloat32Impl() 83 T beta, int32_t axis, T* outputData, const Shape& outputShape); 87 float bias, float alpha, float beta, int32_t axis, float* outputData, in localResponseNorm() argument 99 convertShapeToTflshape(outputShape), outputData); in localResponseNorm() 103 outputData, outputShape); in localResponseNorm() 110 _Float16* outputData, const Shape& outputShape) { in localResponseNorm() argument 118 convertFloat32ToFloat16(outputDataFloat32, outputData); in localResponseNorm()
|
D | Cast.cpp | 44 bool copyToTensor(const FromT* inputData, int numElements, uint8_t* outputData, in copyToTensor() argument 49 copyCast(inputData, reinterpret_cast<dataType*>(outputData), numElements); \ in copyToTensor() 72 bool eval(const uint8_t* inputData, const Shape& inputShape, uint8_t* outputData, in eval() argument 80 copyToTensor(reinterpret_cast<const dataType*>(inputData), numElements, outputData, \ in eval() 92 return copyData(inputData, inputShape, outputData, outputShape); in eval()
|
D | Pow.cpp | 35 const Shape& exponentShape, T* outputData, const Shape& outputShape) { in evalGeneric() argument 50 outputData[outputFlatIndex] = std::pow(static_cast<float>(baseData[baseFlatIndex]), in evalGeneric() 70 const Shape& exponentShape, void* outputData, const Shape& outputShape) { in eval() argument 75 reinterpret_cast<_Float16*>(outputData), outputShape); in eval() 80 reinterpret_cast<float*>(outputData), outputShape); in eval()
|
D | RNN.cpp | 119 const int32_t activation, T* outputData) { in RNNStep() argument 128 /*outputBatchStride=*/numUnits, /*outputBatchOffset=*/0, outputData); in RNNStep() 141 const uint32_t outputBatchStride, const uint32_t outputBatchOffset, T* outputData, in RNNStep() argument 168 T* output_ptr_batch = outputData + b * outputBatchStride + outputBatchOffset; in RNNStep() 228 _Float16* outputData); 237 const uint32_t outputBatchOffset, _Float16* outputData, 244 float* outputData); 253 float* outputData, float* hiddenStateOutput);
|
D | FullyConnected.cpp | 59 float* outputData, const Shape& outputShape) { in fullyConnectedFloat32() argument 74 outputData, convertShapeToDims(outputShape)); in fullyConnectedFloat32() 81 outputData, convertShapeToDims(outputShape)); in fullyConnectedFloat32() 89 _Float16* outputData, const Shape& outputShape) { in fullyConnectedFloat16() argument 102 convertFloat32ToFloat16(outputDataFloat32, outputData); in fullyConnectedFloat16() 110 uint8_t* outputData, const Shape& outputShape) { in fullyConnectedQuant8() argument 142 outputActivationMin, outputActivationMax, outputData, in fullyConnectedQuant8() 151 int8_t* outputData, const Shape& outputShape) { in fullyConnectedQuant8() argument 179 biasData, convertShapeToTflshape(outputShape), outputData); in fullyConnectedQuant8()
|
D | ResizeImageOps.cpp | 69 bool halfPixelCenters, T* outputData, const Shape& outputShape) { in resizeNearestNeighbor() argument 101 outputData + b * outHeight * outWidth * channels + in resizeNearestNeighbor() 112 bool alignCorners, bool halfPixelCenters, T* outputData, in resizeImageOpNhwc() argument 127 outDimData, convertShapeToTflshape(outputShape), outputData); in resizeImageOpNhwc() 131 resizeNearestNeighbor(inputData, inputShape, alignCorners, halfPixelCenters, outputData, in resizeImageOpNhwc() 140 _Float16* outputData, const Shape& outputShape) { in resizeImageOpNhwc() argument 147 convertFloat32ToFloat16(outputData_float32, outputData); in resizeImageOpNhwc() 153 bool alignCorners, bool halfPixelCenters, T* outputData, in resizeImageOp() argument 158 NN_RET_CHECK(output.initialize(outputData, outputShape)); in resizeImageOp()
|
D | TransposeConv2D.cpp | 128 const TransposeConv2dParam& param, float* outputData, in transposeConvNhwc() argument 136 memset(outputData, 0, getNumberOfElements(outputShape) * sizeof(float)); in transposeConvNhwc() 139 float* outputBase = outputData; in transposeConvNhwc() 171 float* outPtr = outputData; in transposeConvNhwc() 185 const TransposeConv2dParam& param, T* outputData, const Shape& outputShape) { in transposeConvNhwc() argument 263 T* outPtr = outputData; in transposeConvNhwc() 280 const TransposeConv2dParam& param, _Float16* outputData, in transposeConvNhwc() argument 295 convertFloat32ToFloat16(outputData_float32, outputData); in transposeConvNhwc() 303 const TransposeConv2dParam& param, T_Input* outputData, in transposeConv() argument 308 NN_RET_CHECK(output.initialize(outputData, outputShape)); in transposeConv() [all …]
|
D | Conv2D.cpp | 199 float* outputData, const Shape& outputShape) { in convNhwc() argument 218 output_activation_min, output_activation_max, outputData, in convNhwc() 228 uint8_t* outputData, const Shape& outputShape) { in convNhwc() argument 269 output_activation_min, output_activation_max, outputData, in convNhwc() 282 int8_t* outputData, Shape outputShape) { in convNhwc() argument 301 convertUInt8ToInt8(unsignedOutput, outputData); in convNhwc() 311 _Float16* outputData, const Shape& outputShape) { in convNhwc() argument 327 convertFloat32ToFloat16(outputData_float32, outputData); in convNhwc() 337 int32_t dilation_height_factor, int32_t activation, bool useNchw, T_Input* outputData, in conv() argument 342 NN_RET_CHECK(output.initialize(outputData, outputShape)); in conv() [all …]
|
D | DepthwiseConv2D.cpp | 138 int32_t depthMultiplier, int32_t activation, float* outputData, in depthwiseConvNhwc() argument 162 convertShapeToTflshape(outputShape), outputData); in depthwiseConvNhwc() 173 _Float16* outputData, const Shape& outputShape) { in depthwiseConvNhwc() argument 189 convertFloat32ToFloat16(outputDataFloat32, outputData); in depthwiseConvNhwc() 198 int32_t depthMultiplier, int32_t activation, uint8_t* outputData, in depthwiseConvNhwc() argument 238 convertShapeToTflshape(outputShape), outputData); in depthwiseConvNhwc() 249 int32_t depthMultiplier, int32_t activation, int8_t* outputData, in depthwiseConvNhwc() argument 270 convertUInt8ToInt8(unsignedOutput, outputData); in depthwiseConvNhwc() 283 int32_t depthMultiplier, int32_t activation, T* outputData, const Shape& outputShape) { in depthwiseConvQuant8PerChannelNhwc() argument 324 T* outPtr = outputData; in depthwiseConvQuant8PerChannelNhwc() [all …]
|
D | ArgMinMax.cpp | 30 Out* outputData, const Shape& outputShape) { in argMinMaxImpl() argument 46 outputData[outer * innerSize + inner] = minMaxIndex; in argMinMaxImpl() 52 uint8_t* outputData, const Shape& outputShape) { in argMinMaxGeneric() argument 60 reinterpret_cast<int32_t*>(outputData), outputShape); \ in argMinMaxGeneric()
|
D | RoiPooling.cpp | 58 T_Input* outputData, const Shape& outputShape) { in roiPoolingNhwc() argument 74 T_Input* outPtr = outputData; in roiPoolingNhwc() 147 bool useNchw, T_Input* outputData, const Shape& outputShape) { in roiPooling() argument 151 NN_RET_CHECK(output.initialize(outputData, outputShape)); in roiPooling() 164 float widthStride, bool useNchw, uint8_t* outputData, in roiPooling() argument 169 batchSplitShape, heightStride, widthStride, useNchw, outputData, in roiPooling() 179 float widthStride, bool useNchw, int8_t* outputData, in roiPooling() argument 184 batchSplitShape, heightStride, widthStride, useNchw, outputData, in roiPooling()
|
D | Tile.cpp | 69 void tileImpl(const T* inputData, const Shape& inputShape, const int32_t* multiples, T* outputData, in tileImpl() argument 71 TileOneDimension(inputShape, inputData, multiples, outputData, 0); in tileImpl() 91 uint8_t* outputData, const Shape& outputShape) { in eval() argument 97 reinterpret_cast<dataType*>(outputData), outputShape); \ in eval()
|
D | Quantize.cpp | 40 bool quantizeToQuant8(const T* inputData, uint8_t* outputData, const Shape& outputShape) { in quantizeToQuant8() argument 44 outputData[i] = static_cast<uint8_t>(std::max<float>( in quantizeToQuant8() 52 bool quantizeToQuant8Signed(const T* inputData, int8_t* outputData, const Shape& outputShape) { in quantizeToQuant8Signed() argument 56 outputData[i] = static_cast<int8_t>(std::max<float>( in quantizeToQuant8Signed()
|
D | MaximumMinimum.cpp | 36 bool isMinimum, T* outputData, const Shape& outputShape) { in evalGeneric() argument 51 outputData[outputFlatIndex] = isMinimum ? std::min(aData[aFlatIndex], bData[bFlatIndex]) in evalGeneric() 62 bool isMinimum, T* outputData, const Shape& outputShape) { in evalQuant8() argument 79 outputData[outputFlatIndex] = in evalQuant8()
|
D | SVDF.cpp | 164 float* outputData, float* outputStateData) { in EvalFloat32() argument 206 tflite::tensor_utils::ReductionSumVector(scratch, outputData, batch_size * num_units, rank); in EvalFloat32() 210 tflite::tensor_utils::VectorBatchVectorAdd(biasData, num_units, batch_size, outputData); in EvalFloat32() 214 tflite::tensor_utils::ApplyActivationToVector(outputData, batch_size * num_units, in EvalFloat32() 215 params_.activation_, outputData); in EvalFloat32()
|
/packages/modules/NeuralNetworks/common/include/ |
D | Operations.h | 49 bool floorFloat16(const _Float16* inputData, _Float16* outputData, const Shape& shape); 50 bool floorFloat32(const float* inputData, float* outputData, const Shape& shape); 58 _Float16* outputData, const Shape& outputShape); 64 int32_t depthMultiplier, int32_t activation, float* outputData, 72 uint8_t* outputData, const Shape& outputShape); 80 int32_t depthMultiplier, int32_t activation, uint8_t* outputData, 85 _Float16* outputData, const Shape& outputShape); 87 float bias, float alpha, float beta, int32_t axis, float* outputData, 90 bool copyData(const void* inputData, const Shape& inputShape, void* outputData, 95 T* outputData, const Shape& outputShape); [all …]
|
/packages/apps/Camera2/src/com/android/camera/app/ |
D | MemoryQuery.java | 104 HashMap outputData = new HashMap(); in queryMemory() local 105 outputData.put(KEY_TIMESTAMP, new Long(timestamp)); in queryMemory() 106 outputData.put(KEY_MEMORY_AVAILABLE, new Long(availMem)); in queryMemory() 107 outputData.put(KEY_TOTAL_MEMORY, new Long(totalMem)); in queryMemory() 108 outputData.put(KEY_TOTAL_PSS, new Long(totalPSS)); in queryMemory() 109 outputData.put(KEY_LAST_TRIM_LEVEL, new Integer(info.lastTrimLevel)); in queryMemory() 110 outputData.put(KEY_TOTAL_PRIVATE_DIRTY, new Long(totalPrivateDirty)); in queryMemory() 111 outputData.put(KEY_TOTAL_SHARED_DIRTY, new Long(totalSharedDirty)); in queryMemory() 112 outputData.put(KEY_MEMORY_CLASS, new Long(memoryClass)); in queryMemory() 113 outputData.put(KEY_LARGE_MEMORY_CLASS, new Long(largeMemoryClass)); in queryMemory() [all …]
|
/packages/modules/NeuralNetworks/runtime/test/ |
D | TestMemoryInternal.cpp | 152 uint8_t* outputData = in TEST_F() local 154 ASSERT_NE(outputData, nullptr); in TEST_F() 155 memset(outputData, 0, outputSize); in TEST_F() 169 CompareMatrices(expected3, *reinterpret_cast<Matrix3x4*>(outputData + offsetForActual)), in TEST_F() 174 munmap(outputData, outputSize); in TEST_F()
|