Getting Python


Python is a great programming language for several diverse purposes. One of the things that make it so good is the number and diversity of libraries available. This is also a curse sometimes; because the installation of these libraries over a vast number of scenarios (different OSs, devices, etc) may give place to unexpected, headache-giving problems. To solve this several solutions have been adopted; but in order to use them, it is recommendable to plan before installing. Here, I will review the main options for installing Python in your system, reviewing the advantages of each one.

Vanilla Python

The most obvious option is using the default distribution of Python, that can be downloaded from The default distribution of Python includes a package manager (pip) that can handle most (but not all) of the main libraries. Installing a new library is as simple as pip install package. pip automatically resolves the dependencies. An alternative is manually installing the libraries. Most of them are packaged with a default installer that does not resolve dependencies. The biggest advantage of this method is a generic install that can be more easily troubleshooted, on the cost of having to download separately (and painstakingly configure some of) the libraries that you need.

OS packages

Many operating systems (most of Linux distributions and OSX) either have Python already installed or have it included in the package manager (apt, yum, macports, etc) sources. Normally, many of the libraries are also provided as packages that can be added with the package manager. This configuration respects the software management of the OS, making it especially recommended on managed environments, and is often the easiest to set up; but the library versions may be outdated.

Commercial distributions
Under this category, I will include three distributions: Anaconda, made by Continuum and available for free; ActivePython, by ActiveState; and Enthough Canopy that has free and paid versions, made by Enthought (the paid versions include some additional libraries and access to documentation, and are free for academic use). These environments include most of the scientific libraries that you will need, along with Spyder (an environment for Python that is very similar to Matlab) and IPython (an advanced Python interpreter that includes the gorgeous Notebook). The scientific libraries are not always easy to install on vanilla Python, so a great advantage of these environments is that they are included from the beginning. Both environments also include pip to install external packages, although the vendors recommend to use their own package managers when possible. There are other commercial options, but these are the most used in the scientific community

Free distributions
Similarly to the commercial distributions, there are open source Python distributions: Python(xy) and WinPython (targeted specially at Windows). These distributions offer most of the advantages of their commercial counterparts, with the exception of the proprietary libraries and professional support that are exclusive of the paid versions

There is no absolute best option. If you are a purist, you may want to install the vanilla version, or use the OS default installed Python. If you want a headache free experience, the commercial or free distributions may be the way to go. If you are ready to spend some money (or are part of academia), have a look on what the paid versions offer; you may find some libraries really useful, and very valuable documentation and courses. For more information on Python distributions, have a look at the official documentation.

Leave a Reply

Your email address will not be published. Required fields are marked *