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

MatMul spec update #2765

Merged

Conversation

mitruska
Copy link
Contributor

@mitruska mitruska commented Oct 22, 2020

We are considering change in OpenVino MatMul specification, because of discrepancy with the current ngraph implementation for 1D tensors.

The tests on CPU proved that the current implementation follows rather numpy matmul shape inference logic instead of the openvino MatMul spec (1D x 1D seems to be not supported by CPU at all).
We shouldn't change the current behaviour of ngraph MatMul to ensure backward compatibility and numpy approach is rather common for other frameworks.

Multiplying two matrices of shape 2D and bigger seems to be the same and correct anyway.

I would like to ask people from other plugins to check support for MatMul 1D cases and specification review to ensure that we should update the MatMul spec.

This topic is related with fused op removal PR #2866.

Feel free to add other reviewers.

Ticket: 37453

@mitruska mitruska marked this pull request as ready for review October 23, 2020 08:07
@mitruska mitruska requested a review from a team as a code owner October 23, 2020 08:07
Copy link
Contributor

@slyalin slyalin left a comment

Choose a reason for hiding this comment

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

Do not apply transposition to 1D tensors.

@mitruska mitruska requested a review from slyalin November 4, 2020 10:38
@slyalin slyalin merged commit 15d7919 into openvinotoolkit:master Nov 6, 2020
mryzhov pushed a commit to mryzhov/openvino that referenced this pull request Dec 16, 2020
Aligned specification with nGraph MatMul shape inference operation. Affects description of the behavior for 1D tensors.
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.

6 participants