解决PyInstaller打包的EXE内存爆满的问题

问题描述:

使用PyInstaller打包Python程序,在运行exe文件时,出现内存爆满,

问题原因:

在Python程序中包含了多进程或多线程代码

例如Pool()进程池

解决方法:

引入freeze_support


from multiprocessingimport freeze_support

if __name__ =='__main__':

    freeze_support()

方案出处:

https://blog.csdn.net/xiong_big/article/details/54614231

你可能感兴趣的:(解决PyInstaller打包的EXE内存爆满的问题)