Skip to content

Commit ed6d8e0

Browse files
authored
Commit PSU Lora fix (#791)
1 parent e974fbe commit ed6d8e0

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

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

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -171,16 +171,20 @@ std::vector<std::unique_ptr<ComputeCapability>> GetCapability::Execute() {
171171
for (auto this_cluster : connected_clusters) {
172172
bool omit_subgraph = false;
173173

174-
//auto id = this_cluster.at(0);
175174
if (this_cluster.size() == 1) {
176175
//check next cluster
177176
auto index = this_cluster.at(0);
177+
size_t j = cluster_index;
178178
if (graph_viewer_.GetNode(index)->OpType() == "EPContext") {
179179
omit_subgraph=false;
180-
} else if(cluster_index < total_clusters-1) {
181-
bool append_node = AddTrivialClusterToNextClusterIfConnected(graph_viewer_, index, connected_clusters[cluster_index+1]);
180+
} else if(j < total_clusters-1) {
181+
bool append_node = false;
182+
while(j<total_clusters && !append_node) {
183+
j=j+1;
184+
append_node = AddTrivialClusterToNextClusterIfConnected(graph_viewer_, index, connected_clusters[j]);
185+
}
182186
if(append_node) {
183-
connected_clusters[cluster_index+1].emplace_back(index);
187+
connected_clusters[j].emplace_back(index);
184188
}
185189
omit_subgraph=true;
186190
}

onnxruntime/test/providers/cpu/controlflow/loop_test.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -688,7 +688,7 @@ TEST(Loop, SubgraphTypeOverride) {
688688
Graph::ResolveOptions options;
689689
options.override_types = true;
690690
test.Run(OpTester::ExpectResult::kExpectSuccess, "",
691-
{kTensorrtExecutionProvider}, &session_run_options, nullptr,
691+
{kTensorrtExecutionProvider, kOpenVINOExecutionProvider}, &session_run_options, nullptr,
692692
ExecutionMode::ORT_SEQUENTIAL, options);
693693
}
694694

0 commit comments

Comments
 (0)