Julia vs. Python 3 – Which programs are fastest?
benchmarksgame-team.pages.debian.net
benchmarksgame-team.pages.debian.net
I feel like Julia, faster though it seems to be, has a massive chip on the shoulder, keeps proving its erm performance is bigger than everyone else.
On the benchmarks where Julia is faster, it’s time is in bold. On the one regex one where Python happens to be faster, no bold. I guess outliers can be gleaned over.
It's not numpy. It's not numba. … https://pybenchmarks.org/
> in bold
A versus B, bold shows when the fastest A program is faster.
The Benchmarks Game is a project that dates back to at least 2002 (https://benchmarksgame-team.pages.debian.net/benchmarksgame/...), a decade before Julia was announced, collects code from many different languages, and lets you filter the results depending on what you are interested in. Go to the website, click on Python, and when selecting the other language, Python's results are in bold.
Why should Julia users be criticized for contributing code to a website dedicated to performance benchmarks, but it's ok for Python/Fortran/C/Javascript users to contribute? And why should this contribution from some individual count as evidence of some 'shoulder chip' for the wider language community?
(BTW, all benchmarks in all languages appear to be running on 4 cores, so it's not that weird for Julia to set NUM_THREADS to 4.)
Yeah, every language is using 4 threads: Java, C++, etc. The odd one out is Python not multithreading because GIL. Getting mad at Julia because Python is an outlier in a benchmark that's not maintained by Julia people is a very weird response to say the least.
You realise they didn't put the bold there manually?
> the Python code is painfully unoptimised, the Julia one has plenty of inclining, uses native vector types vs naked lists etc.
Yeah I agree this comparison is unfair, but who cares? Even if it was fair Julia should be way faster than Python! Python is one of the slowest languages in popular use. Everything should be faster than it.
The fact that somebody submitted a comparison to Python in the first place is kind of embarrassing. Like saying "look! my car is faster than a camel!".
Pity they didn't say what it was.
I wish there were more meaningful comparisons posted in a more objective manner. I'd like to see comparison that takes into consideration "ability to refactor", "ease of readability", "performance", and a few other (perhaps subjective) metrics. I'm not sure Julia will win out all the time depending on the weights you place on all these metrics.
We get to see how they compare.
Python: simple, short, very obvious what's going on, completely unoptimized. I wonder how much faster it would be, if it was (1) vectorized with numpy, and then (2) numba on top. I doubt it would be much less readable.
Julia: highly optimized (many "inline" annotations etc.), vectorized, much less readable than Python.
TL;DR: this isn't a fair comparison.
There is no shame in offering credit where due.
> many "inline" annotations etc.
https://benchmarksgame-team.pages.debian.net/benchmarksgame/...
Vectorization, in the sense of using `.+` etc, does not provide any speedup in Julia, it is only for notational convenience, and is at best the same speed as a loop, often slower.
People do say, but without program measurements…