OpenVINO 2022.1 introduces a new version of OpenVINO API (API 2.0). For more information on the changes and transition steps, see the transition guide
SharedBuffer class to store pointer to pre-acclocated buffer.
#include <shared_buffer.hpp> template <typename T> class SharedBuffer: public ngraph::runtime::AlignedBuffer { public: // construction SharedBuffer(char \* data, size_t size, const T& shared_object); };
public: // methods AlignedBuffer& operator = (AlignedBuffer&& other); size_t size() const; void \* get_ptr(size_t offset) const; void \* get_ptr(); const void \* get_ptr() const; template <typename T> T \* get_ptr(); template <typename T> const T \* get_ptr() const; template <typename T> operator T\* ();