I'm trying to do some machine learning learning on a sequencing dataset that involves special characters and Greek alphabet. and it keeps throwing errors. Every single time I run the script it throws an error from different position.
file = open(filename,encoding="utf-8")
for record in SeqIO.parse(file,"fasta"):
print("ID %s" % record.id)
print("Sequence length %i" % len(record))
UnicodeEncodeError: 'ascii' codec can't encode character '\u0394' in position 2635: ordinal not in range(128)