4 ms·
The rest is not a fair comparison, because it rewrites the used libraries, not the application code. You can always speed up an application if you rewrite the
by FreeHugs 4y ago
The rest is not a fair comparison, because it rewrites the used libraries, not the application code.
You can always speed up an application if you rewrite the used libraries to match your specific use case.
- flohofwoe 4y agoUsually not by 10x though, unless the original implementation involved some really bad decisions.
- wnkrshm 4y agoThe Rust code is still only brute force - using suitable persistent acceleration structures you can probably get a 10x again or maybe even 100x, in 2D a kd-tree is really fast for NNs. So much faster that the allocations for the result will probably be the bottleneck.
- iudqnolq 4y agoIt's a fair comparison if the purpose is to guide people in fixing performance issues in their python code. "That Rust library will be faster than the corresponding python library" is a useful thing to know here.