2009-01-06 46 views
2

我被迫升級到Python 2.6和我有使用Python的數值(NumPy)與Python 2.6 Windows中的問題。我收到以下錯誤......我如何使用Python的數值與Python 2.6

Traceback (most recent call last): 
    File "<pyshell#0>", line 1, in <module> 
    from numpy.core.numeric import array,dot,all 
    File "C:\svn\svn_urbansim\UrbanSimDev\Builds\working\urbansim\Tools\Python26\lib\site-packages\numpy\__init__.py", line 39, in <module> 
    import core 
    File "C:\svn\svn_urbansim\UrbanSimDev\Builds\working\urbansim\Tools\Python26\lib\site-packages\numpy\core\__init__.py", line 5, in <module> 
    import multiarray 
ImportError: Module use of python25.dll conflicts with this version of Python. 

看來,現有的模塊試圖使用python25.dll文件。有沒有什麼辦法可以告訴它使用python26.dll文件而不修改源代碼?

回答

9

你怎麼安裝? NumPy目前沒有Python 2.6二進制文件。

如果您有LAPACK/ATLAS/BLAS等等和開發環境,您應該能夠從源代碼編譯numpy。否則,我認爲如果你需要NumPy,你會在Windows上使用Python 2.5。

NumPy的下一版本應該有一個2.6二進制文件,它可能在未來一個月左右的時間內出來。

[編輯]:好像有一個pygame的開發者在Windows上創建了一個與NumPy 1.2.1二進制的Python 2.6,可here