Change script to python