Pros and cons of IronPython and IronPython Studio
Asked Answered
F

3

16

We are ready in our company to move everything to Python instead of C#, we are a consulting company and we usually write small projects in C# we don't do huge projects and our work is more based on complex mathematical models not complex software structures. So we believe IronPython is a good platform for us because it provides standard GUI functionality on windows and access to all of .Net libraries.

I know Ironpython studio is not complete, and in fact I had a hard time adding my references but I was wondering if someone could list some of the pros and cons of this migration for us, considering Python code is easier to read by our clients and we usually deliver a proof-of-concept prototype instead of a full-functional code, our clients usually go ahead and implement the application themselves

Fives answered 23/1, 2009 at 2:49 Comment(1)
F# is pretty good for scripting stuff as well, don't know if you've considered that as an option.Sunday
S
18

My company, Resolver Systems, develops what is probably the biggest application written in IronPython yet. (It's called Resolver One, and it's a Pythonic spreadsheet). We are also hosting the Ironclad project (to run CPython extensions under IronPython) and that is going well (we plan to release a beta of Resolver One & numpy soon).

The reason we chose IronPython was the .NET integration - our clients want 100% integration on Windows and the easiest way to do that right now is .NET.

We design our GUI (without behaviour) in Visual Studio, compile it into a DLL and subclass it from IronPython to add behaviour.

We have found that IronPython is faster at some cases and slower at some others. However, the IronPython team is very responsive, whenever we report a regression they fix it and usually backport it to the bugfix release. If you worry about performance, you can always implement a critical part in C# (we haven't had to do that yet).

If you have experience with C#, then IronPython will be natural for you, and easier than C#, especially for prototypes.

Regarding IronPython studio, we don't use it. Each of us has his editor of choice (TextPad, Emacs, Vim & Wing), and everything works fine.

Sordid answered 23/1, 2009 at 9:29 Comment(0)
T
9

There are a lot of reasons why you want to switch from C# to python, i did this myself recently. After a lot of investigating, here are the reasons why i stick to CPython:

  • Performance: There are some articles out there stating that there are always cases where ironpython is slower, so if performance is an issue
  • Take the original: many people argue that new features etc. are always integrated in CPython first and you have to wait until they are implemented in ironpython.
  • Licensing: Some people argue this is a timebomb: nobody knows how the licensing of ironpython/mono might change in near future
  • Extensions: one of the strengths of python are the thousands of extensions which are all usable by CPython, as you mentioned mathematical problems: numpy might be a suitable fast package for you which might not run as expected under IronPython (although Ironclad)
  • Especially under Windows you have a native GUI-toolkit with wxPython which also looks great under several other platforms and there are pyQT and a lot of other toolkits. They have nice designer like wxGlade, but here VisualStudio C# Designer is easier to use.
  • Platform independence (if this is an issue): CPython is ported to really a lot of platforms, whereas ironpython can only be used on the major platforms (recently read a developer was sad that he couldn't get mono to run under his AIX)

Ironpython is a great work, and if i had a special .NET library i would have to use, IronPython might be the choice, but for general purpose problems, people seem to suggest using the original CPython, unless Guido changes his mind.

Timisoara answered 23/1, 2009 at 9:6 Comment(2)
Something to note, IronPython 2.0 has beaten CPython in all the performance tests now. IronPython 1.0 was about compatibility, 2.0 was about performance. Keep in mind, its possible to use a JIT like Psyco to improve Cpython performance significantly (2x to 100x)Zeebrugge
I use both IronPython and Cpython personally. I tend to use IronPython when I need .Net, Cpython when I need numpy, scipy or matplotlib. The rest of my scripts tend to run happily under either. I use SciTe as my editor for IronPython and Spyder as my IDE for CPython. I am a huge fan of Spyder personally, but it does not play well with IronPython currently.Journalize
Z
7

The way you describe things, it sounds like you're company is switching to Python simple for the sake of Python. Is there some specific reason you want to use Python? Is a more dynamic language necessary? Is the functional programming going to help you at all? If you've got a perfectly good working set of tools in C#, why bother switching?

If you're set on switching, you may want to consider starting with standard Python unless you're specifically tied to the .NET libraries. You can write cross platform GUIs using a number of different frameworks like wxPython, pyQt, etc. That said, Visual Studio has a far superior GUI designer to just about any of the tools out there for creating Python windowed layouts.

Zeebrugge answered 23/1, 2009 at 2:59 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.