Some fixes to parse_data.py