• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /**
2  * Copyright 2023 Huawei Technologies Co., Ltd
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #ifndef NNACL_TENSORLIST_C_H_
18 #define NNACL_TENSORLIST_C_H_
19 
20 #include "nnacl/tensor_c.h"
21 
22 typedef struct vvector {
23   int **shape_;      // value of shapes
24   int *shape_size_;  // size of shape
25   size_t size_;      // number of shapes
26 } vvector;
27 
28 typedef struct TensorListC {
29   bool shape_changed_;
30   int data_type_;
31   int format_;
32   int shape_value_;
33   int tensors_data_type_;  // element_data_type_, keep same as c++
34   int max_elements_num_;
35   TensorC **tensors_;
36   size_t element_num_;
37   size_t element_shape_size_;
38   int element_shape_[MAX_SHAPE_SIZE];
39 } TensorListC;
40 
41 #endif  // NNACL_TENSORLIST_C_H_
42