I have tried BioPython SeqIO and other parsers but couldn't find any good tool to parse DAT files.
https://omics.pnl.gov/software/uniprot-dat-file-parser
I have tried this one but they don't provide any gene annotations
http://biopython.org/wiki/SeqIO
They mostly talk about taking inputs of FASTA and not DAT file.
from Bio import SeqIO
for record in SeqIO.parse("Fasta/f002", "fasta"):
... print("%s %i" % (record.id, len(record)))
Those look like what Biopython calls
"swiss"format, the plain text format used at SwissProt prior to it being called UniProt. Try:See also the table for formats at http://biopython.org/wiki/SeqIO