/frameworks/ml/nn/common/operations/ |
D | BidirectionalSequenceLSTM.cpp | 82 RunTimeOperandInfo* operands) { in BidirectionalSequenceLSTM() argument 83 input_ = GetInput(operation, operands, kInputTensor); in BidirectionalSequenceLSTM() 86 GetInput(operation, operands, kFwInputToInputWeightsTensor); // optional in BidirectionalSequenceLSTM() 87 fw_input_to_forget_weights_ = GetInput(operation, operands, kFwInputToForgetWeightsTensor); in BidirectionalSequenceLSTM() 88 fw_input_to_cell_weights_ = GetInput(operation, operands, kFwInputToCellWeightsTensor); in BidirectionalSequenceLSTM() 89 fw_input_to_output_weights_ = GetInput(operation, operands, kFwInputToOutputWeightsTensor); in BidirectionalSequenceLSTM() 92 GetInput(operation, operands, kFwRecurrentToInputWeightsTensor); // optional in BidirectionalSequenceLSTM() 94 GetInput(operation, operands, kFwRecurrentToForgetWeightsTensor); in BidirectionalSequenceLSTM() 95 fw_recurrent_to_cell_weights_ = GetInput(operation, operands, kFwRecurrentToCellWeightsTensor); in BidirectionalSequenceLSTM() 97 GetInput(operation, operands, kFwRecurrentToOutputWeightsTensor); in BidirectionalSequenceLSTM() [all …]
|
D | QuantizedLSTM.cpp | 223 QuantizedLSTMCell::QuantizedLSTMCell(const Operation& operation, RunTimeOperandInfo* operands) { in QuantizedLSTMCell() argument 224 input_ = GetInput(operation, operands, kInputTensor); in QuantizedLSTMCell() 226 inputToInputWeights_ = GetInput(operation, operands, kInputToInputWeightsTensor); in QuantizedLSTMCell() 227 inputToForgetWeights_ = GetInput(operation, operands, kInputToForgetWeightsTensor); in QuantizedLSTMCell() 228 inputToCellWeights_ = GetInput(operation, operands, kInputToCellWeightsTensor); in QuantizedLSTMCell() 229 inputToOutputWeights_ = GetInput(operation, operands, kInputToOutputWeightsTensor); in QuantizedLSTMCell() 231 recurrentToInputWeights_ = GetInput(operation, operands, kRecurrentToInputWeightsTensor); in QuantizedLSTMCell() 232 recurrentToForgetWeights_ = GetInput(operation, operands, kRecurrentToForgetWeightsTensor); in QuantizedLSTMCell() 233 recurrentToCellWeights_ = GetInput(operation, operands, kRecurrentToCellWeightsTensor); in QuantizedLSTMCell() 234 recurrentToOutputWeights_ = GetInput(operation, operands, kRecurrentToOutputWeightsTensor); in QuantizedLSTMCell() [all …]
|
D | SVDF.cpp | 33 SVDF::SVDF(const Operation& operation, RunTimeOperandInfo* operands) { in SVDF() argument 35 input_ = GetInput(operation, operands, kInputTensor); in SVDF() 36 weights_feature_ = GetInput(operation, operands, kWeightsFeatureTensor); in SVDF() 37 weights_time_ = GetInput(operation, operands, kWeightsTimeTensor); in SVDF() 38 bias_ = GetInput(operation, operands, kBiasTensor); in SVDF() 39 state_in_ = GetInput(operation, operands, kStateInTensor); in SVDF() 41 const auto& rankOperand = *GetInput(operation, operands, kRankParam); in SVDF() 43 const auto& activationOperand = *GetInput(operation, operands, kActivationParam); in SVDF() 47 state_out_ = GetOutput(operation, operands, kStateOutTensor); in SVDF() 48 output_ = GetOutput(operation, operands, kOutputTensor); in SVDF() [all …]
|
D | LSHProjection.cpp | 34 LSHProjection::LSHProjection(const Operation& operation, RunTimeOperandInfo* operands) { in LSHProjection() argument 35 input_ = GetInput(operation, operands, kInputTensor); in LSHProjection() 36 weight_ = GetInput(operation, operands, kWeightTensor); in LSHProjection() 37 hash_ = GetInput(operation, operands, kHashTensor); in LSHProjection() 40 getScalarData<int32_t>(*GetInput(operation, operands, kTypeParam))); in LSHProjection() 42 output_ = GetOutput(operation, operands, kOutputTensor); in LSHProjection() 45 bool LSHProjection::Prepare(const Operation& operation, RunTimeOperandInfo* operands, in Prepare() argument 50 NN_RET_CHECK(!IsNullInput(GetInput(operation, operands, requiredInput))) in Prepare() 55 const RunTimeOperandInfo* hash = GetInput(operation, operands, kHashTensor); in Prepare() 60 const RunTimeOperandInfo* input = GetInput(operation, operands, kInputTensor); in Prepare() [all …]
|
D | RNN.cpp | 34 RNN::RNN(const Operation& operation, RunTimeOperandInfo* operands) { in RNN() argument 36 input_ = GetInput(operation, operands, kInputTensor); in RNN() 37 weights_ = GetInput(operation, operands, kWeightsTensor); in RNN() 38 recurrent_weights_ = GetInput(operation, operands, kRecurrentWeightsTensor); in RNN() 39 hidden_state_in_ = GetInput(operation, operands, kHiddenStateInTensor); in RNN() 40 bias_ = GetInput(operation, operands, kBiasTensor); in RNN() 43 getScalarData<int32_t>(operands[operation.inputs[kActivationParam]])); in RNN() 45 hidden_state_out_ = GetOutput(operation, operands, kHiddenStateOutTensor); in RNN() 46 output_ = GetOutput(operation, operands, kOutputTensor); in RNN() 49 bool RNN::Prepare(const Operation& operation, RunTimeOperandInfo* operands, Shape* hiddenStateShape, in Prepare() argument [all …]
|
D | Multinomial.cpp | 54 Multinomial::Multinomial(const Operation& operation, RunTimeOperandInfo* operands) { in Multinomial() argument 56 input_ = GetInput(operation, operands, kInputTensor); in Multinomial() 57 sample_count_ = getScalarData<int>(*GetInput(operation, operands, kSampleCountParam)); in Multinomial() 58 random_seeds_ = GetInput(operation, operands, kRandomSeedsTensor); in Multinomial() 60 output_ = GetOutput(operation, operands, kOutputTensor); in Multinomial() 63 bool Multinomial::Prepare(const Operation& operation, RunTimeOperandInfo* operands, in Prepare() argument 66 NN_CHECK_EQ(NumInputsWithValues(operation, operands), 3); in Prepare() 69 const RunTimeOperandInfo* input = GetInput(operation, operands, Multinomial::kInputTensor); in Prepare() 74 getScalarData<int>(*GetInput(operation, operands, kSampleCountParam)); in Prepare()
|
D | HashtableLookup.cpp | 40 HashtableLookup::HashtableLookup(const Operation& operation, RunTimeOperandInfo* operands) { in HashtableLookup() argument 41 lookup_ = GetInput(operation, operands, kLookupTensor); in HashtableLookup() 42 key_ = GetInput(operation, operands, kKeyTensor); in HashtableLookup() 43 value_ = GetInput(operation, operands, kValueTensor); in HashtableLookup() 45 output_ = GetOutput(operation, operands, kOutputTensor); in HashtableLookup() 46 hits_ = GetOutput(operation, operands, kHitsTensor); in HashtableLookup()
|
D | LSTM.cpp | 54 LSTMCell::LSTMCell(const Operation& operation, RunTimeOperandInfo* operands) { in LSTMCell() argument 55 input_ = GetInput(operation, operands, kInputTensor); in LSTMCell() 58 GetInput(operation, operands, kInputToInputWeightsTensor); // optional in LSTMCell() 59 input_to_forget_weights_ = GetInput(operation, operands, kInputToForgetWeightsTensor); in LSTMCell() 60 input_to_cell_weights_ = GetInput(operation, operands, kInputToCellWeightsTensor); in LSTMCell() 61 input_to_output_weights_ = GetInput(operation, operands, kInputToOutputWeightsTensor); in LSTMCell() 64 GetInput(operation, operands, kRecurrentToInputWeightsTensor); // optional in LSTMCell() 65 recurrent_to_forget_weights_ = GetInput(operation, operands, kRecurrentToForgetWeightsTensor); in LSTMCell() 66 recurrent_to_cell_weights_ = GetInput(operation, operands, kRecurrentToCellWeightsTensor); in LSTMCell() 67 recurrent_to_output_weights_ = GetInput(operation, operands, kRecurrentToOutputWeightsTensor); in LSTMCell() [all …]
|
D | EmbeddingLookup.cpp | 32 EmbeddingLookup::EmbeddingLookup(const Operation& operation, RunTimeOperandInfo* operands) { in EmbeddingLookup() argument 33 value_ = GetInput(operation, operands, kValueTensor); in EmbeddingLookup() 34 lookup_ = GetInput(operation, operands, kLookupTensor); in EmbeddingLookup() 36 output_ = GetOutput(operation, operands, kOutputTensor); in EmbeddingLookup()
|
/frameworks/ml/nn/common/ |
D | CpuExecutor.cpp | 55 OperationExecutionContext(const Operation* operation, RunTimeOperandInfo* operands) in OperationExecutionContext() argument 56 : operation(operation), operands(operands) {} in OperationExecutionContext() 88 RunTimeOperandInfo* operands; member in android::nn::__anonec8350e20111::OperationExecutionContext 95 return &operands[operation->inputs[index]]; in getInputInfo() 100 return &operands[operation->outputs[index]]; in getOutputInfo() 105 return &operands[operation->outputs[index]]; in getOutputInfo() 610 RunTimeOperandInfo* operands) { in consumeOperationInputs() argument 612 auto& info = operands[i]; in consumeOperationInputs() 628 static void freeUnusedSubgraphOperands(std::vector<RunTimeOperandInfo>* operands) { in freeUnusedSubgraphOperands() argument 629 for (auto& info : *operands) { in freeUnusedSubgraphOperands() [all …]
|
D | ValidateHal.cpp | 168 static bool validateOperands(const hidl_vec<VersionedOperand>& operands, in validateOperands() argument 174 for (auto& versionedOperand : operands) { in validateOperands() 450 const hidl_vec<Operand>& operands, in validateOperations() argument 472 CHECK_LT(subgraph.inputIndexes[index], subgraph.operands.size()); in validateOperations() 473 return &subgraph.operands[subgraph.inputIndexes[index]]; in validateOperations() 478 CHECK_LT(subgraph.outputIndexes[index], subgraph.operands.size()); in validateOperations() 479 return &subgraph.operands[subgraph.outputIndexes[index]]; in validateOperations() 487 op.outputs.size() > 0 ? op.outputs.data() : nullptr, operands, getHalVersion(op), in validateOperations() 506 const Operand& operand = operands[i]; in validateOperations() 551 const hidl_vec<Operand>& operands, OperandLifeTime lifetime) { in validateModelInputOutputs() argument [all …]
|
D | Utils.cpp | 198 const uint32_t* outputIndexes, const Operand* operands, in OperationValidationContext() argument 205 operands(operands), in OperationValidationContext() 229 const Operand* operands; member in android::nn::__anon8d54713c0111::OperationValidationContext 243 return &operands[inputIndexes[index]]; in getInputOperand() 248 return &operands[outputIndexes[index]]; in getOutputOperand() 444 LOG(INFO) << "operands" << toString(model.operands); in logModelToInfo() 454 LOG(INFO) << "operands" << toString(model.operands); in logModelToInfo() 464 LOG(INFO) << "operands" << toString(model.operands); in logModelToInfo() 475 LOG(INFO) << label << ".operands" << toString(subgraph.operands); in logSubgraphToInfo() 652 int validateOperationOperandTypes(const std::vector<Operand>& operands, uint32_t inOperandCount, in validateOperationOperandTypes() argument [all …]
|
/frameworks/ml/nn/common/include/ |
D | CpuExecutor.h | 169 RunTimeOperandInfo* operands); 171 int executeSubgraph(const hal::Subgraph& subgraph, RunTimeOperandInfo* operands); 173 int executeOperation(const hal::Operation& operation, RunTimeOperandInfo* operands); 174 int executeIfOperation(const hal::Operation& operation, RunTimeOperandInfo* operands); 175 int executeWhileOperation(const hal::Operation& operation, RunTimeOperandInfo* operands); 178 const std::vector<RunTimeOperandInfo>& operands); 266 const RunTimeOperandInfo* operands) { in NumInputsWithValues() argument 269 [&operands](uint32_t i) { return !IsNullInput(&operands[i]); }); in NumInputsWithValues() 284 inline RunTimeOperandInfo* GetInput(const hal::Operation& operation, RunTimeOperandInfo* operands, in GetInput() argument 286 return &operands[operation.inputs[index]]; in GetInput() [all …]
|
/frameworks/ml/nn/runtime/test/android_fuzzing/ |
D | Converter.cpp | 100 std::vector<TestOperand> convert(const Operands& operands) { in convert() argument 102 testOperands.reserve(operands.operand_size()); in convert() 103 const auto& repeatedOperand = operands.operand(); in convert() 132 std::vector<TestOperand>* operands) { in calculateNumberOfConsumers() argument 133 CHECK(operands != nullptr); in calculateNumberOfConsumers() 134 const auto addConsumer = [operands](uint32_t operand) { in calculateNumberOfConsumers() 135 if (operand < operands->size()) { in calculateNumberOfConsumers() 136 operands->at(operand).numberOfConsumers++; in calculateNumberOfConsumers() 146 std::vector<TestOperand> operands = convert(model.operands()); in convert() local 153 calculateNumberOfConsumers(operations, &operands); in convert() [all …]
|
/frameworks/ml/nn/runtime/test/specs/V1_2/ |
D | cast.mod.py | 23 operands = [ variable 50 for operand1, operand2 in itertools.product(operands, operands): 66 operands = [ variable 87 for operand1 in operands:
|
/frameworks/ml/nn/runtime/test/generated/spec_V1_3/ |
D | hard_swish.example.cpp | 16 .operands = {{ // input0 in get_test_model_simple() 63 .operands = {{ // input0 in get_test_model_simple_all_inputs_as_internal() 144 .operands = {{ // input0 in get_test_model_simple_float16() 191 .operands = {{ // input0 in get_test_model_simple_float16_all_inputs_as_internal() 272 .operands = {{ // input0 in get_test_model_simple_relaxed() 319 .operands = {{ // input0 in get_test_model_simple_relaxed_all_inputs_as_internal() 400 .operands = {{ // input0 in get_test_model_simple_quant8() 447 .operands = {{ // input0 in get_test_model_simple_quant8_all_inputs_as_internal() 528 .operands = {{ // input0 in get_test_model_simple_quant8_signed() 575 .operands = {{ // input0 in get_test_model_simple_quant8_signed_all_inputs_as_internal() [all …]
|
D | if_simple.example.cpp | 16 .operands = {{ // x in get_test_model_true() 77 .operands = {{ // y1 in get_test_model_true() 126 .operands = {{ // y2 in get_test_model_true() 191 .operands = {{ // x in get_test_model_true_all_inputs_as_internal() 286 .operands = {{ // y1 in get_test_model_true_all_inputs_as_internal() 335 .operands = {{ // y2 in get_test_model_true_all_inputs_as_internal() 400 .operands = {{ // x in get_test_model_true_all_outputs_as_internal() 495 .operands = {{ // y1 in get_test_model_true_all_outputs_as_internal() 544 .operands = {{ // y2 in get_test_model_true_all_outputs_as_internal() 609 .operands = {{ // x in get_test_model_true_relaxed() [all …]
|
D | if_constant.example.cpp | 16 .operands = {{ // cond in get_test_model_copy_true() 87 .operands = {{ // x1 in get_test_model_copy_true() 136 .operands = {{ // x2 in get_test_model_copy_true() 201 .operands = {{ // cond in get_test_model_copy_true_relaxed() 272 .operands = {{ // x1 in get_test_model_copy_true_relaxed() 321 .operands = {{ // x2 in get_test_model_copy_true_relaxed() 386 .operands = {{ // cond in get_test_model_copy_true_float16() 457 .operands = {{ // x1 in get_test_model_copy_true_float16() 506 .operands = {{ // x2 in get_test_model_copy_true_float16() 571 .operands = {{ // cond in get_test_model_copy_true_int32() [all …]
|
D | cast_identity.example.cpp | 16 .operands = {{ // input0 in get_test_model_float16() 63 .operands = {{ // input0 in get_test_model_float16_all_inputs_as_internal() 144 .operands = {{ // input01 in get_test_model_float32() 191 .operands = {{ // input01 in get_test_model_float32_all_inputs_as_internal() 272 .operands = {{ // input01 in get_test_model_float32_relaxed() 319 .operands = {{ // input01 in get_test_model_float32_relaxed_all_inputs_as_internal() 400 .operands = {{ // input02 in get_test_model_int32() 447 .operands = {{ // input03 in get_test_model_bool8() 494 .operands = {{ // input04 in get_test_model_quant8_asymm() 541 .operands = {{ // input04 in get_test_model_quant8_asymm_all_inputs_as_internal() [all …]
|
D | while_infinite_loop.example.cpp | 16 .operands = {{ // param2 in get_test_model() 77 .operands = {{ // i in get_test_model() 116 .operands = {{ // i1 in get_test_model() 191 .operands = {{ // param2 in get_test_model_relaxed() 252 .operands = {{ // i in get_test_model_relaxed() 291 .operands = {{ // i1 in get_test_model_relaxed() 366 .operands = {{ // param2 in get_test_model_float16() 427 .operands = {{ // i in get_test_model_float16() 466 .operands = {{ // i1 in get_test_model_float16() 541 .operands = {{ // param2 in get_test_model_quant8() [all …]
|
D | rank.example.cpp | 16 .operands = {{ // input0 in get_test_model_1d() 63 .operands = {{ // input0 in get_test_model_1d_all_inputs_as_internal() 144 .operands = {{ // input0 in get_test_model_1d_int32() 191 .operands = {{ // input0 in get_test_model_1d_float16() 238 .operands = {{ // input0 in get_test_model_1d_float16_all_inputs_as_internal() 319 .operands = {{ // input0 in get_test_model_1d_quant8() 366 .operands = {{ // input0 in get_test_model_1d_quant8_all_inputs_as_internal() 447 .operands = {{ // input0 in get_test_model_1d_quant8_signed() 494 .operands = {{ // input0 in get_test_model_1d_quant8_signed_all_inputs_as_internal() 575 .operands = {{ // input01 in get_test_model_1d_2() [all …]
|
/frameworks/ml/nn/runtime/test/generated/spec_V1_2/ |
D | cast.example.cpp | 16 .operands = {{ // input0 in get_test_model_float16_to_float16() 63 .operands = {{ // input0 in get_test_model_float16_to_float16_all_inputs_as_internal() 144 .operands = {{ // input0 in get_test_model_float16_to_float32() 191 .operands = {{ // input0 in get_test_model_float16_to_float32_all_inputs_as_internal() 272 .operands = {{ // input0 in get_test_model_float16_to_float32_relaxed() 319 .operands = {{ // input0 in get_test_model_float16_to_float32_relaxed_all_inputs_as_internal() 400 .operands = {{ // input0 in get_test_model_float16_to_int32() 447 .operands = {{ // input0 in get_test_model_float16_to_int32_all_inputs_as_internal() 528 .operands = {{ // input0 in get_test_model_float16_to_quant8() 575 .operands = {{ // input0 in get_test_model_float16_to_quant8_all_inputs_as_internal() [all …]
|
D | l2_normalization_v1_2.example.cpp | 16 .operands = {{ // op1 in get_test_model_dim4_axis3() 63 .operands = {{ // op1 in get_test_model_dim4_axis3_all_inputs_as_internal() 144 .operands = {{ // op1 in get_test_model_dim4_axis3_relaxed() 191 .operands = {{ // op1 in get_test_model_dim4_axis3_relaxed_all_inputs_as_internal() 272 .operands = {{ // op1 in get_test_model_dim4_axis3_float16() 319 .operands = {{ // op1 in get_test_model_dim4_axis3_float16_all_inputs_as_internal() 400 .operands = {{ // op1 in get_test_model_dim4_axis3_quant8() 447 .operands = {{ // op1 in get_test_model_dim4_axis3_quant8_all_inputs_as_internal() 528 .operands = {{ // op1 in get_test_model_dim3_axis2() 575 .operands = {{ // op1 in get_test_model_dim3_axis2_all_inputs_as_internal() [all …]
|
/frameworks/ml/nn/runtime/test/generated/spec_V1_3_cts_only/ |
D | if_simple_unknown_dimension.example.cpp | 16 .operands = {{ // x in get_test_model_true() 77 .operands = {{ // y1 in get_test_model_true() 126 .operands = {{ // y2 in get_test_model_true() 191 .operands = {{ // x in get_test_model_true_all_inputs_as_internal() 286 .operands = {{ // y1 in get_test_model_true_all_inputs_as_internal() 335 .operands = {{ // y2 in get_test_model_true_all_inputs_as_internal() 400 .operands = {{ // x in get_test_model_true_all_outputs_as_internal() 495 .operands = {{ // y1 in get_test_model_true_all_outputs_as_internal() 544 .operands = {{ // y2 in get_test_model_true_all_outputs_as_internal() 609 .operands = {{ // x in get_test_model_true_relaxed() [all …]
|
D | if_simple_unknown_rank.example.cpp | 16 .operands = {{ // x in get_test_model_true() 77 .operands = {{ // y1 in get_test_model_true() 126 .operands = {{ // y2 in get_test_model_true() 191 .operands = {{ // x in get_test_model_true_all_inputs_as_internal() 286 .operands = {{ // y1 in get_test_model_true_all_inputs_as_internal() 335 .operands = {{ // y2 in get_test_model_true_all_inputs_as_internal() 400 .operands = {{ // x in get_test_model_true_all_outputs_as_internal() 495 .operands = {{ // y1 in get_test_model_true_all_outputs_as_internal() 544 .operands = {{ // y2 in get_test_model_true_all_outputs_as_internal() 609 .operands = {{ // x in get_test_model_true_relaxed() [all …]
|