How to install numpy and scipy for Ironpython27? Old method doesn't work

后端 未结 5 635
失恋的感觉
失恋的感觉 2020-11-29 06:42

I think this is the most popular way to do it before:

https://pytools.codeplex.com/wikipage?title=NumPy%20and%20SciPy%20for%20.Net

But this link is no longer

5条回答
  •  陌清茗
    陌清茗 (楼主)
    2020-11-29 07:42

    Updated Instructions July 2019:

    I was able to get scipy up and running in IronPython but wasn't able to follow @Nilser's instructions completely. Here are some updated instructions to get it working.

    Like others have said, the repo is now at http://code.enthought.com/.iron/eggs/index.html. Don't bother signing up for an Enthoughts account to access the old link, like some of the above comments suggest.

    The ironpkg-1.0.0.py file is no longer hosted in Enthought's repo for some reason. I was able to track it down and am hosting it on github so it's easier to find.

    1. Download IronPython-2.7.5.msi from the IronLanguages GitHub page and install it. I wasn't able to get scipy to work on newer versions of IronPython. I believe the dlls are bound to the 2.7.5 release of IronPython.
    2. Download ironpkg-1.0.0.1.egg from the Enthought repo at the above link.
    3. Copy the contents of the ironpkg-1.0.0.py from GitHub and create a new file with the contents named 'ironpkg-1.0.0.py' in the same folder that you downloaded the ironpkg egg.
    4. Open the cmd prompt as an administrator and navigate to where the ironpkg-1.0.0.py file is. Run ipy ironpkg-1.0.0.py --install. Check whether the install worked using ironpkg -h.
    5. Since Enthoughts changed the location of their repository, it is necessary to change the ironpkg config file to point to the address of the new location. The config file can be found at the user directory e.g. c:\users\\.ironpkg. Also note that this is a system file, so you have to show system files in order to see it. Open it in a textpad and update the address. Should be:
    IndexedRepos = [
        'http://code.enthought.com/.iron/eggs',
    ]
    
    1. Now you can run ironpkg scipy to install scipy and its dependencies.
    2. Check whether the install worked by running ipy -X:Frames -c "import scipy"

提交回复
热议问题