Python Multithreaded Tor Script (Algorithm)