Skip to content

Commit aa8e4fb

Browse files
committed
update: Upgraded to OpenVINO v2024.2
1 parent 4ac4cd2 commit aa8e4fb

File tree

4 files changed

+12
-13
lines changed

4 files changed

+12
-13
lines changed

cmake/onnxruntime_providers_openvino.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@
1717

1818
# Header paths
1919
find_package(OpenVINO REQUIRED COMPONENTS Runtime ONNX)
20-
if(OpenVINO_VERSION VERSION_LESS 2023.0)
21-
message(FATAL_ERROR "OpenVINO 2023.0 and newer are supported. Please, latest OpenVINO release")
20+
if(OpenVINO_VERSION VERSION_LESS 2023.3)
21+
message(FATAL_ERROR "OpenVINO 2023.3 and newer are supported. Please, use latest OpenVINO release")
2222
endif()
2323

2424
if (WIN32)

onnxruntime/core/providers/openvino/ov_versions/capability.cc

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,18 +35,16 @@ GetCapability::GetCapability(const GraphViewer& graph_viewer_param,
3535
device_type_ = "CPU";
3636
if (enable_qdq_optimizer) npu_qdq_optimizer_enabled = true;
3737
}
38-
#if OPENVINO_VERSION_MAJOR == 2023 && OPENVINO_VERSION_MINOR == 1
39-
data_ops_ = new DataOps(graph_viewer_, V_2023_1, device_type_, npu_qdq_optimizer_enabled);
40-
#elif OPENVINO_VERSION_MAJOR == 2023 && OPENVINO_VERSION_MINOR == 2
41-
data_ops_ = new DataOps(graph_viewer_, V_2023_2, device_type_, npu_qdq_optimizer_enabled);
42-
#elif OPENVINO_VERSION_MAJOR == 2023 && OPENVINO_VERSION_MINOR == 3
38+
#if OPENVINO_VERSION_MAJOR == 2023 && OPENVINO_VERSION_MINOR == 3
4339
data_ops_ = new DataOps(graph_viewer_, V_2023_3, device_type_, npu_qdq_optimizer_enabled);
4440
#elif OPENVINO_VERSION_MAJOR == 2024 && OPENVINO_VERSION_MINOR == 0
4541
data_ops_ = new DataOps(graph_viewer_, V_2024_0, device_type_, npu_qdq_optimizer_enabled);
4642
#elif OPENVINO_VERSION_MAJOR == 2024 && OPENVINO_VERSION_MINOR == 1
4743
data_ops_ = new DataOps(graph_viewer_, V_2024_1, device_type_, npu_qdq_optimizer_enabled);
44+
#elif OPENVINO_VERSION_MAJOR == 2024 && OPENVINO_VERSION_MINOR == 2
45+
data_ops_ = new DataOps(graph_viewer_, V_2024_2, device_type_, npu_qdq_optimizer_enabled);
4846
#else
49-
data_ops_ = new DataOps(graph_viewer_, V_2024_1, device_type_, npu_qdq_optimizer_enabled);
47+
data_ops_ = new DataOps(graph_viewer_, V_2024_2, device_type_, npu_qdq_optimizer_enabled);
5048
#endif
5149
}
5250

onnxruntime/core/providers/openvino/ov_versions/data_ops.cc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -361,7 +361,7 @@ void DataOps::populate_op_mode_supported() {
361361

362362
// populate unsupportedmode_t
363363
{
364-
UnsupportedOpMode obj = {{V_2024_1},
364+
UnsupportedOpMode obj = {{V_2024_1, V_2024_2},
365365
[this](const Node* node, const InitializedTensorSet&) {
366366
// If the Input of ReduceMax op is UINT8, it is rejected (Due to output mismatch)
367367
for (size_t i = 0; i < node->InputDefs().size(); i++) {
@@ -376,7 +376,7 @@ void DataOps::populate_op_mode_supported() {
376376
op_list_.insert({"ReduceMax", obj});
377377
}
378378
{
379-
UnsupportedOpMode obj = {{V_2023_1, V_2023_2, V_2023_3, V_2024_0, V_2024_1},
379+
UnsupportedOpMode obj = {{V_2023_1, V_2023_2, V_2023_3, V_2024_0, V_2024_1, V_2024_2},
380380
[this](const Node* node, const InitializedTensorSet&) {
381381
const auto& input_arg = node->InputDefs()[1];
382382
auto shape = input_arg->Shape();
@@ -393,7 +393,7 @@ void DataOps::populate_op_mode_supported() {
393393
op_list_.insert({"Reshape", obj});
394394
}
395395
{
396-
UnsupportedOpMode obj = {{V_2023_1, V_2023_2, V_2023_3, V_2024_0, V_2024_1},
396+
UnsupportedOpMode obj = {{V_2023_1, V_2023_2, V_2023_3, V_2024_0, V_2024_1, V_2024_2},
397397
[this](const Node* node, const InitializedTensorSet&) {
398398
// If the operator is unsqueeze
399399
// If axes is an input, then we cannot produce a static graph.
@@ -408,7 +408,7 @@ void DataOps::populate_op_mode_supported() {
408408
op_list_.insert({"Unsqueeze", obj});
409409
}
410410
{
411-
UnsupportedOpMode obj = {{V_2023_1, V_2023_2, V_2023_3, V_2024_0, V_2024_1},
411+
UnsupportedOpMode obj = {{V_2023_1, V_2023_2, V_2023_3, V_2024_0, V_2024_1, V_2024_2},
412412
[this](const Node* node, const InitializedTensorSet&) {
413413
// check for attributes
414414
auto& upsample_attr = node->GetAttributes();

onnxruntime/core/providers/openvino/ov_versions/data_ops.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@ enum versionNum {
2828
V_2023_2,
2929
V_2023_3,
3030
V_2024_0,
31-
V_2024_1
31+
V_2024_1,
32+
V_2024_2
3233
};
3334

3435
using VersionNum = enum versionNum;

0 commit comments

Comments
 (0)