Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
kipukun
· 1y ago · 0 comments
To the second footnote: you could utilize Polar's lazyframe API to do that cosine similarity in a streaming fashion for large files.
Comments
[–]
minimaxir
1y ago
That would get around memory limitations but I still think that would be slow.
[–]
kipukun
OP
1y ago
You'd be surprised. As long as your query is using Polars natives and not a UDF (which drops it down to Python), you may get good results.
[–]
jononor
1y ago
A (simple) benchmark would be great to figure out where the practical limits of such an approach are. Runtime is expected to grow with O(n*2) which will get painful at some point.