Cython is actually based on the well-known Pyrex, but it also comes with support for more cutting edge optimizations and functionality.
The Cython language is very close to the Python language, but Cython additionally supports calling C functions and declaring C types on variables and class attributes. This allows the compiler to generate very efficient C code from Cython code.
This makes Cython the ideal language for wrapping for external C libraries, and for fast C modules that speed up the execution of Python code.
Here are some key features of "Cython":
· Cython gives you the combined power of Python and C to let you
· write Python code that calls back and forth from and to C or C++ code natively at any point.
· easily tune readable Python code into plain C performance by adding static type declarations.
· use combined source code level debugging to find bugs in your Python, Cython and C code.
· interact efficiently with large data sets, e.g. using multi-dimensional NumPy arrays.
· quickly build your applications within the large, mature and widely used CPython ecosystem.
· integrate natively with existing code and data in legacy, low-level or high-performance applications and libraries.
What's New in This Release: [ read full changelog ]
· A reference leak was fixed in the new dict iteration code when the loop target was not a plain variable but an unpacked tuple.
· Memory views did not handle the special case of a NULL buffer strides value, as allowed by PEP3118.