Skip to content

Commit

Permalink
Update ms2rescore.py
Browse files Browse the repository at this point in the history
  • Loading branch information
daichengxin committed Dec 22, 2024
1 parent 3e8457f commit 1f665cf
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions quantmsrescore/ms2rescore.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ def __iter__(self) -> Iterable[PSM]:
yield psm
else:
self.skip_invalid_psm += 1
# If it is a valid Peptide Hits then keep it
if len(new_hits) > 0:
peptide_id.setHits(new_hits)
self.new_peptide_ids.append(peptide_id)
Expand Down Expand Up @@ -245,6 +246,7 @@ def rescore_idxml(input_file, output_file, config) -> None:
logging.warning(
f"Removed {reader.skip_invalid_psm} PSMs without search engine features!"
)
# Synchronised acquisition of new peptide IDs after removing invalid PSMs
peptide_ids = reader.new_peptide_ids
else:
peptide_ids = reader.peptide_ids
Expand Down

0 comments on commit 1f665cf

Please sign in to comment.