Move code into T0_freqlist.py

...so we can clean up the tools directory