/external/tensorflow/tensorflow/lite/micro/kernels/ |
D | conv_common.cc | 162 const auto* affine_quantization = in ConvPrepare() local 164 TFLITE_DCHECK(affine_quantization != nullptr); in ConvPrepare() 165 TFLITE_DCHECK(affine_quantization->scale != nullptr); in ConvPrepare() 166 TFLITE_DCHECK(affine_quantization->zero_point != nullptr); in ConvPrepare() 169 affine_quantization->scale->size == 1 || in ConvPrepare() 170 affine_quantization->scale->size == in ConvPrepare() 172 TF_LITE_ENSURE_EQ(context, affine_quantization->scale->size, in ConvPrepare() 173 affine_quantization->zero_point->size); in ConvPrepare()
|
D | quantize.cc | 50 const auto* affine_quantization = in Prepare() local 52 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 53 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 54 TF_LITE_ENSURE(context, affine_quantization->scale->size == 1); in Prepare()
|
D | transpose_conv.cc | 162 const auto* affine_quantization = in Prepare() local 164 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 165 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 166 TF_LITE_ENSURE(context, affine_quantization->zero_point); in Prepare() 169 affine_quantization->scale->size == 1 || in Prepare() 170 affine_quantization->scale->size == in Prepare() 172 TF_LITE_ENSURE_EQ(context, affine_quantization->scale->size, in Prepare() 173 affine_quantization->zero_point->size); in Prepare()
|
D | depthwise_conv.cc | 143 const auto* affine_quantization = in Prepare() local 146 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 147 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 148 TF_LITE_ENSURE(context, affine_quantization->zero_point); in Prepare() 150 context, affine_quantization->scale->size == 1 || in Prepare() 151 affine_quantization->scale->size == in Prepare() 153 TF_LITE_ENSURE_EQ(context, affine_quantization->scale->size, in Prepare() 154 affine_quantization->zero_point->size); in Prepare()
|
/external/tensorflow/tensorflow/lite/micro/kernels/arc_mli/ |
D | mli_tf_utils.h | 68 const auto* affine_quantization = in ConvertToMliQuantParamsPerChannel() local 70 mliT->el_params.asym.dim = affine_quantization->quantized_dimension; in ConvertToMliQuantParamsPerChannel() 74 mliT->shape[affine_quantization->quantized_dimension]; in ConvertToMliQuantParamsPerChannel() 76 float* fscale = affine_quantization->scale->data; in ConvertToMliQuantParamsPerChannel()
|
D | depthwise_conv.cc | 82 const auto* affine_quantization = in IsMliApplicable() local 95 (affine_quantization->scale->size == in IsMliApplicable() 181 const auto* affine_quantization = in Prepare() local 184 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 185 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 186 TF_LITE_ENSURE(context, affine_quantization->zero_point); in Prepare() 188 context, affine_quantization->scale->size == 1 || in Prepare() 189 affine_quantization->scale->size == in Prepare() 191 TF_LITE_ENSURE_EQ(context, affine_quantization->scale->size, in Prepare() 192 affine_quantization->zero_point->size); in Prepare()
|
D | conv.cc | 97 const auto* affine_quantization = in IsMliApplicable() local 105 (affine_quantization->scale->size == in IsMliApplicable() 189 const auto* affine_quantization = in Prepare() local 191 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 192 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 193 TF_LITE_ENSURE(context, affine_quantization->zero_point); in Prepare() 196 affine_quantization->scale->size == 1 || in Prepare() 197 affine_quantization->scale->size == in Prepare() 199 TF_LITE_ENSURE_EQ(context, affine_quantization->scale->size, in Prepare() 200 affine_quantization->zero_point->size); in Prepare()
|
/external/tensorflow/tensorflow/lite/kernels/ |
D | kernel_util.cc | 195 const auto* affine_quantization = in PopulateConvolutionQuantizationParams() local 200 per_channel_shift, affine_quantization->scale->size); in PopulateConvolutionQuantizationParams() 221 const auto* affine_quantization = in PopulateConvolutionQuantizationParams() local 223 TF_LITE_ENSURE(context, affine_quantization); in PopulateConvolutionQuantizationParams() 224 TF_LITE_ENSURE(context, affine_quantization->scale); in PopulateConvolutionQuantizationParams() 225 const bool is_per_channel = affine_quantization->scale->size > 1; in PopulateConvolutionQuantizationParams() 231 TF_LITE_ENSURE_EQ(context, affine_quantization->scale->size, num_channels); in PopulateConvolutionQuantizationParams() 234 filter->dims->data[affine_quantization->quantized_dimension]); in PopulateConvolutionQuantizationParams() 240 const float* filter_scales = affine_quantization->scale->data; in PopulateConvolutionQuantizationParams()
|
D | depthwise_conv.cc | 179 const auto* affine_quantization = in Prepare() local 182 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 183 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 184 TF_LITE_ENSURE(context, (affine_quantization->scale->size == 1 || in Prepare() 185 affine_quantization->scale->size == channels_out)); in Prepare() 198 const auto* affine_quantization = in Prepare() local 201 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 202 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 204 context, affine_quantization->scale->size, in Prepare() 205 filter->dims->data[affine_quantization->quantized_dimension]); in Prepare() [all …]
|
D | conv.cc | 377 const auto* affine_quantization = in Prepare() local 380 const float scale = affine_quantization->scale->data[0]; in Prepare() 381 for (int i = 1; i < affine_quantization->scale->size; i++) { in Prepare() 382 if (affine_quantization->scale->data[i] != scale) { in Prepare() 426 const auto* affine_quantization = in Prepare() local 429 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 430 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 431 TF_LITE_ENSURE(context, (affine_quantization->scale->size == 1 || in Prepare() 432 affine_quantization->scale->size == channels_out)); in Prepare() 555 const auto* affine_quantization = in Prepare() local [all …]
|
D | quantize.cc | 109 const auto* affine_quantization = in Prepare() local 111 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 112 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 113 TF_LITE_ENSURE(context, affine_quantization->scale->size == 1); in Prepare()
|
D | elementwise_test.cc | 76 auto* affine_quantization = in ExtractDequantVector() local 78 float scaling_factor = affine_quantization->scale->data[0]; in ExtractDequantVector() 79 int zero_point = affine_quantization->zero_point->data[0]; in ExtractDequantVector()
|
D | test_util.h | 822 auto* affine_quantization = reinterpret_cast<TfLiteAffineQuantization*>( in QuantizeTensor() local 824 affine_quantization->quantized_dimension = 0; in QuantizeTensor() 825 affine_quantization->scale = TfLiteFloatArrayCreate(1); in QuantizeTensor() 826 affine_quantization->zero_point = TfLiteIntArrayCreate(1); in QuantizeTensor() 827 affine_quantization->scale->data[0] = scaling_factor; in QuantizeTensor() 828 affine_quantization->zero_point->data[0] = 0; in QuantizeTensor() 829 t->quantization.params = affine_quantization; in QuantizeTensor()
|
D | transpose_conv.cc | 372 const auto* affine_quantization = in Prepare() local 376 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 377 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 378 TF_LITE_ENSURE(context, (affine_quantization->scale->size == 1 || in Prepare() 379 affine_quantization->scale->size == channels_out)); in Prepare()
|
/external/tensorflow/tensorflow/lite/ |
D | interpreter.cc | 64 auto* affine_quantization = reinterpret_cast<TfLiteAffineQuantization*>( in GetQuantizationFromLegacy() local 66 affine_quantization->scale = TfLiteFloatArrayCreate(1); in GetQuantizationFromLegacy() 67 affine_quantization->zero_point = TfLiteIntArrayCreate(1); in GetQuantizationFromLegacy() 68 affine_quantization->scale->data[0] = legacy_quantization.scale; in GetQuantizationFromLegacy() 69 affine_quantization->zero_point->data[0] = legacy_quantization.zero_point; in GetQuantizationFromLegacy() 70 quantization.params = affine_quantization; in GetQuantizationFromLegacy()
|
D | interpreter_builder.cc | 407 auto* affine_quantization = reinterpret_cast<TfLiteAffineQuantization*>( in ParseQuantization() local 409 affine_quantization->scale = TfLiteFloatArrayCreate(num_scales); in ParseQuantization() 410 affine_quantization->zero_point = TfLiteIntArrayCreate(num_scales); in ParseQuantization() 412 affine_quantization->scale->data[i] = src_quantization->scale()->Get(i); in ParseQuantization() 413 affine_quantization->zero_point->data[i] = in ParseQuantization() 416 affine_quantization->quantized_dimension = in ParseQuantization() 418 quantization->params = reinterpret_cast<void*>(affine_quantization); in ParseQuantization()
|
/external/tensorflow/tensorflow/lite/micro/kernels/vexriscv/ |
D | depthwise_conv.cc | 378 const auto* affine_quantization = in Prepare() local 381 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 382 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 383 TF_LITE_ENSURE(context, affine_quantization->zero_point); in Prepare() 385 context, affine_quantization->scale->size == 1 || in Prepare() 386 affine_quantization->scale->size == in Prepare() 388 TF_LITE_ENSURE_EQ(context, affine_quantization->scale->size, in Prepare() 389 affine_quantization->zero_point->size); in Prepare()
|
/external/tensorflow/tensorflow/lite/micro/kernels/xtensa/ |
D | depthwise_conv.cc | 390 const auto* affine_quantization = in Prepare() local 393 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 394 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 395 TF_LITE_ENSURE(context, affine_quantization->zero_point); in Prepare() 397 context, affine_quantization->scale->size == 1 || in Prepare() 398 affine_quantization->scale->size == in Prepare() 400 TF_LITE_ENSURE_EQ(context, affine_quantization->scale->size, in Prepare() 401 affine_quantization->zero_point->size); in Prepare()
|
/external/tensorflow/tensorflow/lite/micro/kernels/cmsis_nn/ |
D | depthwise_conv.cc | 132 const auto* affine_quantization = in Prepare() local 135 TF_LITE_ENSURE(context, affine_quantization); in Prepare() 136 TF_LITE_ENSURE(context, affine_quantization->scale); in Prepare() 137 TF_LITE_ENSURE(context, affine_quantization->zero_point); in Prepare() 139 context, affine_quantization->scale->size == 1 || in Prepare() 140 affine_quantization->scale->size == in Prepare() 142 TF_LITE_ENSURE_EQ(context, affine_quantization->scale->size, in Prepare() 143 affine_quantization->zero_point->size); in Prepare()
|
/external/tensorflow/tensorflow/lite/core/ |
D | subgraph.cc | 130 auto* affine_quantization = in GetLegacyQuantization() local 132 if (!affine_quantization || !affine_quantization->scale || in GetLegacyQuantization() 133 !affine_quantization->zero_point || in GetLegacyQuantization() 134 affine_quantization->scale->size != 1 || in GetLegacyQuantization() 135 affine_quantization->zero_point->size != 1) { in GetLegacyQuantization() 140 legacy_quantization.scale = affine_quantization->scale->data[0]; in GetLegacyQuantization() 141 legacy_quantization.zero_point = affine_quantization->zero_point->data[0]; in GetLegacyQuantization()
|