Codon Looks Very Promising For Super-Fast Python Code
While there is Pyston, PyPy, and various other alternative Python implementations being done in the name of performance, Codon is one of the newer ones and is talking up 10~100x faster performance.
Codon was started by MIT researchers with an aim of delivering C/C++ like performance out of Python. Even with real-world genomics code that's been hand optimized, with Codon the researchers were seeing 5~10x speed-ups. Codon also supports a parallel back-end to support targeting GPUs or multiple CPU cores.
There is more background information on Codon available from news.mit.edu.
The code to Codon is made public under a Business Source License and can be found on GitHub. The project does acknowledge though that it may not work as a drop-in replacement yet among other limitations:
More details on this Python implementation can also be found via Exaloop.io. It should be interesting for benchmarking Codon against Python 3.11 considering its recent upstream performance optimizations as well as seeing how it stacks up against some of the other performance-optimized Python implementations.
Codon was started by MIT researchers with an aim of delivering C/C++ like performance out of Python. Even with real-world genomics code that's been hand optimized, with Codon the researchers were seeing 5~10x speed-ups. Codon also supports a parallel back-end to support targeting GPUs or multiple CPU cores.
There is more background information on Codon available from news.mit.edu.
The code to Codon is made public under a Business Source License and can be found on GitHub. The project does acknowledge though that it may not work as a drop-in replacement yet among other limitations:
"While Codon supports nearly all of Python's syntax, it is not a drop-in replacement, and large codebases might require modifications to be run through the Codon compiler. For example, some of Python's modules are not yet implemented within Codon, and a few of Python's dynamic features are disallowed. The Codon compiler produces detailed error messages to help identify and resolve any incompatibilities."
More details on this Python implementation can also be found via Exaloop.io. It should be interesting for benchmarking Codon against Python 3.11 considering its recent upstream performance optimizations as well as seeing how it stacks up against some of the other performance-optimized Python implementations.
34 Comments