quick and dirty in py for 007. takes 3s to run