Intel’s Python distribution provides a major math boost
16 March 2016 | 0
Intel has been quietly offering pre-release access to its distribution of the Python language, which is outfitted with the Intel Math Kernel Library (MKL) for accelerated computational performance on Intel processors.
The Intel Distribution for Python Technical Preview supports Python 2.7 and 3.5 (beta 1), and it includes NumPy and SciPy, the popular math and statistical analysis packages that Intel has optimised with MKL.
The distribution’s main touted advantage is speed — but not a PyPy-style general speedup via a JIT. Instead, the MKL speeds up certain math operations so that they run faster on one thread and multiple threads. A set of benchmarks published by Intel claims that certain operations can run two to four times faster (on one thread) and 22 to 97 times faster (on 32 threads).
Another claimed advantage for Intel’s distribution is convenience; the Pandas, Matplotlib, IPython (the core of the Jupyter data-notebook project), Sympy, and NumExpr libraries are included with it, as are a host of other projects. Many are commonly used in conjunction with NumPy and SciPy. Linux and Windows are both supported in Intel’s distribution.
Installing Python is not typically problematic, but adding the welter of libraries commonly used for math and stats, especially on Windows systems, is not straightforward. Some distributions, such as Anaconda for Windows, pre-bundle many projects to cut down on the hassle of getting up and running on them.
Intel’s distribution takes the same tack, but can also install any needed third-party packages with Python’s Pip package manager. However, it is likely that only the packages bundled with the distribution will have native Intel MKL support.
According to the release notes, most of the known issues for Intel’s Python distribution revolve around it failing various unit tests — not in itself a sign that applications running on the distribution will fail, but it hints that the project isn’t ready for prime time. Among the packages that fail is Cython, a project used to transform Python code into C modules — which could in time benefit from closer integration with Intel MKL.
The Intel MKL previously gained attention when it was included as part of Revolution Analytics’ distribution of the R stats-and-math language. Microsoft bought the company and rechristened the product as Microsoft R Open, but said that support for the Intel MKL would remain.
Intel is also preparing a version of Intel VTune Amplifier XE with support for Python that is available now as an early-access beta. This application provides line-by-line analysis of Python applications to determine where a given app does most of its work and where optimisations will yield the best benefit, whether leveraging Intel MKL or not.
IDG News Service