Closed abrown closed 3 weeks ago
hey, will these bindings support API 2.0 in future, are there any plans?
I think so, but it's dependent on a couple of things, mainly getting time to do this. Are you interested in helping out with that?
hey, thanks for the quick reply, i really am not very knowledgeable in this area, i needed to inference dynamic model with rust and openvino. so wanted to know the status.
I've been informed that the legacy OpenVINO C API will be going away at the end of 2023. This means that switching to OpenVINO's 2.0 API will be necessary to continue binding to future versions of OpenVINO. To help out with this task, here are some steps I might follow:
libopenvino_c.so
and list the new ov_*
symbols: nm <path> --dynamic --demangle | grep ov_
crates/openvino-sys/upstream
) to a more recent version (i.e., the most recent release tag)src/bindings/c
codegen
task (crates/xtask/src/codegen.rs
) to generate new Rust FFI shims to call these functions; then generate the new code with cargo xtask codegen
openvino
crate, mechanically changing as many openvino_sys::ie_*
imports to their openvino_sys::ov_*
equivalent; unfortunately, some of these changes cannot be mechanical and we will have to tweak certain functions (e.g., inputs and outputs are referenced by name) according to the transition guideAt this point, it should be possible to run all of the tests and ensure the bindings to the new API still work. At this point we would create a new release, etc.
OpenVINO has a new API for accessing its functionality: API 2.0. The C API that these bindings rely on will soon be considered a legacy API. It would be worthwhile to consider switching the implementation to use the C API of API 2.0. A description of how to use some of the top-level structures can be found here.