1 /*
2  * Copyright (c) 2021 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 /**
17  * @addtogroup ic_sdk
18  * @{
19  *
20  * @brief Defines the development tool functions, constants and error codes for image classification (IC).
21  *
22  * @since 2.2
23  * @version 1.0
24  */
25 
26 /**
27  * @file ic_constants.h
28  *
29  * @brief Defines the constants and, input and output formats for calling the image classification plugin.
30  *
31  * @since 2.2
32  * @version 1.0
33  */
34 
35 #ifndef IC_CONSTANTS_H
36 #define IC_CONSTANTS_H
37 
38 #include <cstddef>
39 #include <cstdint>
40 #include <vector>
41 
42 #include "ai_datatype.h"
43 
44 namespace OHOS {
45 namespace AI {
46 /**
47  * @brief Defines the version number of the image classification client.
48  *
49  * @since 2.2
50  * @version 1.0
51  */
52 const long long CLIENT_VERSION_IC = 20001003;
53 
54 /**
55  * @brief Defines the version number of the image classification algorithm.
56  *
57  * @since 2.2
58  * @version 1.0
59  */
60 const long long ALGOTYPE_VERSION_IC = 20001001;
61 
62 /**
63  * @brief Defines the value of invalid handles.
64  *
65  * @since 2.2
66  * @version 1.0
67  */
68 const intptr_t INVALID_IC_HANDLE = -1;
69 
70 /**
71  * @brief Defines the input format for image classification.
72  *
73  * @since 2.2
74  * @version 1.0
75  */
76 using IcInput = Array<uint8_t>;
77 
78 /**
79  * @brief Defines the output format for image classification.
80  *
81  * @since 2.2
82  * @version 1.0
83  */
84 using IcOutput = Array<int32_t>;
85 } // namespace AI
86 } // namespace OHOS
87 
88 #endif // IC_CONSTANTS_H
89 /** @} */