upvote
Cython is a no-brainer really. You write the same language with immense speedup (matching what the "other languages" can achieve at much less effort).

Also tools like numba can beat them all at way less effort.

Imho, dropping into other languages should be the last resort in any project.

reply
Mojo aims to be this (other language) arguably with easier programming model that rust, familiar syntax to python devs, and a modern design in general. Its stated goal now, is the easiest way to extend python. it provides the same interface for zero-hassle import of .mojo files
reply
Cython and PyBind and Nanobind are good for wrapping an existing library written in C++ and crafting an interface that doesn’t feel like it’s a C++ one. They were a big step from ctypes and SWIG
reply
Plus, even if it has a Perl like feeling to it, C++26 reflection will make this even easier.

Already available on GCC 16.

reply
> If more than a few percent of execution time is spent in Python you are probably doing it wrong.

Every program that starts with 1% of Python writes more Python and gets to 20,40, 60 and than 99% of it.

reply