Home
last modified time | relevance | path

Searched refs:n_cell (Results 1 – 20 of 20) sorted by relevance

/external/tensorflow/tensorflow/lite/kernels/
Dbidirectional_sequence_lstm_test.cc32 BidirectionalLSTMOpModel(int n_batch, int n_input, int n_cell, int n_output, in BidirectionalLSTMOpModel() argument
42 n_fw_cell_(n_cell), in BidirectionalLSTMOpModel()
43 n_bw_cell_(n_cell), in BidirectionalLSTMOpModel()
433 const int n_cell = 4; in TEST_P() local
441 n_batch, n_input, n_cell, n_output, sequence_length, /*use_cifg=*/false, in TEST_P()
450 {n_cell, n_input}, // input_to_input_weight tensor in TEST_P()
451 {n_cell, n_input}, // input_to_forget_weight tensor in TEST_P()
452 {n_cell, n_input}, // input_to_cell_weight tensor in TEST_P()
453 {n_cell, n_input}, // input_to_output_weight tensor in TEST_P()
455 {n_cell, n_output}, // recurrent_to_input_weight tensor in TEST_P()
[all …]
Dunidirectional_sequence_lstm_test.cc32 UnidirectionalLSTMOpModel(int n_batch, int n_input, int n_cell, int n_output, in UnidirectionalLSTMOpModel() argument
43 n_cell_(n_cell), in UnidirectionalLSTMOpModel()
288 int n_batch, int n_input, int n_cell, int n_output, int sequence_length, in HybridUnidirectionalLSTMOpModel() argument
294 n_batch, n_input, n_cell, n_output, sequence_length, time_major, in HybridUnidirectionalLSTMOpModel()
503 const int n_cell = 4; in TEST_F() local
508 n_batch, n_input, n_cell, n_output, sequence_length, in TEST_F()
516 {n_cell, n_input}, // input_to_input_weight tensor in TEST_F()
517 {n_cell, n_input}, // input_to_forget_weight tensor in TEST_F()
518 {n_cell, n_input}, // input_to_cell_weight tensor in TEST_F()
519 {n_cell, n_input}, // input_to_output_weight tensor in TEST_F()
[all …]
Dlstm_eval.cc48 int32_t* projection_weights_row_sums, int32_t* row_sums, int n_cell, in ComputeRowSums() argument
67 input_to_input_row_sums, n_cell, n_input); in ComputeRowSums()
70 input_to_forget_row_sums, n_cell, n_input); in ComputeRowSums()
72 input_to_cell_row_sums, n_cell, n_input); in ComputeRowSums()
74 input_to_output_row_sums, n_cell, n_input); in ComputeRowSums()
79 aux_input_to_input_row_sums, n_cell, in ComputeRowSums()
83 aux_input_to_forget_row_sums, n_cell, in ComputeRowSums()
86 aux_input_to_cell_row_sums, n_cell, in ComputeRowSums()
89 aux_input_to_output_row_sums, n_cell, in ComputeRowSums()
94 recurrent_to_input_row_sums, n_cell, in ComputeRowSums()
[all …]
Doptional_tensor_test.cc31 LSTMOpModel(int n_batch, int n_input, int n_cell, int n_output, bool use_cifg, in LSTMOpModel() argument
37 n_cell_(n_cell), in LSTMOpModel()
232 const int n_cell = 4; in TEST() local
235 LSTMOpModel lstm(n_batch, n_input, n_cell, n_output, in TEST()
244 {n_cell, n_input}, // input_to_forget_weight tensor in TEST()
245 {n_cell, n_input}, // input_to_cell_weight tensor in TEST()
246 {n_cell, n_input}, // input_to_output_weight tensor in TEST()
249 {n_cell, n_output}, // recurrent_to_forget_weight tensor in TEST()
250 {n_cell, n_output}, // recurrent_to_cell_weight tensor in TEST()
251 {n_cell, n_output}, // recurrent_to_output_weight tensor in TEST()
[all …]
Dlstm_test.cc39 LSTMOpModel(int n_batch, int n_input, int n_cell, int n_output, bool use_cifg, in LSTMOpModel() argument
53 input_to_input_weights_ = AddInput({weight_type, {n_cell, n_input}}); in LSTMOpModel()
55 input_to_forget_weights_ = AddInput({weight_type, {n_cell, n_input}}); in LSTMOpModel()
56 input_to_cell_weights_ = AddInput({weight_type, {n_cell, n_input}}); in LSTMOpModel()
57 input_to_output_weights_ = AddInput({weight_type, {n_cell, n_input}}); in LSTMOpModel()
62 recurrent_to_input_weights_ = AddInput({weight_type, {n_cell, n_output}}); in LSTMOpModel()
64 recurrent_to_forget_weights_ = AddInput({weight_type, {n_cell, n_output}}); in LSTMOpModel()
65 recurrent_to_cell_weights_ = AddInput({weight_type, {n_cell, n_output}}); in LSTMOpModel()
66 recurrent_to_output_weights_ = AddInput({weight_type, {n_cell, n_output}}); in LSTMOpModel()
72 cell_to_input_weights_ = AddInput({weight_type, {n_cell}}); in LSTMOpModel()
[all …]
Dunidirectional_sequence_lstm.cc411 int n_output, int n_cell, in CheckInputTensorDimensions() argument
425 TF_LITE_ENSURE_EQ(context, input_to_input_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
435 TF_LITE_ENSURE_EQ(context, input_to_forget_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
443 TF_LITE_ENSURE_EQ(context, input_to_cell_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
451 n_cell); in CheckInputTensorDimensions()
463 n_cell); in CheckInputTensorDimensions()
473 TF_LITE_ENSURE_EQ(context, recurrent_to_cell_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
490 TF_LITE_ENSURE_EQ(context, cell_to_input_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
500 TF_LITE_ENSURE_EQ(context, cell_to_forget_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
510 TF_LITE_ENSURE_EQ(context, cell_to_output_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
[all …]
Dbidirectional_sequence_lstm.cc177 int n_cell, int input_to_input_weights_tensor, in CheckLstmTensorDimensionsAndTypes() argument
201 TF_LITE_ENSURE_EQ(context, input_to_forget_weights->dims->data[0], n_cell); in CheckLstmTensorDimensionsAndTypes()
211 TF_LITE_ENSURE_EQ(context, input_to_input_weights->dims->data[0], n_cell); in CheckLstmTensorDimensionsAndTypes()
222 TF_LITE_ENSURE_EQ(context, input_to_cell_weights->dims->data[0], n_cell); in CheckLstmTensorDimensionsAndTypes()
232 TF_LITE_ENSURE_EQ(context, input_to_output_weights->dims->data[0], n_cell); in CheckLstmTensorDimensionsAndTypes()
242 n_cell); in CheckLstmTensorDimensionsAndTypes()
255 n_cell); in CheckLstmTensorDimensionsAndTypes()
266 TF_LITE_ENSURE_EQ(context, recurrent_to_cell_weights->dims->data[0], n_cell); in CheckLstmTensorDimensionsAndTypes()
285 TF_LITE_ENSURE_EQ(context, cell_to_input_weights->dims->data[0], n_cell); in CheckLstmTensorDimensionsAndTypes()
294 TF_LITE_ENSURE_EQ(context, cell_to_forget_weights->dims->data[0], n_cell); in CheckLstmTensorDimensionsAndTypes()
[all …]
Dlstm.cc854 int n_output, int n_cell, in CheckInputTensorDimensions() argument
869 TF_LITE_ENSURE_EQ(context, input_to_forget_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
880 TF_LITE_ENSURE_EQ(context, input_to_input_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
891 TF_LITE_ENSURE_EQ(context, input_to_cell_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
901 n_cell); in CheckInputTensorDimensions()
914 n_cell); in CheckInputTensorDimensions()
925 TF_LITE_ENSURE_EQ(context, recurrent_to_cell_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
944 TF_LITE_ENSURE_EQ(context, cell_to_input_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
954 TF_LITE_ENSURE_EQ(context, cell_to_forget_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
964 TF_LITE_ENSURE_EQ(context, cell_to_output_weights->dims->data[0], n_cell); in CheckInputTensorDimensions()
[all …]
/external/tensorflow/tensorflow/lite/tools/optimize/calibration/custom_logging_ops/
Dlstm.cc63 const TfLiteLSTMParams* params, int n_batch, int n_cell, int n_input, in LstmStepWithAuxInput() argument
80 std::fill_n(input_gate_scratch, n_cell * n_batch, 0.0f); in LstmStepWithAuxInput()
82 std::fill_n(forget_gate_scratch, n_cell * n_batch, 0.0f); in LstmStepWithAuxInput()
83 std::fill_n(cell_scratch, n_cell * n_batch, 0.0f); in LstmStepWithAuxInput()
84 std::fill_n(output_gate_scratch, n_cell * n_batch, 0.0f); in LstmStepWithAuxInput()
87 tensor_utils::VectorBatchVectorAssign(input_gate_bias_ptr, n_cell, in LstmStepWithAuxInput()
90 tensor_utils::VectorBatchVectorAssign(forget_gate_bias_ptr, n_cell, n_batch, in LstmStepWithAuxInput()
92 tensor_utils::VectorBatchVectorAssign(cell_bias_ptr, n_cell, n_batch, in LstmStepWithAuxInput()
94 tensor_utils::VectorBatchVectorAssign(output_gate_bias_ptr, n_cell, n_batch, in LstmStepWithAuxInput()
101 input_to_input_weights_ptr, n_cell, n_input, input_ptr, n_batch, in LstmStepWithAuxInput()
[all …]
/external/tensorflow/tensorflow/lite/delegates/gpu/cl/kernels/
Dlstm_full_test.cc35 LSTMOpModel(int n_batch, int n_input, int n_cell, int n_output, bool use_cifg, in LSTMOpModel() argument
70 AddConstInput({weight_type, {n_cell, n_input}}, input_to_input_weights); in LSTMOpModel()
72 AddConstInput({weight_type, {n_cell, n_input}}, input_to_forget_weights); in LSTMOpModel()
73 AddConstInput({weight_type, {n_cell, n_input}}, input_to_cell_weights); in LSTMOpModel()
74 AddConstInput({weight_type, {n_cell, n_input}}, input_to_output_weights); in LSTMOpModel()
79 AddConstInput({weight_type, {n_cell, n_output}}, in LSTMOpModel()
82 AddConstInput({weight_type, {n_cell, n_output}}, in LSTMOpModel()
84 AddConstInput({weight_type, {n_cell, n_output}}, recurrent_to_cell_weights); in LSTMOpModel()
85 AddConstInput({weight_type, {n_cell, n_output}}, in LSTMOpModel()
92 AddConstInput({weight_type, {n_cell}}, cell_to_input_weights); in LSTMOpModel()
[all …]
/external/tensorflow/tensorflow/lite/tools/optimize/calibration/builtin_logging_ops/
Dlstm.cc47 const int n_output, const int n_cell, in CalculateLstmGateFloat() argument
58 std::fill_n(gate, n_cell * n_batch, 0.0f); in CalculateLstmGateFloat()
60 tensor_utils::VectorBatchVectorAssign(gate_bias, n_cell, n_batch, gate); in CalculateLstmGateFloat()
66 input_to_gate_weights, n_cell, n_input, input, n_batch, gate); in CalculateLstmGateFloat()
72 n_cell, n_aux_input, in CalculateLstmGateFloat()
77 recurrent_to_gate_weights, n_cell, n_output, output_state, n_batch, gate); in CalculateLstmGateFloat()
81 cell_to_gate_weights, n_cell, cell_state, n_batch, gate); in CalculateLstmGateFloat()
85 logger->LogTensorValue(intermediate_tensor_index, gate, n_cell * n_batch, in CalculateLstmGateFloat()
88 tensor_utils::MeanStddevNormalization(gate, gate, n_cell, n_batch); in CalculateLstmGateFloat()
89 tensor_utils::VectorBatchVectorCwiseProduct(layer_norm_coefficients, n_cell, in CalculateLstmGateFloat()
[all …]
/external/tensorflow/tensorflow/lite/delegates/nnapi/
Dnnapi_delegate_test.cc3092 LSTMOpModel(int n_batch, int n_input, int n_cell, int n_output, bool use_cifg, in LSTMOpModel() argument
3099 n_cell_(n_cell), in LSTMOpModel()
3458 const int n_cell = 4; in TEST_F() local
3461 LSTMOpModel lstm(n_batch, n_input, n_cell, n_output, in TEST_F()
3469 {n_cell, n_input}, // input_to_input_weight tensor in TEST_F()
3470 {n_cell, n_input}, // input_to_forget_weight tensor in TEST_F()
3471 {n_cell, n_input}, // input_to_cell_weight tensor in TEST_F()
3472 {n_cell, n_input}, // input_to_output_weight tensor in TEST_F()
3474 {n_cell, n_output}, // recurrent_to_input_weight_tensor in TEST_F()
3475 {n_cell, n_output}, // recurrent_to_forget_weight_tensor in TEST_F()
[all …]
/external/tensorflow/tensorflow/lite/kernels/internal/reference/
Dportable_tensor_utils.h153 int32_t n_batch, int32_t n_input, int32_t n_cell, in MatrixBatchVectorMultiply() argument
158 n_input, n_cell, gate_output, gate_output_zp); in MatrixBatchVectorMultiply()
309 int32_t n_cell, int16_t* output) { in TwoGateSaturatingAdd() argument
313 recurrent_effective_scale_b, n_batch, n_cell, output); in TwoGateSaturatingAdd()
Dportable_tensor_utils_impl.h126 int32_t n_cell, int8_t* gate_output,
228 int32_t n_batch, int32_t n_cell,
Dportable_tensor_utils.cc348 int32_t n_cell, int8_t* gate_output, in PortableMatrixBatchVectorMultiply() argument
353 for (int row = 0; row < n_cell; ++row) { in PortableMatrixBatchVectorMultiply()
369 gate_output[batch * n_cell + row] = static_cast<int8_t>(acc); in PortableMatrixBatchVectorMultiply()
750 int32_t n_batch, int32_t n_cell, in PortableTwoGateSaturatingAdd() argument
754 for (int i = 0; i < n_batch * n_cell; ++i) { in PortableTwoGateSaturatingAdd()
/external/tensorflow/tensorflow/lite/kernels/internal/optimized/
Dneon_tensor_utils.h114 int32_t n_batch, int32_t n_input, int32_t n_cell, in MatrixBatchVectorMultiply() argument
119 n_input, n_cell, gate_output, gate_output_zp); in MatrixBatchVectorMultiply()
306 int32_t n_cell, int16_t* output) { in TwoGateSaturatingAdd() argument
310 recurrent_effective_scale_b, n_batch, n_cell, output); in TwoGateSaturatingAdd()
Dsse_tensor_utils.h123 int32_t n_batch, int32_t n_input, int32_t n_cell, in MatrixBatchVectorMultiply() argument
128 n_input, n_cell, gate_output, gate_output_zp); in MatrixBatchVectorMultiply()
315 int32_t n_cell, int16_t* output) { in TwoGateSaturatingAdd() argument
319 recurrent_effective_scale_b, n_batch, n_cell, output); in TwoGateSaturatingAdd()
/external/tensorflow/tensorflow/lite/kernels/internal/
Dtensor_utils_common.h163 int32_t n_batch, int32_t n_input, int32_t n_cell,
461 int32_t n_cell, int16_t* output);
Dtensor_utils_test.cc1980 int32_t n_cell, int16_t* output);
/external/tensorflow/tensorflow/compiler/mlir/lite/ir/
Dtfl_ops.cc2028 const int n_cell = input_to_output_weights.getDimSize(0); in Verify() local
2037 (state_size != n_batch * n_cell) || in Verify()
2040 (recurrent_to_output_weights.getDimSize(0) != n_cell) || in Verify()
2054 forget_layer_norm_coefficients.getDimSize(0) != n_cell) in Verify()