command line parsing in python, useful for parallelizing stuff on multicore machines