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

Add Blas3 to the sources #1311

Closed
amueller opened this issue Nov 2, 2012 · 10 comments
Closed

Add Blas3 to the sources #1311

amueller opened this issue Nov 2, 2012 · 10 comments

Comments

@amueller
Copy link
Member

amueller commented Nov 2, 2012

@fabianp could you please give me a hand in that?

@fabianp
Copy link
Member

fabianp commented Nov 2, 2012

I've been trying to avoid this since it's a LOT of code with lots of special cases (much much more than level1-2) and because level3 is O(n^3) operations probably inlining in cython is not so important and the python functions returned by get_blas_funcs would do the job.

What's the particular usercase? Is the function missing from get_blas_funcs (in that case I would gladly help you with f2py) ?

@amueller
Copy link
Member Author

amueller commented Nov 2, 2012

There are two use-cases: the speed-up of euclidean distances by @vene #1006 and neural networks.
I profiled the neural network and with the current batch-size, there is significant overhead.
Even without batches, there is a vector x vector (i.e. rank 1) matrix multiplication. That is also blas3, right?

in case of Vlad's PR, the compilation worked, but there was an linker error on my box.

@fabianp
Copy link
Member

fabianp commented Nov 2, 2012

If you are speaking about ger that's level 2.

@fabianp
Copy link
Member

fabianp commented Nov 2, 2012

Anyway sure I could help with particular problems but adding the full level3 specification is IMHO a bit overkill.

@fabianp
Copy link
Member

fabianp commented Nov 2, 2012

Also, if you want to team up with the scipy guys (I talked with Ralph Gommers at EuroScipy) they where open-minded to expose a C API for BLAS functions (via Cython) , which frankly would be of great benefit for us.

@amueller
Copy link
Member Author

amueller commented Nov 2, 2012

Yeah, exposing blas via Cython is really what we want. We would have to maintain a backport but that would be better than doing it ourselves.

Yes, I wanted ger. Having the same for batches would be gemm, right? So this would be what I want....

@amueller
Copy link
Member Author

amueller commented Nov 2, 2012

Not sure what @vene wants, though.

@fabianp
Copy link
Member

fabianp commented Nov 2, 2012

Adding gemm seems reasonable to me. I see in @vene's PR references to dgemm so I suppose the goal is to add that to the cblas directory, right ?

@amueller
Copy link
Member Author

amueller commented Nov 2, 2012

yes, that would be great :)

@fabianp
Copy link
Member

fabianp commented Nov 2, 2012

Done, see #1313

@amueller amueller closed this as completed Nov 2, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants