Class HostBuffer
Defined in File holoinfer_buffer.hpp
-
class HostBuffer
-
Public Functions
-
inline explicit HostBuffer(holoinfer_datatype data_type = holoinfer_datatype::h_Float32)
Constructor.
- Parameters
data_type – data type of the buffer
-
inline void *data()
Get the buffer data on the host.
- Returns
void pointer to the buffer
-
inline size_t size() const
Get the number of elements in the buffer.
- Returns
size
-
inline void set_type(holoinfer_datatype in_type)
Set the data type and resize the buffer.
- Parameters
in_type – input data type
-
inline void resize(size_t number_of_elements)
Resize the underlying buffer on host.
- Parameters
number_of_elements – Number of elements to be resized with
-
inline explicit HostBuffer(holoinfer_datatype data_type = holoinfer_datatype::h_Float32)