一、安装pyinstaller
pip install pyinstaller
二、编译:
pyinstaller facedetectandsaveimage.py
结果:
自动生成"C:\Users\username\dist\FaceDetectAndSaveImage"文件夹和相关文件(包括exe文件)
注意:
python源码中尽量不要包含中文,否则需要附加另外的文件。
一、安装pyinstaller
pip install pyinstaller
二、编译:
pyinstaller facedetectandsaveimage.py
结果:
自动生成"C:\Users\username\dist\FaceDetectAndSaveImage"文件夹和相关文件(包括exe文件)
注意:
python源码中尽量不要包含中文,否则需要附加另外的文件。
编译python源代码为可执行文件(.py--->.exe)
原文:https://www.cnblogs.com/windel/p/8372077.html