diff --git a/java/src/test/java/ai/onnxruntime/InferenceTest.java b/java/src/test/java/ai/onnxruntime/InferenceTest.java index 86587fe4b3a3d..e11537492d3a7 100644 --- a/java/src/test/java/ai/onnxruntime/InferenceTest.java +++ b/java/src/test/java/ai/onnxruntime/InferenceTest.java @@ -770,8 +770,9 @@ private void runProvider(OrtProvider provider) throws OrtException { if (provider == OrtProvider.CORE_ML) { // CoreML gives slightly different answers on a 2020 13" M1 MBP assertArrayEquals(expectedOutput, resultArray, 1e-2f); - } else if (provider == OrtProvider.CUDA) { + } else if (provider == OrtProvider.CUDA || provider == OrtProvider.TENSOR_RT) { // CUDA gives slightly different answers on a H100 with CUDA 12.2 + // Need larger tolerance since TRT 10.4 assertArrayEquals(expectedOutput, resultArray, 1e-3f); } else { assertArrayEquals(expectedOutput, resultArray, 1e-5f);