summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHenning Baldersheim <balder@yahoo-inc.com>2022-04-03 18:03:14 +0200
committerGitHub <noreply@github.com>2022-04-03 18:03:14 +0200
commit35c74d9abcfa7abb0cc12c1b47d26bac6f24f997 (patch)
treee16f5c826ca1c052b3ba5ecffe1e5c1496ce5e0f
parenta8ebc51eaeb26c977e997e6a9f1dab2123cdddcf (diff)
parent363bb6411525d55abb0c17ad821a54b63f7f4865 (diff)
Merge pull request #21956 from vespa-engine/toregge/track-changes-to-onnxruntime-api
Track changes to onnxruntime API.
-rw-r--r--eval/src/tests/tensor/onnx_wrapper/onnx_wrapper_test.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/eval/src/tests/tensor/onnx_wrapper/onnx_wrapper_test.cpp b/eval/src/tests/tensor/onnx_wrapper/onnx_wrapper_test.cpp
index e50c41e2e09..021b20149d1 100644
--- a/eval/src/tests/tensor/onnx_wrapper/onnx_wrapper_test.cpp
+++ b/eval/src/tests/tensor/onnx_wrapper/onnx_wrapper_test.cpp
@@ -482,7 +482,11 @@ TEST(OnnxTest, inspect_float_to_int8_conversion) {
TEST(OnnxTest, default_allocator_type) {
Ort::AllocatorWithDefaultOptions default_alloc;
+#if ORT_API_VERSION >= 10
+ OrtAllocatorType res = OrtInvalidAllocator;
+#else
OrtAllocatorType res = Invalid;
+#endif
Ort::ThrowOnError(Ort::GetApi().MemoryInfoGetType(default_alloc.GetInfo(), &res));
fprintf(stderr, "default allocator type: %d\n", int(res));
}