Hacker News new | past | comments | ask | show | jobs | submit login

I updated with a pandas script as well.

I think the strength of the languages have in part to do with their libraries. You have to pick the right tools for the right task.

The pandas version runs 3x faster than regular python, but 17x slower than C.




Great, I'll include that in the next run of the benchmark. Is it Python 3 or 2? (Does it work with Pypy) Also, if you're comparing it to C you should compare it to C3.c, from the final tables, which uses bignums like Python does automatically.

*Edit: I tried your faster_py.py, but it didn't seem any faster than Pypy2.py in the repo (running both with Pypy). I haven't yet got the Pandas version to work due to library compatibility issues (I've got about five versions of Python installed; still working on it).


It's about 2x faster in regular CPython 2.7 on my machine. In pypy it is actually way slower than your original one.

In many cases, pypy cannot be used, because it's not compatible with all the libraries.


Ah, right. I've included your version (converted to Python 3) as Python3_fst; it's around twice as fast as regular CPython 3.3.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: