Ubuntu 11.04、Ubuntu 12.04、WindowsXPSP3をすべて「デュアルブート」して更新しました。PCはかなり古いIntelCeleronD CPU 3.06GHz、2GB RAM
Ubuntu 11.04ではNumpyをATLASでコンパイルしています(ATLASはソースからコンパイルしています)
Ubuntu 12.04ではNumpyを最新のMKL、icc、ifortでビルドしてい
ますWindows XPではNumpyとMKLを使用しています(Christoph Gohlkeから提供されたPythonパッケージから)
詳細ここ: http: //pastebin.com/raw.php?i = wxuFbyVg
私は簡単に試しました:
%timeit np.dot(np.ones((1000,1000)), np.ones((1000,1000)))
そしてこの結果を得ました:
Ubuntu ATLAS: 1 loops, best of 3: 457 ms per loop
Windows MKL: 1 loops, best of 3: 680 ms per loop
Ubuntu MKL: 1 loops, best of 3: 1.04 s per loop
上記は悪い例だと思い、利用可能な多くの比較の1つを検索しました。つまり、最初のGoogleヒット:http ://dpinte.wordpress.com/2010/01/15/numpy-performance-improvement-with-the-mkl/
私は同じ機能をテストしました:
%timeit test_eigenvalue()
Ubuntu Atlas: 1 loops, best of 3: 6.38 s per loop
Windows MKL: 1 loops, best of 3: 2.22 s per loop
Ubuntu MKL: 1 loops, best of 3: 3.58 s per loop
%timeit test_svd()
Ubuntu Atlas: 1 loops, best of 3: 2.13 s per loop
Windows MKL: 1 loops, best of 3: 2.06 s per loop
Ubuntu MKL: 1 loops, best of 3: 3.09 s per loop
%timeit test_inv()
Ubuntu Atlas: 1 loops, best of 3: 964 ms per loop
Windows MKL: 1 loops, best of 3: 1.02 s per loop
Ubuntu MKL: 1 loops, best of 3: 1.59 s per loop
%timeit test_det()
Ubuntu Atlas: 1 loops, best of 3: 308 ms per loop
Windows MKL: 1 loops, best of 3: 322 ms per loop
Ubuntu MKL: 1 loops, best of 3: 491 ms per loop
%timeit test_dot()
Ubuntu Atlas: 1 loops, best of 3: 1.5 s per loop
Windows MKL: 1 loops, best of 3: 1.77 s per loop
Ubuntu MKL: 1 loops, best of 3: 2.77 s per loop
したがって、ATLASでコンパイルされたNumpyは、何らかの理由で最良の結果をもたらします。
誰かが問題になる可能性があることを知っていますか?