Skip to content

Commit 13e4bff

Browse files
author
DEKHTIARJonathan
committed
[TF-TRT] Adjusting Conv2D Test Tolerance
1 parent cd17810 commit 13e4bff

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tensorflow/python/compiler/tensorrt/test/conv2d_test.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,14 @@ def ExpectedEnginesToBuild(self, run_params):
164164
"""Return the expected engines to build."""
165165
return ["TRTEngineOp_000"]
166166

167+
def ExpectedAbsoluteTolerance(self, run_params):
168+
"""The absolute tolerance to compare floating point results."""
169+
return 5.e-01 if run_params.precision_mode == "INT8" else 1.e-02
170+
171+
def ExpectedRelativeTolerance(self, run_params):
172+
"""The relative tolerance to compare floating point results."""
173+
return 5.e-00 if run_params.precision_mode == "INT8" else 1.e-02
174+
167175

168176
class Conv2DTranposeTest(trt_test.TfTrtIntegrationTestBase):
169177
"""Testing conversion of conv2d_transpose (AKA Conv2DBackpropInput)"""

0 commit comments

Comments
 (0)