Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update ONNX Python tests #1514

Conversation

rblaczkowski
Copy link
Contributor

* enable more ONNX python tests
* increase XFAIL cases
* small refactor

@rblaczkowski rblaczkowski requested review from a team July 28, 2020 12:54
ngraph/python/tests/test_onnx/utils/__init__.py Outdated Show resolved Hide resolved
ngraph/python/tests/test_onnx/utils/__init__.py Outdated Show resolved Hide resolved
ngraph/python/tests/test_onnx/utils/__init__.py Outdated Show resolved Hide resolved
ngraph/python/tox.ini Show resolved Hide resolved
@rblaczkowski rblaczkowski changed the title [WIP] Update ONNX python tests: Update ONNX python tests: Jul 30, 2020
ngraph/python/tests/test_onnx/test_ops_matmul.py Outdated Show resolved Hide resolved
ngraph/python/tests/test_onnx/test_zoo_models.py Outdated Show resolved Hide resolved
ngraph/python/tox.ini Show resolved Hide resolved
Copy link
Contributor

@arogowie-intel arogowie-intel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great refactoring - I like those parameterizations :)

ngraph/python/tests/test_onnx/test_ops_matmul.py Outdated Show resolved Hide resolved
assert_onnx_import_equals_callable("Elu", elu, [-0.9, -0.8, -0.7, -0.4, -0.3, -0.2, -0.1])
assert_onnx_import_equals_callable("Elu", elu, [[1, 2, 3], [4, 5, 6]])
assert_onnx_import_equals_callable("Elu", elu, [-2, -1.0, 0.0, 1.0, 2.0], alpha=0.5)
assert_onnx_import_equals_callable("Elu", elu, [-2, -1.0, 0.0, 1.0, 2.0], alpha=alpha_value)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess you want to use here test parameter:

Suggested change
assert_onnx_import_equals_callable("Elu", elu, [-2, -1.0, 0.0, 1.0, 2.0], alpha=alpha_value)
assert_onnx_import_equals_callable("Elu", elu, data, alpha=alpha_value)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, yes, thanks to point it out


reduce_data = np.array([[[5, 1], [20, 2]], [[30, 1], [40, 2]], [[55, 1], [60, 2]]], dtype=np.float32)
reduce_axis_parameters = [
# (operation, keepdims - True/False, axis)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure how this comment relates to the following code...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now this comment is deprecated - it was related to previous version - fixed

ngraph/python/tests/test_onnx/test_ops_reduction.py Outdated Show resolved Hide resolved
ngraph/python/tests/test_onnx/test_zoo_models.py Outdated Show resolved Hide resolved
ngraph/python/tests/test_onnx/test_ops_matmul.py Outdated Show resolved Hide resolved
ngraph/python/tests/test_onnx/test_ops_reduction.py Outdated Show resolved Hide resolved
ngraph/python/tox.ini Show resolved Hide resolved
@postrational postrational changed the title Update ONNX python tests: Update ONNX python tests Aug 4, 2020
@postrational postrational changed the title Update ONNX python tests Update ONNX Python tests Aug 4, 2020
@postrational postrational merged commit d14d09e into openvinotoolkit:master Aug 4, 2020
RomanZm pushed a commit to RomanZm/openvino that referenced this pull request Aug 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants