Saturday, 15 May 2010

python - how to deploy a C# application that calls numpy through IronPython -



python - how to deploy a C# application that calls numpy through IronPython -

i'm writing c# gui application i'd utilize numpy, have used under python 2.7 extensively , fast , easy program. (i still find gui work in c# much easier utilize pyqt.)

an ironpython port of numpy , scipy exists , i'd larn how utilize it.

before starting, i'd know kind of deployment options have? can wrap python , numpy or have install python, ironpython, numpy on customer's machines?

you can wrap ironpython code .net assembly dll or exe. if need load code other .net code, create dll using ironpython script

import clr clr.compilemodules(dllname, module1.py, module2.py,...)

then load assembly

assembly dpma = assembly.loadfile(path.getfullpath("compiledironpythonmodule.dll")); pyengine.runtime.loadassembly(dpma);

(c# example). in visualstudio need references ironpython , dll in project.

i succeeded in compiling numpy , scipy-refactored scratch ironpython 2.7.5, visual studio 2012 .net 4.0 intel fortran composer xe 2013 (using latter needed changes scipy iron_setup.py files). output set of dlls. can @ point import modules on ironpython command line. what's not working yet how cook ironpython code numpy/scipy import .net assembly. this, checking ironpycompiler.

c# python numpy ironpython

No comments:

Post a Comment