This script changes IP via Tor and clicks ads for a certain query on Google search. Tested with Firefox and Chrome.
Run the shell script to install dependencies and setup Tor
./ad_clicker_setup.sh
python ad_clicker.py -q <search query> [-b browser] [-t ad_visit_time_in_seconds]