Expand description
The openvino crate provides high-level, ergonomic, safe Rust bindings to OpenVINO. See the repository README for more information, such as build instructions.
Check the loaded version of OpenVINO:
assert!(openvino::version().build_number.starts_with("2"))
Most interaction with OpenVINO begins with instantiating a Core:
let _ = openvino::Core::new().expect("to instantiate the OpenVINO library");
Modules§
- See
PrePostProcess
.
Macros§
- Convert a Rust string into a string to pass across the C boundary.
- Drop one of the Rust wrapper structures using the provided free function. This relies on all Rust wrapper functions having a
ptr
field pointing to their OpenVINO C structure. - Convert an unsafe call to openvino-sys into an
InferenceError
.
Structs§
- See
CompiledModel
. - See
Core
. - See
Dimension
. - See
InferRequest
. - See
Layout
. - See
Model
. - See
Node
. - See
PartialShape
. - See
Rank
. - See
Shape
. - See
Tensor
. - Represents OpenVINO version information.
Enums§
DeviceType
represents accelerator devices.ElementType
represents the type of elements that a tensor can hold. SeeElementType
.- Enumerate errors returned by the OpenVINO implementation. See
OvStatusCode
. - Enumerate the ways that library loading can fail.
- Interpolation mode when resizing during preprocess steps.
- Read-write property keys.
- Enumerate setup failures: in some cases, this library will call library-loading code that may fail in a different way (i.e.,
LoadingError
) than the calls to the OpenVINO libraries (i.e.,InferenceError
).
Functions§
- Emit the version string of the OpenVINO C API backing this implementation.