Call compiled Julia function from Python

Creating a C-callable function and using PkgCompiler might be the best option. One advantage of supplying a dynamically linkable library is that people are used them; it won’t scare them away. But, it’s not a lean library. It still contains the Julia runtime (although in recent development versions of Julia you can get rid of the compiler, if I’m not mistaken)

There is also the python module juliacall. You can make this a python dependency that you can pip-install. It will automatically download and install Julia if it’s not detected in the user’s path. You could perhaps use the jill python library to roll your own installer for your project and use either juliacall or pyjulia.

2 Likes