/packages/modules/NeuralNetworks/common/cpu_operations/ |
D | Activation.cpp | 364 Shape input = context->getInputShape(kInputTensor); in prepare() 400 switch (context->getInputType(kInputTensor)) { in executeRelu() 402 return reluFloat(context->getInputBuffer<_Float16>(kInputTensor), in executeRelu() 403 context->getInputShape(kInputTensor), in executeRelu() 407 return reluFloat(context->getInputBuffer<float>(kInputTensor), in executeRelu() 408 context->getInputShape(kInputTensor), in executeRelu() 412 return reluQuant8(context->getInputBuffer<uint8_t>(kInputTensor), in executeRelu() 413 context->getInputShape(kInputTensor), in executeRelu() 417 return reluQuant8Signed(context->getInputBuffer<int8_t>(kInputTensor), in executeRelu() 418 context->getInputShape(kInputTensor), in executeRelu() [all …]
|
D | Elementwise.cpp | 74 switch (context->getInputType(kInputTensor)) { in execute() 76 return compute<float, _Float16>(func, context->getInputBuffer<_Float16>(kInputTensor), in execute() 77 context->getInputShape(kInputTensor), in execute() 80 return compute<float, float>(func, context->getInputBuffer<float>(kInputTensor), in execute() 81 context->getInputShape(kInputTensor), in execute() 91 switch (context->getInputType(kInputTensor)) { in executeAbs() 94 context->getInputBuffer<_Float16>(kInputTensor), in executeAbs() 95 context->getInputShape(kInputTensor), in executeAbs() 98 return compute<float, float>(std::abs, context->getInputBuffer<float>(kInputTensor), in executeAbs() 99 context->getInputShape(kInputTensor), in executeAbs() [all …]
|
D | Gather.cpp | 54 Shape input = context->getInputShape(kInputTensor); in prepare() 74 NN_RET_CHECK(handleNegativeAxis(context->getInputShape(kInputTensor), &axis)); in execute() 75 switch (context->getInputType(kInputTensor)) { in execute() 77 return eval(context->getInputBuffer<_Float16>(kInputTensor), in execute() 78 context->getInputShape(kInputTensor), axis, in execute() 83 return eval(context->getInputBuffer<float>(kInputTensor), in execute() 84 context->getInputShape(kInputTensor), axis, in execute() 89 return eval(context->getInputBuffer<int32_t>(kInputTensor), in execute() 90 context->getInputShape(kInputTensor), axis, in execute() 95 return eval(context->getInputBuffer<uint8_t>(kInputTensor), in execute() [all …]
|
D | ChannelShuffle.cpp | 53 Shape input = context->getInputShape(kInputTensor); in prepare() 65 NN_RET_CHECK(handleNegativeAxis(context->getInputShape(kInputTensor), &axis)); in execute() 66 switch (context->getInputType(kInputTensor)) { in execute() 68 return eval(context->getInputBuffer<_Float16>(kInputTensor), in execute() 69 context->getInputShape(kInputTensor), numGroups, axis, in execute() 72 return eval(context->getInputBuffer<float>(kInputTensor), in execute() 73 context->getInputShape(kInputTensor), numGroups, axis, in execute() 76 return eval(context->getInputBuffer<uint8_t>(kInputTensor), in execute() 77 context->getInputShape(kInputTensor), numGroups, axis, in execute() 80 return eval(context->getInputBuffer<int8_t>(kInputTensor), in execute() [all …]
|
D | Neg.cpp | 44 Shape input = context->getInputShape(kInputTensor); in prepare() 51 switch (context->getInputType(kInputTensor)) { in execute() 53 return compute(context->getInputBuffer<_Float16>(kInputTensor), in execute() 54 context->getInputShape(kInputTensor), in execute() 57 return compute(context->getInputBuffer<float>(kInputTensor), in execute() 58 context->getInputShape(kInputTensor), in execute() 61 return compute(context->getInputBuffer<int32_t>(kInputTensor), in execute() 62 context->getInputShape(kInputTensor), in execute()
|
D | Transpose.cpp | 76 NN_RET_CHECK(!context->isOmittedInput(kInputTensor)); in prepare() 79 const Shape& input = context->getInputShape(kInputTensor); in prepare() 116 switch (context->getInputType(kInputTensor)) { in execute() 118 return transposeGeneric(context->getInputBuffer<float>(kInputTensor), in execute() 119 context->getInputShape(kInputTensor), in execute() 125 return transposeGeneric(context->getInputBuffer<_Float16>(kInputTensor), in execute() 126 context->getInputShape(kInputTensor), in execute() 132 return transposeGeneric(context->getInputBuffer<uint8_t>(kInputTensor), in execute() 133 context->getInputShape(kInputTensor), in execute() 139 return transposeGeneric(context->getInputBuffer<int8_t>(kInputTensor), in execute() [all …]
|
D | Slice.cpp | 78 const Shape& inputShape = context->getInputShape(kInputTensor); in prepare() 113 switch (context->getInputType(kInputTensor)) { in execute() 115 return evalGeneric(context->getInputBuffer<_Float16>(kInputTensor), in execute() 116 context->getInputShape(kInputTensor), in execute() 124 return evalGeneric(context->getInputBuffer<float>(kInputTensor), in execute() 125 context->getInputShape(kInputTensor), in execute() 133 return evalGeneric(context->getInputBuffer<int32_t>(kInputTensor), in execute() 134 context->getInputShape(kInputTensor), in execute() 142 return evalGeneric(context->getInputBuffer<uint8_t>(kInputTensor), in execute() 143 context->getInputShape(kInputTensor), in execute() [all …]
|
D | PRelu.cpp | 101 Shape input = context->getInputShape(kInputTensor); in prepare() 110 switch (context->getInputType(kInputTensor)) { in execute() 116 context->getInputBuffer<_Float16>(kInputTensor), in execute() 117 context->getInputShape(kInputTensor), in execute() 127 context->getInputBuffer<float>(kInputTensor), in execute() 128 context->getInputShape(kInputTensor), in execute() 134 return evalQuant8(context->getInputBuffer<uint8_t>(kInputTensor), in execute() 135 context->getInputShape(kInputTensor), in execute() 142 return evalQuant8(context->getInputBuffer<int8_t>(kInputTensor), in execute() 143 context->getInputShape(kInputTensor), in execute()
|
D | LogSoftmax.cpp | 66 return context->setOutputShape(kOutputTensor, context->getInputShape(kInputTensor)); in prepare() 71 NN_RET_CHECK(handleNegativeAxis(context->getInputShape(kInputTensor), &axis)); in execute() 72 switch (context->getInputType(kInputTensor)) { in execute() 74 return compute(context->getInputBuffer<_Float16>(kInputTensor), in execute() 75 context->getInputShape(kInputTensor), in execute() 79 return compute(context->getInputBuffer<float>(kInputTensor), in execute() 80 context->getInputShape(kInputTensor), in execute()
|
D | Elu.cpp | 50 Shape inputShape = context->getInputShape(kInputTensor); in prepare() 57 switch (context->getInputType(kInputTensor)) { in execute() 59 return eluFloat(context->getInputBuffer<_Float16>(kInputTensor), in execute() 60 context->getInputShape(kInputTensor), in execute() 65 return eluFloat(context->getInputBuffer<float>(kInputTensor), in execute() 66 context->getInputShape(kInputTensor), in execute()
|
D | FullyConnected.cpp | 183 Shape input = context->getInputShape(kInputTensor); in prepare() 194 switch (context->getInputType(kInputTensor)) { in execute() 196 return fullyConnectedFloat32(context->getInputBuffer<float>(kInputTensor), in execute() 197 context->getInputShape(kInputTensor), in execute() 206 return fullyConnectedFloat16(context->getInputBuffer<_Float16>(kInputTensor), in execute() 207 context->getInputShape(kInputTensor), in execute() 216 return fullyConnectedQuant8(context->getInputBuffer<uint8_t>(kInputTensor), in execute() 217 context->getInputShape(kInputTensor), in execute() 226 return fullyConnectedQuant8(context->getInputBuffer<int8_t>(kInputTensor), in execute() 227 context->getInputShape(kInputTensor), in execute()
|
D | Dequantize.cpp | 75 const Shape& input = context->getInputShape(kInputTensor); in prepare() 86 const OperandType inputType = context->getInputType(kInputTensor); in execute() 89 const Shape& inputShape = context->getInputShape(kInputTensor); in execute() 91 const uint8_t* inputBuffer = context->getInputBuffer<uint8_t>(kInputTensor); in execute() 99 const int8_t* inputBuffer = context->getInputBuffer<int8_t>(kInputTensor); in execute() 107 const int8_t* inputBuffer = context->getInputBuffer<int8_t>(kInputTensor); in execute() 115 const int8_t* inputBuffer = context->getInputBuffer<int8_t>(kInputTensor); in execute()
|
D | Quantize.cpp | 64 const Shape& input = context->getInputShape(kInputTensor); in prepare() 74 const OperandType inputType = context->getInputType(kInputTensor); in execute() 78 return quantizeToQuant8<float>(context->getInputBuffer<float>(kInputTensor), in execute() 82 return quantizeToQuant8Signed<float>(context->getInputBuffer<float>(kInputTensor), in execute() 88 return quantizeToQuant8<_Float16>(context->getInputBuffer<_Float16>(kInputTensor), in execute() 92 return quantizeToQuant8Signed<_Float16>(context->getInputBuffer<_Float16>(kInputTensor), in execute()
|
D | Reduce.cpp | 46 const Shape inputShape = context->getInputShape(kInputTensor); in compute() 54 context->getInputBuffer<T>(kInputTensor), in compute() 66 Shape inputShape = context->getInputShape(kInputTensor); in prepare() 104 switch (context->getInputType(kInputTensor)) { in executeProd() 123 switch (context->getInputType(kInputTensor)) { in executeSum() 134 switch (context->getInputType(kInputTensor)) { in executeMax() 153 switch (context->getInputType(kInputTensor)) { in executeMin() 172 switch (context->getInputType(kInputTensor)) { in executeAny() 182 switch (context->getInputType(kInputTensor)) { in executeAll()
|
D | L2Normalization.cpp | 202 const Shape& input = context->getInputShape(kInputTensor); in prepare() 230 NN_RET_CHECK(handleNegativeAxis(context->getInputShape(kInputTensor), &axis)); in execute() 231 switch (context->getInputType(kInputTensor)) { in execute() 233 return l2normFloat32(context->getInputBuffer<float>(kInputTensor), in execute() 234 context->getInputShape(kInputTensor), axis, in execute() 238 return l2normFloat16(context->getInputBuffer<_Float16>(kInputTensor), in execute() 239 context->getInputShape(kInputTensor), axis, in execute() 243 return l2normQuant8(context->getInputBuffer<uint8_t>(kInputTensor), in execute() 244 context->getInputShape(kInputTensor), axis, in execute() 248 return l2normQuant8Signed(context->getInputBuffer<int8_t>(kInputTensor), in execute() [all …]
|
D | ResizeImageOps.cpp | 170 Shape input = context->getInputShape(kInputTensor); in prepare() 228 switch (context->getInputType(kInputTensor)) { in execute() 230 return resizeImageOp(opType, context->getInputBuffer<_Float16>(kInputTensor), in execute() 231 context->getInputShape(kInputTensor), useNchw, alignCorners, in execute() 236 return resizeImageOp(opType, context->getInputBuffer<float>(kInputTensor), in execute() 237 context->getInputShape(kInputTensor), useNchw, alignCorners, in execute() 241 return resizeImageOp(opType, context->getInputBuffer<uint8_t>(kInputTensor), in execute() 242 context->getInputShape(kInputTensor), useNchw, alignCorners, in execute() 246 return resizeImageOp(opType, context->getInputBuffer<int8_t>(kInputTensor), in execute() 247 context->getInputShape(kInputTensor), useNchw, alignCorners, in execute()
|
D | Softmax.cpp | 232 Shape input = context->getInputShape(kInputTensor); in prepare() 249 switch (context->getInputType(kInputTensor)) { in execute() 251 return softmaxFloat16(context->getInputBuffer<_Float16>(kInputTensor), in execute() 252 context->getInputShape(kInputTensor), in execute() 257 return softmaxFloat32(context->getInputBuffer<float>(kInputTensor), in execute() 258 context->getInputShape(kInputTensor), in execute() 263 return softmaxQuant8(context->getInputBuffer<uint8_t>(kInputTensor), in execute() 264 context->getInputShape(kInputTensor), in execute() 269 return softmaxQuant8(context->getInputBuffer<int8_t>(kInputTensor), in execute() 270 context->getInputShape(kInputTensor), in execute()
|
D | Squeeze.cpp | 36 NN_RET_CHECK(!context->isOmittedInput(kInputTensor)); in prepare() 40 const Shape inputShape = context->getInputShape(kInputTensor); in prepare() 92 switch (context->getInputType(kInputTensor)) { in execute() 97 return copyData(context->getInputBuffer(kInputTensor), in execute() 98 context->getInputShape(kInputTensor), in execute()
|
D | RoiPooling.cpp | 180 Shape input = context->getInputShape(kInputTensor); in prepare() 197 if (context->getInputType(kInputTensor) == OperandType::TENSOR_FLOAT16) { in prepare() 226 switch (context->getInputType(kInputTensor)) { in execute() 228 return roiPooling(context->getInputBuffer<_Float16>(kInputTensor), in execute() 229 context->getInputShape(kInputTensor), in execute() 240 return roiPooling(context->getInputBuffer<float>(kInputTensor), in execute() 241 context->getInputShape(kInputTensor), in execute() 252 return roiPooling(context->getInputBuffer<uint8_t>(kInputTensor), in execute() 253 context->getInputShape(kInputTensor), in execute() 264 return roiPooling(context->getInputBuffer<int8_t>(kInputTensor), in execute() [all …]
|
D | InstanceNormalization.cpp | 97 Shape input = context->getInputShape(kInputTensor); in prepare() 103 switch (context->getInputType(kInputTensor)) { in execute() 105 return instanceNorm(context->getInputBuffer<_Float16>(kInputTensor), in execute() 106 context->getInputShape(kInputTensor), in execute() 114 return instanceNorm(context->getInputBuffer<float>(kInputTensor), in execute() 115 context->getInputShape(kInputTensor), in execute()
|
D | Reverse.cpp | 41 const Shape inputShape = context->getInputShape(kInputTensor); in prepare() 66 convertShapeToTflshape(context->getInputShape(kInputTensor)); in reverse() 69 tensorShape, context->getInputBuffer<T>(kInputTensor), in reverse() 75 switch (context->getInputType(kInputTensor)) { in execute()
|
/packages/modules/NeuralNetworks/common/types/operations/src/ |
D | MirrorPad.cpp | 31 const OperandType inputTensorType = context->getInputType(kInputTensor); in validate() 56 const Shape inputTensorShape = context->getInputShape(kInputTensor); in validate() 61 << "Input tensor #" << kInputTensor << " scale " << inputTensorShape.scale in validate() 64 << "Input tensor #" << kInputTensor << " offset " << inputTensorShape.offset in validate() 74 << kInputTensor << " rank " << inputTensorRank; in validate() 81 << "Input tensor #" << kInputTensor << " rank " << inputTensorRank in validate()
|
D | Reduce.cpp | 27 OperandType inputType = context->getInputType(kInputTensor); in validateProdSum() 34 const Shape& input = context->getInputShape(kInputTensor); in validateProdSum() 44 OperandType inputType = context->getInputType(kInputTensor); in validateMaxMin() 57 const Shape& input = context->getInputShape(kInputTensor); in validateMaxMin() 67 OperandType inputType = context->getInputType(kInputTensor); in validateLogical() 73 const Shape& input = context->getInputShape(kInputTensor); in validateLogical()
|
D | Reverse.cpp | 31 const OperandType inputTensorType = context->getInputType(kInputTensor); in validate() 53 const Shape inputTensorShape = context->getInputShape(kInputTensor); in validate() 58 << "Input tensor #" << kInputTensor << " scale " << inputTensorShape.scale in validate() 61 << "Input tensor #" << kInputTensor << " offset " << inputTensorShape.offset in validate() 67 << "Input tensor #" << kInputTensor << " rank " << inputTensorRank << " does not match " in validate()
|
D | Elementwise.cpp | 27 OperandType inputType = context->getInputType(kInputTensor); in validate() 39 OperandType inputType = context->getInputType(kInputTensor); in validateAbs() 52 OperandType inputType = context->getInputType(kInputTensor); in validateFloor() 59 const Shape& input = context->getInputShape(kInputTensor); in validateFloor() 70 OperandType inputType = context->getInputType(kInputTensor); in validateRsqrt()
|