Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 0 additions & 24 deletions backends/openvino/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -53,30 +53,6 @@ target_sources(

executorch_target_link_options_shared_lib(openvino_backend)

if(EXECUTORCH_BUILD_OPENVINO_EXECUTOR_RUNNER)
# Build executor runner binary for openvino backend
list(APPEND openvino_executor_runner_libs openvino_backend executorch)

set(_openvino_executor_runner__srcs
${EXECUTORCH_ROOT}/examples/portable/executor_runner/executor_runner.cpp
${EXECUTORCH_ROOT}/extension/data_loader/file_data_loader.cpp
${EXECUTORCH_ROOT}/extension/evalue_util/print_evalue.cpp
${EXECUTORCH_ROOT}/extension/runner_util/inputs.cpp
${EXECUTORCH_ROOT}/extension/runner_util/inputs_portable.cpp
)
add_executable(openvino_executor_runner ${_openvino_executor_runner__srcs})

list(APPEND openvino_executor_runner_libs)

target_link_libraries(
openvino_executor_runner gflags portable_ops_lib
${openvino_executor_runner_libs}
)
target_compile_options(
openvino_executor_runner PUBLIC ${_common_compile_options}
)
endif()

# Install OpenVINO backend library to the lib directory
install(
TARGETS openvino_backend
Expand Down
2 changes: 1 addition & 1 deletion backends/openvino/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ Follow the steps below to setup your build environment:
```bash
./openvino_build.sh --enable_python
```
**Build C++ Runtime Libraries for OpenVINO Backend**: Run the `openvino_build.sh` script with the `--cpp_runtime` flag to build the C++ runtime libraries as shown in the below command. The compiled libraries files and binaries can be found in the `<executorch_root>/cmake-out` directory. The binary located at `<executorch_root>/cmake-out/backends/openvino/openvino_executor_runner` can be used to run inference with vision models.
**Build C++ Runtime Libraries for OpenVINO Backend**: Run the `openvino_build.sh` script with the `--cpp_runtime` flag to build the C++ runtime libraries as shown in the below command. The compiled libraries files and binaries can be found in the `<executorch_root>/cmake-out` directory. The binary located at `<executorch_root>/cmake-out/executor_runner` can be used to run inference with vision models.
```bash
./openvino_build.sh --cpp_runtime
```
Expand Down
3 changes: 2 additions & 1 deletion backends/openvino/scripts/openvino_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,11 @@ build_cpp_runtime() {
-DEXECUTORCH_BUILD_OPENVINO=ON \
-DEXECUTORCH_BUILD_EXTENSION_DATA_LOADER=ON \
-DEXECUTORCH_BUILD_EXTENSION_MODULE=ON \
-DEXECUTORCH_BUILD_EXTENSION_NAMED_DATA_MAP=ON \
-DEXECUTORCH_BUILD_EXTENSION_RUNNER_UTIL=ON \
-DEXECUTORCH_BUILD_EXTENSION_FLAT_TENSOR=ON \
-DEXECUTORCH_BUILD_EXTENSION_TENSOR=ON \
-DEXECUTORCH_BUILD_OPENVINO_EXECUTOR_RUNNER=ON \
-DEXECUTORCH_BUILD_EXECUTOR_RUNNER=ON \
-DEXECUTORCH_BUILD_KERNELS_QUANTIZED=ON \
-DEXECUTORCH_BUILD_EXTENSION_LLM=ON \
-DEXECUTORCH_BUILD_EXTENSION_LLM_RUNNER=ON \
Expand Down
4 changes: 2 additions & 2 deletions docs/source/build-run-openvino.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ The exported model will be saved as 'resnet50.pte' in the current directory.

### Build C++ OpenVINO Examples

After building the OpenVINO backend following the [instructions](#setup) above, the executable will be saved in `<executorch_root>/cmake-out/backends/openvino/`.
After building the OpenVINO backend following the [instructions](#setup) above, the executable will be saved in `<executorch_root>/cmake-out/`.

The executable requires a model file (`.pte` file generated in the aot step) and the number of inference executions.

Expand All @@ -101,7 +101,7 @@ The executable requires a model file (`.pte` file generated in the aot step) and
Run inference with a given model for 10 executions:

```
./openvino_executor_runner \
./executor_runner \
--model_path=model.pte \
--num_executions=10
```
Expand Down
8 changes: 4 additions & 4 deletions examples/openvino/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ Build the backend libraries and executor runner by executing the script below in
```bash
./openvino_build.sh
```
The executable is saved in `<executorch_root>/cmake-out/backends/openvino/`
The executable is saved in `<executorch_root>/cmake-out/`

### Run the Example with Executor Runner

Expand All @@ -166,9 +166,9 @@ Now, run the example using the executable generated in the above step. The execu
#### Command Syntax:

```
cd ../../cmake-out/backends/openvino
cd ../../cmake-out

./openvino_executor_runner \
./executor_runner \
--model_path=<path_to_model> \
--num_executions=<iterations>
```
Expand All @@ -182,7 +182,7 @@ cd ../../cmake-out/backends/openvino
Run inference with a given model for 10 iterations:

```
./openvino_executor_runner \
./executor_runner \
--model_path=model.pte \
--num_executions=10
```
Loading