1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
/*
* Copyright (C) 2019 Intel Corporation. All rights reserved.
* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
*/
#ifndef WASI_NN_TENSORFLOWLITE_HPP
#define WASI_NN_TENSORFLOWLITE_HPP
#include "wasi_nn.h"
#ifdef __cplusplus
extern "C" {
#endif
error
tensorflowlite_load(void *tflite_ctx, graph_builder_array *builder,
graph_encoding encoding, execution_target target, graph *g);
error
tensorflowlite_init_execution_context(void *tflite_ctx, graph g,
graph_execution_context *ctx);
error
tensorflowlite_set_input(void *tflite_ctx, graph_execution_context ctx,
uint32_t index, tensor *input_tensor);
error
tensorflowlite_compute(void *tflite_ctx, graph_execution_context ctx);
error
tensorflowlite_get_output(void *tflite_ctx, graph_execution_context ctx,
uint32_t index, tensor_data output_tensor,
uint32_t *output_tensor_size);
void
tensorflowlite_initialize(void **tflite_ctx);
void
tensorflowlite_destroy(void *tflite_ctx);
#ifdef __cplusplus
}
#endif
#endif
|