finalizing py script