added windows support for main2.py thanks to lorenzo