|
|
|
|
|
by kwertzzz
2977 days ago
|
|
Sorry for the delay, but here is an example code: https://gist.github.com/Alexander-Barth/c8eb764f400cdb7a1eb5... Do not hesitate to tell me if I missed something to optimize the python code. If somebody has numba, pythan,... installed, I would be interested to see the speed-up compared to the vanilla python version on your machine. So in short, for my cases: the fastest Julia test case (with loops and avoiding unnecessary allocation) was about 10x faster than fastest python 3 test case (with vectorization). The runtime with vectorization are relatively similar (julia
is only about 25% faster than python). Explicit loop and careful memory management are clearly beneficial in Julia. |
|
Moral of the story is, these Python tools are built for microbenchmarks and can do okay there, but without the full stack optimized together and without a type system that's exploitable for all of the performance tricks, it falls apart in real-world code.