2

I've tried bundling my application with PyInstaller and CxFreeze but both gave me lots of issues. I think this might be caused by the fact that I'm using lots of libraries such as TF, Keras, Pandas, Pillow, OpenCV, etc..

Is there any other option for bundling my python app? I do not need to distribute it, I just need to bring it to school to show it to my professor without having to install python or any other library.

I thought of making a USB with a virtualenv on it, and install all the necessary libraries but then, when I try to run the script, it complains about lots of missing files from the standard library that virtualenv didn't copy. So I have to go to my Python installation folder and copy those to the venv, which seems kind of ugly.

Is there a better option?

EDIT: PortablePython is not an option because it's not Python3 compatible and because it's discontinued

Elia Perantoni
  • 581
  • 1
  • 6
  • 19
  • If you are already using conda packages, I have found constructor to be quite useful. – Jaime Rodríguez-Guerra May 13 '18 at 11:42
  • 1
    @Simon yes, I’m very sure. Look closely at the top answer there; it’s none of the ones the OP has named here. Portable Python is designed specifically for this use case; to be able to run Python stand-alone from a USB stick. – Martijn Pieters May 13 '18 at 14:22
  • @MartijnPieters Ah I see, yes you were correct – Xantium May 13 '18 at 14:25
  • @MartijnPieters It's not being developed anymore, it's a closed project. – Elia Perantoni May 13 '18 at 17:03
  • Generally speaking: unless your professor runs Windows machines only, they will have access to Python. Otherwise, get yourself a PythonAnywhere account and run your code there, or run it on ideone or similar online environments. – Martijn Pieters May 13 '18 at 17:27
  • We have Windows machines and can't use PythonAnywhere or IdeOne because my program needs to comunicate with another process via udp – Elia Perantoni May 13 '18 at 17:34

0 Answers0