exe = EXE(pyz, a.scripts, a.binaries, a.zipfiles, a.datas, name='main',
    debug=False, strip=False, upx=True, console=True)
Getting rid of console output when freezing Python programs using Pyinstaller