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

Do we need dot Op to handle the vector cases? #946

Open
ricardoV94 opened this issue Jul 19, 2024 · 0 comments
Open

Do we need dot Op to handle the vector cases? #946

ricardoV94 opened this issue Jul 19, 2024 · 0 comments
Labels

Comments

@ricardoV94
Copy link
Member

ricardoV94 commented Jul 19, 2024

Description

A matrix vector dot or a vector dot matrix can be represented as a matrix - col/row dot followed by a squeeze of the useless dims.

I don't think we're making any special use of of the vector cases and it creates more versions of equivalent graphs for us to handle. For instance we have a special blockwise for the matrix matrix dot but not the other cases. We wouldn't need to if our core dot Op only did matrix matrix.

We already do this rewrite anyway here, so why not use that as the canonical representation?

def local_dot_to_dot22(fgraph, node):

Only reason I can see is if different routines wil be triggered for the special vector cases? I would be surprised if our backends didn't have special handling though :)

@ricardoV94 ricardoV94 changed the title Do we need dot Op to handle the vector caes? Do we need dot Op to handle the vector cases? Jul 19, 2024
@ricardoV94 ricardoV94 added the needs info Additional information required label Jul 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant