1

After successfully generating C code from Python using Cython and compiling this C code to exe I need to compile this code with Python dependencies (e.g Numpy). To generate C code I'm using

cython.exe test.py --embed -3

Then compiling this C code to exe using MSVC but when I run file I get error

Traceback (most recent call last):
  File "test.py", line 1, in init test
    import numpy
ModuleNotFoundError: No module named 'numpy'
kacpo1
  • 21
  • 1
  • 2
  • Not really. What I meant is to compile all dependencies with actual code to single exe and not to use any external packages. – kacpo1 Feb 05 '21 at 14:14
  • Cython isn't designed for that. You won't get it to work. Especially not with complicated packages like Numpy. Use some other tool. (I can't find the relevant duplicate right now, but there is one) – DavidW Feb 05 '21 at 14:30

0 Answers0