Dzerzhinskogo Ave. 104, Suite 601

Minsk, Belarus

Python – my new magic katana! How I became a true R&D warrior…
Jul 24, 2017

Python – my new magic katana! How I became a true R&D warrior…

Several months ago I have been invited to participate in one project as a mathematician. The customer had several tasks in project backlog, related with computations, geometry and multi-dimensional analysis. And they asked me to produce an algorithmic solution to resolve these tasks. Sounds interesting – I am educated mathematician, and I have wide experience in software development and R&D.

Looks like everything matched! But they use the Python in development, and I was never using it before. Yes, I was using much languages and platforms, including platforms for scientific modeling and computations – but not Python.

By arrangement, was planned that I should write mathematical descriptions for developers and they would implement solutions in Python. After beginning, I understand that this way is ugly. Very uncomfortable to think twice – how to solve the problem, and then how to describe the solution for the developer. And I decided to write the prototypes of calculation modules directly in Python by myself.

I thought – I know the OOP good and saw much in my working life, and I spent a weekend for reading language description to understand language syntax and structure. Everything looks clear by I had some apprehensions – what may be good in the language named in honor of “Monty Python”? This really looks like joke…

I started to write in Python and got some first impressions:

  • Language named in honor of “Monty Python” is the real joke! But that has a different meaning – It is just a mockery of languages with a rigid structure.

Python is so flexible, that you have several solutions to any problem in bounds of language standards! You may use several syntax approaches to describe one operations block! This looks crazy but very comfortable in sense of the personal coding style and a solution view.

  • Object structures and binary operations on them, look very logical and natively understandable. You just work with mathematical objects by mathematical rules in functional form – what do you need more? 🙂
  • At the first week of using Python, I found Anaconda – open Python based platform for scientific computations and data analysis. It has its own repository with a huge number of scientific modules: for math computations and symbolic algebra (as SciPy, NumPy, etc.), for geometry calculations & data visualization, for calculations with arbitrary-precision, for working with 3d meshes, etc.…

I never saw so many instruments in one place.

  • The language contains the hell dream of OOP developer – multiple inheritances (object mixing)!

Also, you can modify not only objects in real time, but their metadata and description (classes), you may change inheritance chain of object on the fly, And much more…

I am not sure that all of that would be needed – but I saw that for the first time in my life in one language! This looks extremely flexible!

But language contains syntax and documenting standards – so this is not a toy – but a serious and flexible instrument.

  • Huge friendly and organized community of Python is open for new members – tons of open source modules, documents, courses – you will never be alone.

Several months passed – were solved first tasks, and I saw much more: a huge amount of ORMs, web-backend frameworks, architecture frameworks, I worked with blender scripting and more… And I do not see the bottom of that magic pot! 🙂

I continue to study Python and related areas and feel happy that I decided to use it several months ago. For me as for R&D scientist/developer that was the best solution in last years. For now, I plan to work in that area for the next years – I want to know and do more…

I feel, that I found my magic katana, and I am ready to fights!

Author: Anton Dziavitsyn, lead software engineer at Inventolabs.
*The text retains author’s spelling and punctuation.
The author’s style of writing has been saved.