Parse text file to fasta using python class