/home/docs/checkouts/readthedocs.org/user_builds/advanced-micro-devices-roccv/checkouts/latest/include/core/util_enums.h Source File

/home/docs/checkouts/readthedocs.org/user_builds/advanced-micro-devices-roccv/checkouts/latest/include/core/util_enums.h Source File#

3 min read time

Applies to Linux

rocCV: /home/docs/checkouts/readthedocs.org/user_builds/advanced-micro-devices-roccv/checkouts/latest/include/core/util_enums.h Source File
util_enums.h
Go to the documentation of this file.
1 
22 #pragma once
23 
24 /* Supported Data Types for use with utilities such as Tensor inputs. */
25 typedef enum eDataType {
26  DATA_TYPE_U8 = 0, /* 8 bit unsigned integer. */
27  DATA_TYPE_S8, /* 8 bit signed integer. */
28  DATA_TYPE_U16, /* 16 bit unsigned integer. */
29  DATA_TYPE_S16, /* 16 bit signed integer. */
30  DATA_TYPE_U32, /* 32 bit unsigned integer. */
31  DATA_TYPE_S32, /* 32 bit signed integer. */
32  DATA_TYPE_F32, /* 32 bit single precision float */
33  DATA_TYPE_F64, /* 64 bit double precision float */
34  DATA_TYPE_4S16, /* 4-channel 16-bit signed integer*/
35 } eDataType;
36 
37 /* Supported Tensor Layout Types. */
38 typedef enum eTensorLayout {
39  TENSOR_LAYOUT_NHWC, /* Number of Samples, Height, Width, Channels. */
40  TENSOR_LAYOUT_HWC, /* Height, Width, Channels. */
41  TENSOR_LAYOUT_NC, /* Number of Samples, Channels */
42  TENSOR_LAYOUT_NW, /* Number of Samples, Width */
43  TENSOR_LAYOUT_N, /* Number of Samples */
44  TENSOR_LAYOUT_NMC, /* (SIFT) Number of Samples, maximum number of features,
45  number of feature coordinates/metadata */
46  TENSOR_LAYOUT_NMD, /* (SIFT) Number of Samples, maximum number of features,
47  Depth of each feature descriptor*/
48  TENSOR_LAYOUT_LNHWC, /* (SIFT) Octave layer, Number of samples, Height,
49  Width, Channels */
50  TENSOR_LAYOUT_NCHW, /* Number of Samples, Channels, Height, Width */
51  TENSOR_LAYOUT_NWC, /* Number of Samples, Width, Channels */
53 
54 typedef enum eChannelType {
55  F_RGB = 1,
56  BGR = 2,
57  YUV = 4, /*Treated as NV12 for Semi-Planar images*/
58  YVU = 8, /*Treated as NV21 for Semi-Planar images*/
59  Grayscale = 16,
60 
61 } eChannelType;
62 
69 enum class eDeviceType { GPU = 0, CPU = 1 };
70 
75 enum class eOwnership { OWNING = 0, VIEW = 1 };
eOwnership
Describes whether a container should own a resource or only be a view for a resource.
Definition: util_enums.h:75
eDeviceType
Describes the device type. Used to determine where Tensor data should be allocated and whether operat...
Definition: util_enums.h:69
eTensorLayout
Definition: util_enums.h:38
@ TENSOR_LAYOUT_NW
Definition: util_enums.h:42
@ TENSOR_LAYOUT_N
Definition: util_enums.h:43
@ TENSOR_LAYOUT_NWC
Definition: util_enums.h:51
@ TENSOR_LAYOUT_NMC
Definition: util_enums.h:44
@ TENSOR_LAYOUT_HWC
Definition: util_enums.h:40
@ TENSOR_LAYOUT_NC
Definition: util_enums.h:41
@ TENSOR_LAYOUT_LNHWC
Definition: util_enums.h:48
@ TENSOR_LAYOUT_NCHW
Definition: util_enums.h:50
@ TENSOR_LAYOUT_NMD
Definition: util_enums.h:46
@ TENSOR_LAYOUT_NHWC
Definition: util_enums.h:39
eDataType
Definition: util_enums.h:25
@ DATA_TYPE_S8
Definition: util_enums.h:27
@ DATA_TYPE_U32
Definition: util_enums.h:30
@ DATA_TYPE_4S16
Definition: util_enums.h:34
@ DATA_TYPE_F32
Definition: util_enums.h:32
@ DATA_TYPE_U16
Definition: util_enums.h:28
@ DATA_TYPE_F64
Definition: util_enums.h:33
@ DATA_TYPE_U8
Definition: util_enums.h:26
@ DATA_TYPE_S16
Definition: util_enums.h:29
@ DATA_TYPE_S32
Definition: util_enums.h:31
eChannelType
Definition: util_enums.h:54
@ BGR
Definition: util_enums.h:56
@ YVU
Definition: util_enums.h:58
@ F_RGB
Definition: util_enums.h:55
@ Grayscale
Definition: util_enums.h:59
@ YUV
Definition: util_enums.h:57