def run_command(cmd, sin, sout):
    print('Running cmd : %s' % ' '.join(cmd))
return subprocess.call(cmd, stdin=sin, stdout=sout, startupinfo=startupinfo)
How to avoid console window with .pyw file containing os.system call?