tset.py reorganised.