31constexpr uint32_t inputTensorIdx = 0;
45 if (
args.is_last_layer)
50 uint16_t op_index =
args.kernel_index;
53 runtime_kernel.
readKernel(op_index, runtime_context);
55 const circle::Tensor *
input = runtime_kernel.
inputs[inputTensorIdx];
58 assert(input !=
nullptr);
59 assert(output !=
nullptr);
72 status = runtime_kernel.
getDataFromStorage(op_index, runtime_storage, runtime_context);
79 assert(input_data !=
nullptr);
80 assert(output_data !=
nullptr);
83 if (input_data == output_data)
86 const size_t element_size =
89 std::memcpy(input_data, output_data, num_elements * element_size);
uint8_t * outputs_data[maxOutputSize]
OMStatus getDataFromStorage(uint16_t op_index, core::OMRuntimeStorage &storage, core::OMRuntimeContext &context)
uint8_t * inputs_data[maxInputSize]
OMStatus readKernel(uint16_t op_index, core::OMRuntimeContext &runtime_context)
const circle::Tensor * outputs[maxOutputSize]
const circle::Tensor * inputs[maxInputSize]
const luci_interpreter::RuntimeShape output_shape
constexpr uint32_t outputTensorIdx
uint32_t num_elements(const Shape &shape)
The number of elements of a feature map of a given shape.
OMDataType onertMicroDatatype(const circle::TensorType type)
size_t getOMDataTypeSize(OMDataType data_type)