Searched refs:execution (Results 1 - 18 of 18) sorted by relevance

/frameworks/ml/nn/runtime/
H A DCompilationBuilder.cpp100 int CompilationBuilder::createExecution(ExecutionBuilder **execution) { argument
103 *execution = nullptr;
106 *execution = new (std::nothrow) ExecutionBuilder(this);
107 return (*execution ? ANEURALNETWORKS_NO_ERROR : ANEURALNETWORKS_OUT_OF_MEMORY);
H A DNeuralNetworks.cpp409 ANeuralNetworksExecution** execution) {
410 if (!compilation || !execution) {
418 *execution = reinterpret_cast<ANeuralNetworksExecution*>(r);
422 void ANeuralNetworksExecution_free(ANeuralNetworksExecution* execution) { argument
423 // TODO specification says that an execution-in-flight can be deleted
425 ExecutionBuilder* r = reinterpret_cast<ExecutionBuilder*>(execution);
429 int ANeuralNetworksExecution_setInput(ANeuralNetworksExecution* execution, int32_t index, argument
432 if (!execution || (!buffer && length != 0)) {
436 ExecutionBuilder* r = reinterpret_cast<ExecutionBuilder*>(execution);
440 int ANeuralNetworksExecution_setInputFromMemory(ANeuralNetworksExecution* execution, int32_ argument
408 ANeuralNetworksExecution_create(ANeuralNetworksCompilation* compilation, ANeuralNetworksExecution** execution) argument
454 ANeuralNetworksExecution_setOutput(ANeuralNetworksExecution* execution, int32_t index, const ANeuralNetworksOperandType* type, void* buffer, size_t length) argument
465 ANeuralNetworksExecution_setOutputFromMemory(ANeuralNetworksExecution* execution, int32_t index, const ANeuralNetworksOperandType* type, const ANeuralNetworksMemory* memory, size_t offset, size_t length) argument
479 ANeuralNetworksExecution_startCompute(ANeuralNetworksExecution* execution, ANeuralNetworksEvent** event) argument
[all...]
H A DCompilationBuilder.h47 int createExecution(ExecutionBuilder** execution);
56 // Whether the application prefers to go fast or use low power for this execution.
/frameworks/base/core/java/android/os/
H A DTestLooperManager.java122 MessageExecution execution = new MessageExecution();
123 execution.m = message;
124 synchronized (execution) {
125 mExecuteQueue.add(execution);
128 execution.wait();
131 if (execution.response != null) {
132 throw new RuntimeException(execution.response);
/frameworks/ml/nn/runtime/test/
H A DTestValidation.cpp413 ANeuralNetworksExecution* execution = nullptr; local
414 EXPECT_EQ(ANeuralNetworksExecution_create(nullptr, &execution),
418 EXPECT_EQ(ANeuralNetworksExecution_create(mCompilation, &execution),
432 ANeuralNetworksExecution* execution; local
433 EXPECT_EQ(ANeuralNetworksExecution_create(mCompilation, &execution), ANEURALNETWORKS_NO_ERROR);
438 EXPECT_EQ(ANeuralNetworksExecution_setInput(execution, 0, nullptr, nullptr, sizeof(float)),
442 EXPECT_EQ(ANeuralNetworksExecution_setInput(execution, 0, nullptr, buffer, 20),
446 EXPECT_EQ(ANeuralNetworksExecution_setInput(execution, 999, nullptr, buffer, sizeof(float)),
450 EXPECT_EQ(ANeuralNetworksExecution_setInput(execution, -1, nullptr, buffer, sizeof(float)),
455 ANeuralNetworksExecution* execution; local
478 ANeuralNetworksExecution* execution; local
524 ANeuralNetworksExecution* execution; local
570 ANeuralNetworksExecution* execution; local
[all...]
H A DTestTrivialModel.cpp121 Execution execution(&compilation);
122 ASSERT_EQ(execution.setInput(0, matrix1, sizeof(Matrix3x4)), Result::NO_ERROR);
123 ASSERT_EQ(execution.setInput(1, matrix2, sizeof(Matrix3x4)), Result::NO_ERROR);
124 ASSERT_EQ(execution.setOutput(0, actual, sizeof(Matrix3x4)), Result::NO_ERROR);
125 ASSERT_EQ(execution.compute(), Result::NO_ERROR);
181 Execution execution(&compilation);
182 ASSERT_EQ(execution.setInput(0, matrix1, sizeof(Matrix3x4)), Result::NO_ERROR);
183 ASSERT_EQ(execution.setInput(1, matrix2b, sizeof(Matrix4)), Result::NO_ERROR);
184 ASSERT_EQ(execution.setOutput(0, actual, sizeof(Matrix3x4)), Result::NO_ERROR);
185 ASSERT_EQ(execution
[all...]
H A DTestGenerated.cpp94 Execution execution(&compilation);
97 for_all(inputs, [&execution](int idx, const void* p, size_t s) {
99 ASSERT_EQ(Result::NO_ERROR, execution.setInput(idx, buffer, s));
105 for_all(test, [&execution](int idx, void* p, size_t s) {
107 ASSERT_EQ(Result::NO_ERROR, execution.setOutput(idx, buffer, s));
110 Result r = execution.compute();
H A DTestExecution.cpp52 // Wraps an IPreparedModel to allow dummying up the execution status.
56 // the actual execution status). Otherwise, don't bother to execute, and
57 // just send back errorStatus (as the execution status, not the launch
79 // Allow dummying up the error status for execution of all models
81 // execute behaves normally (and sends back the actual execution
83 // back errorStatus (as the execution status, not the launch
149 // TestDriver reports an execution failure, we'll re-execute
156 // normally (and sends back the actual execution status).
158 // errorStatus (as the execution status, not the launch status).
186 // Allow dummying up the error status for execution
200 setInputOutput(WrapperExecution* execution) argument
[all...]
H A DTestUnknownDimensions.cpp40 // (addOperand) time to INTENDED_SIZE, use same size at execution
44 // (addOperand) time to INTENDED_SIZE, give no size at execution time.
126 // Dimensions for intermediate operand actually deduced at execution time
168 Execution execution(&compilation);
210 ASSERT_EQ(execution.setInput(0, ones, sizeAtSet(paramsForInput0), typeAtSet(paramsForInput0)),
212 ASSERT_EQ(execution.setInput(1, twos, sizeAtSet(paramsForInput1), typeAtSet(paramsForInput1)),
214 ASSERT_EQ(execution.setOutput(0, actual, sizeAtSet(paramsForOutput),
219 ASSERT_EQ(execution.compute(), Result::NO_ERROR);
223 ASSERT_NE(execution.compute(), Result::NO_ERROR);
H A DTestMemoryInternal.cpp270 WrapperExecution execution(&compilation);
274 ASSERT_EQ(WrapperResult::NO_ERROR, execution.setInput(0, input, sizeof(input)));
276 ASSERT_EQ(WrapperResult::NO_ERROR, execution.setOutput(0, output, sizeof(output)));
279 WrapperResult r = execution.compute();
/frameworks/ml/nn/runtime/include/
H A DNeuralNetworks.h1812 * an execution. See {@link ANeuralNetworksExecution_setInputFromMemory}
1839 * This includes any compilation or execution object created using the model.</p>
1871 * This includes any execution object created using the compilation.</p>
1880 * <li>Create a new execution instance by calling the
1889 * <li>Wait for the execution to complete with {@link
1891 * <li>Destroy the execution with
1894 * <p>An execution cannot be modified once {@link ANeuralNetworksExecution_startCompute}
1897 * <p>An execution can be applied to a model with
1902 * modifies an execution at a given time. It is however safe for more than one
1970 * that will be signaled once an execution complete
[all...]
/frameworks/ml/nn/common/operations/
H A DLSHProjectionTest.cpp106 Execution execution(&compilation);
109 ASSERT_EQ(execution.setInput(LSHProjection::k##X##Tensor, X##_.data(), \
118 ASSERT_EQ(execution.setOutput(LSHProjection::k##X##Tensor, X##_.data(), \
127 execution.setInput(LSHProjection::kTypeParam, &type_, sizeof(type_)),
130 ASSERT_EQ(execution.compute(), Result::NO_ERROR);
H A DEmbeddingLookupTest.cpp96 Execution execution(&compilation);
99 ASSERT_EQ(execution.setInput(EmbeddingLookup::k##X##Tensor, X##_.data(), \
108 ASSERT_EQ(execution.setOutput(EmbeddingLookup::k##X##Tensor, X##_.data(), \
116 ASSERT_EQ(execution.compute(), Result::NO_ERROR);
H A DLSTMTest.cpp193 Execution execution(&compilation);
195 ASSERT_EQ(execution.setInput(LSTMCell::k##X##Tensor, X##_.data(), \
204 ASSERT_EQ(execution.setOutput(LSTMCell::k##X##Tensor, X##_.data(), \
213 execution.setInput(LSTMCell::kInputToInputWeightsTensor, nullptr, 0);
214 execution.setInput(LSTMCell::kRecurrentToInputWeightsTensor, nullptr, 0);
219 execution.setInput(LSTMCell::kCellToInputWeightsTensor, nullptr, 0);
222 execution.setInput(LSTMCell::kCellToInputWeightsTensor, nullptr, 0);
223 execution.setInput(LSTMCell::kCellToForgetWeightsTensor, nullptr, 0);
224 execution.setInput(LSTMCell::kCellToOutputWeightsTensor, nullptr, 0);
229 execution
[all...]
H A DRNNTest.cpp222 Execution execution(&compilation);
224 ASSERT_EQ(execution.setInput(RNN::k##X##Tensor, X##_.data(), \
233 ASSERT_EQ(execution.setOutput(RNN::k##X##Tensor, X##_.data(), \
241 ASSERT_EQ(execution.setInput(RNN::kActivationParam, &activation_,
245 ASSERT_EQ(execution.compute(), Result::NO_ERROR);
H A DSVDFTest.cpp259 Execution execution(&compilation);
264 ASSERT_EQ(execution.setInput(SVDF::k##X##Tensor, X##_.data(), \
274 ASSERT_EQ(execution.setOutput(SVDF::k##X##Tensor, X##_.data(), \
282 ASSERT_EQ(execution.setInput(SVDF::kRankParam, &rank_, sizeof(rank_)),
286 ASSERT_EQ(execution.setInput(SVDF::kActivationParam, &activation,
290 ASSERT_EQ(execution.compute(), Result::NO_ERROR);
H A DHashtableLookupTest.cpp110 Execution execution(&compilation);
113 ASSERT_EQ(execution.setInput(HashtableLookup::k##X##Tensor, X##_.data(), \
122 ASSERT_EQ(execution.setOutput(HashtableLookup::k##X##Tensor, X##_.data(), \
130 ASSERT_EQ(execution.compute(), Result::NO_ERROR);
/frameworks/rs/script_api/
H A Drs_atomic.spec29 runtime will very often split the execution of one kernel across multiple

Completed in 151 milliseconds