Skip to content

Commit

Permalink
[Relay][Frontend][ONNX] Remove the 'try catch' block
Browse files Browse the repository at this point in the history
  • Loading branch information
cchung100m committed Nov 15, 2019
1 parent c2a51dd commit 0027688
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions tests/python/frontend/onnx/test_forward.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,13 +159,8 @@ def verify_depth_to_space(inshape, outshape, mode, blockSize):
for target, ctx in ctx_list():
x = np.random.uniform(size=inshape).astype('float32')
tvm_out = get_tvm_output(model, x, target, ctx, outshape, 'float32')
try:
onnx_out = get_onnxruntime_output(model, x, 'float32')
except onnx.onnx_cpp2py_export.checker.ValidationError as e:
import warnings
warnings.warn(str(e))
else:
tvm.testing.assert_allclose(onnx_out, tvm_out)
onnx_out = get_onnxruntime_output(model, x, 'float32')
tvm.testing.assert_allclose(onnx_out, tvm_out)


def test_depth_to_space():
Expand Down

0 comments on commit 0027688

Please sign in to comment.