Skip to content

Commit 8f66017

Browse files
authored
[Bugfix] Fix OrtCompatiableGetInputName errors (#435)
* Update utils.cmake * Update vae.h * Update test_lite_sd_pipeline.cpp * Update ort_config.h
1 parent e3f653e commit 8f66017

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lite/ort/core/ort_config.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ inline static std::string OrtCompatiableGetInputName(size_t index, OrtAllocator*
1717
#if ORT_API_VERSION >= 14
1818
return std::string(ort_session->GetInputNameAllocated(index, allocator).get());
1919
#else
20-
return std::string(ort_session->GetInputName(i, allocator));
20+
return std::string(ort_session->GetInputName(index, allocator));
2121
#endif
2222
}
2323

@@ -26,7 +26,7 @@ inline static std::string OrtCompatiableGetOutputName(size_t index, OrtAllocator
2626
#if ORT_API_VERSION >= 14
2727
return std::string(ort_session->GetOutputNameAllocated(index, allocator).get());
2828
#else
29-
return std::string(ort_session->GetOutputName(i, allocator));
29+
return std::string(ort_session->GetOutputName(index, allocator));
3030
#endif
3131
}
3232

0 commit comments

Comments
 (0)