Skip to content

Commit 305cda5

Browse files
authored
Sync from tflite-micro. (tensorflow#174)
1 parent 9a2336d commit 305cda5

10 files changed

+31
-4136
lines changed

src/tensorflow/lite/micro/kernels/leaky_relu_common.cpp

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -51,16 +51,15 @@ TfLiteStatus CalculateOpDataLeakyRelu(TfLiteContext* context,
5151
data->output_zero_point = output->params.zero_point;
5252

5353
int output_shift_alpha;
54-
double alpha_multiplier = static_cast<double>(input->params.scale) *
55-
static_cast<double>(params->alpha) /
56-
static_cast<double>(output->params.scale);
54+
double alpha_multiplier = static_cast<double>(
55+
input->params.scale * params->alpha / output->params.scale);
5756
QuantizeMultiplier(alpha_multiplier, &data->output_multiplier_alpha,
5857
&output_shift_alpha);
5958
data->output_shift_alpha = static_cast<int32_t>(output_shift_alpha);
6059

6160
int output_shift_identity;
62-
double identity_multiplier = static_cast<double>(input->params.scale) /
63-
static_cast<double>(output->params.scale);
61+
double identity_multiplier =
62+
static_cast<double>(input->params.scale / output->params.scale);
6463
QuantizeMultiplier(identity_multiplier, &data->output_multiplier_identity,
6564
&output_shift_identity);
6665
data->output_shift_identity = static_cast<int32_t>(output_shift_identity);

src/tensorflow/lite/micro/kernels/lstm_eval_internal.cpp

Lines changed: 0 additions & 1459 deletions
This file was deleted.

src/tensorflow/lite/micro/kernels/lstm_eval_internal.h

Lines changed: 0 additions & 315 deletions
This file was deleted.

0 commit comments

Comments
 (0)