-
Notifications
You must be signed in to change notification settings - Fork 34
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
Issue with Distances.jl #380
Comments
One option would be to entirely replace Distances with Tullio.jl. I've found it's very performant in practice, and it's quite a bit more flexible 🤷 . It has GPU support, so that would also be a win. |
Uuuh! I like it! So we create our own implementation of "pairwise" (like |
I think so? I'm not completely sure what the resulting implementation would look like -- it might be that we literally just have our own implementation of |
But we already have this in place (implementing our own pairwise), just not with Tullio and unnecessarily restricted to |
Yeah, in #194 I definitely went in the wrong direction trying to force-use the |
Oh wow! I just tried Tullio on CPU and even on SqEuclidean it's already a 3x speed up 😱 |
More updates, GPU is working with Tullio :) and is around 250x faster on my machine! However, if the input is structured as |
Nice, thanks for producing these. Is the correct interpretation that Tullio (for the sizes you picked) is roughly 50% slower than the implementations using |
Amazing. Even if we didn't want to adopt for CPU, this might be a great way to go for GPU. |
Oh! I actually forgot something! Somehow I could not get a nice std implementation for |
I guess this is not surprising as Distances uses scalar indexing which is terrible on GPUs (see JuliaStats/Distances.jl#143 and JuliaStats/Distances.jl#137). |
I meant that the GPU computations are 250x faster than the CPU ones (also using Tullio). Something like 7.3ms against 29μs |
We are relying a lot on
Distances.jl
however, as noted in #98, not all ourpairwise
operations are proper metrics.The PR #194 is stalling because defining everything again for
DotProduct
is quite a mess.@devmotion mentioned in #378 (comment) that we mostly don't need Distances.jl.
I am not really sure on how this should go!
The text was updated successfully, but these errors were encountered: