Tweaking the Python (mostly)

Fixed the majority of the Python scripts to bring them into line with PEP8, but there are still a handful of long lines scattered throughout.  A couple of minor text file tweaks.

The requirements.txt files might be better served bymerging them, but left them separate now (one of them is new and the other is in api/).