Fixed some minor ones in generate.py