[CWB] CWB4 and Ziggurat
Stefan Evert
stefanML at collocations.de
Sat Oct 10 09:47:08 CEST 2015
> On 9 Oct 2015, at 20:45, Yannick Versley <yversley at gmail.com> wrote:
>
> I'd suggest to do it in Python if the Python interpreter weren't quite as bad as it is. Slower than R, seriously?
> Slower than R would be weird. See here for a semi-scientific comparison
> http://www.johndcook.com/blog/2014/06/20/benchmarking-c-python-r-etc/
Sure, but it's unlikely that we're ever going to solve the "stochastic neoclassical growth model, the workhorse of modern macroeconomics" with CQP.
And I find it a little suspicious that CPython is much faster on their Windows machine (even if you take relative times compared to C++). Usually, people on mailing lists (mostly R, I have to admit) ask why their scripting code is slower on Windows than Linux.
Here's what I get with a simple count loop of the form
for x in xrange(N+1):
sum = sum + x
python/simple_count.py 7.47 Mops/s (20.0M ops in 2.68 s)
py3/simple_count.py 7.62 Mops/s (20.0M ops in 2.62 s)
R/simple_count.R 15.59 Mops/s (20.0M ops in 1.28 s)
perl/simple_count.perl 18.17 Mops/s (40.0M ops in 2.20 s)
lua/simple_count.lua 97.12 Mops/s (100.0M ops in 1.03 s)
Now tell me that less than 8 million loops per second isn't just sad. I was going to say that even bash scripting has got to be faster than this, but …
bash/simple_count.sh 0.07 Mops/s (0.2M ops in 2.92 s)
Best, and thanks for the additional pointers to interesting software packages,
Stefan
More information about the CWB
mailing list