[SciPy-user] Benchmark data

Travis Oliphant oliphant.travis at ieee.org
Sat Dec 10 00:50:56 EST 2005


I know people may be tired of the benchmark data, but I'm just trying to 
understand what kinds of techniques produce fast code.   

I recompiled python 2.4.2 using gcc 3.4.1 on Mandrake 10.1 (with 
py-debug off) and rebuilt Numeric, numarray, and scipy_core.

The results of my benchmarks are:

 > uname -a
Linux oliphant 2.6.3-9mdkenterprise #1 SMP Fri Apr 23 12:23:42 EDT 2004 
i686 Intel(R) Xeon(TM) CPU 2.66GHz unknown GNU/Linux

Python 2.4.2 (#1, Dec  9 2005, 22:29:36)
[GCC 3.4.1 (Mandrakelinux 10.1 3.4.1-4mdk)]
Optimization flags: -DNDEBUG -g -O3 -Wall -Wstrict-prototypes
CPU info: getNCPUs=2 has_mmx has_sse has_sse2 is_32bit is_Intel
Numeric-24.2
numarray-1.5.1
scipy-core-0.8.1.1619
benchmark size = 12  (vectors of length 16777216)
label            Numeric       numarray     scipy.base
    1             0.5558         0.1091         0.4889
    2             0.3804         0.3641         0.3706
    3             0.2654          0.265         0.2802
    4              1.302         0.7388         0.7712
    5             0.4035         0.4016         0.3729
    6             0.2651         0.2689           0.28
    7              1.304         0.9061         0.7685
    8              1.077         0.6743         0.6736
    9              14.15          12.75          12.81
   10              13.94          13.51          12.79
   11              11.16          10.58          10.39
TOTAL               44.8          40.56             40


So, I'm not sure how to reproduce what Gerard sees (except numarray's 
faster arange)
which is a little perplexing.  I suppose that's why people criticize 
benchmarks so much.

But at least we can still see that an improved arange may be a benefit.  
As part of the recent
ufunc changes, I also improved the remainder function to not use 
floating point unless
it must (in order to match the python's remainder function). 
Notice that neither numarray nor Numeric match python's usage of % for 
integers.

-Travis





More information about the SciPy-User mailing list