Make "psms" tuple used for output a named tuple
Closed this issue · 1 comments
Primarily concerns model.py
and ms_io.py
.
Currently, how model output from model.py
is passed into ms_io.py
is confusing. ms_io.py
has a "psms" attribute that is appended to by on_predict_batch_end
. The below chunk of code is an example of how the "psms" tuple is appended to ms_io.py
currently.
Each of these fields should be given a name within a named tuple, and this named tuple should be used to pass information to ms_io.py
instead of how it is being done now.
Or rather a dataclass instead, for added flexibility.
I agree that this would be a good tweak to make the code easier to understand: define a Psm
dataclass that has attributes for the information needed for the mzTab export, create those objects during prediction, and ultimately write it to the output file.
@Lilferrit Can you look into tackling this?