OpenMS
Loading...
Searching...
No Matches
TransitionListEvidenceFilter.h
Go to the documentation of this file.
1// Copyright (c) 2002-present, OpenMS Inc. -- EKU Tuebingen, ETH Zurich, and FU Berlin
2// SPDX-License-Identifier: BSD-3-Clause
3//
4// --------------------------------------------------------------------------
5// $Maintainer: Justin Sing $
6// $Authors: Justin Sing $
7// --------------------------------------------------------------------------
8
9#pragma once
10
17
18#include <string>
19#include <vector>
20
21namespace OpenMS
22{
35 class OPENMS_DLLAPI TransitionListEvidenceFilter :
37 public ProgressLogger
38 {
39public:
42 {
44 std::string compound_id;
46 std::string sequence;
48 double precursor_mz{0.0};
50 double precursor_im{-1.0};
52 bool supported_ms1{false};
54 bool supported_ms2{false};
56 Size ms1_hit_count{0};
58 double ms1_max_intensity{0.0};
60 double ms1_sum_intensity{0.0};
62 double ms1_best_rt{-1.0};
64 Size ms2_hit_count{0};
66 Size ms2_best_fragment_hits{0};
68 double ms2_max_intensity{0.0};
70 double ms2_sum_intensity{0.0};
72 double ms2_best_rt{-1.0};
73 };
74
76 struct Result
77 {
81 std::vector<PrecursorEvidence> evidence;
83 Size total_target_precursors{0};
85 Size supported_precursors{0};
87 Size ms1_supported{0};
89 Size ms2_supported{0};
91 Size hybrid_supported{0};
93 std::string summary;
95 double precursor_im_scale{1.0};
97 bool precursor_im_scaled_by_charge{false};
98 };
99
105
107 ~TransitionListEvidenceFilter() override = default;
109
111 void updateMembers_() override;
112
126 Result filter(const std::vector<OpenSwath::SwathMap>& swath_maps,
127 const OpenSwath::LightTargetedExperiment& transition_exp,
128 const ChromExtractParams& ms1_params,
129 const ChromExtractParams& ms2_params,
130 bool pasef,
131 int threads = 1) const;
132
133private:
134 bool enabled_{false};
135 std::string evidence_sources_{"hybrid"};
136 Size ms1_top_peaks_per_spectrum_{1000};
137 Size ms2_top_peaks_per_spectrum_{1000};
138 Size ms2_top_transitions_per_precursor_{6};
139 Size ms2_min_fragment_hits_{4};
140 Size min_supported_precursors_{3};
141 bool peak_picking_enabled_{false};
142 bool peak_picking_use_gauss_{true};
143 };
144}
A base class for all classes handling default parameters.
Definition DefaultParamHandler.h:66
Base class for all classes that want to report their progress.
Definition ProgressLogger.h:27
Prefilter transition-library precursors by quick raw-data evidence.
Definition TransitionListEvidenceFilter.h:38
TransitionListEvidenceFilter()
Default constructor.
~TransitionListEvidenceFilter() override=default
Destructor.
std::string summary
Human-readable summary for logging.
Definition TransitionListEvidenceFilter.h:93
std::vector< PrecursorEvidence > evidence
Per-candidate evidence, in the same order as the internal target candidates.
Definition TransitionListEvidenceFilter.h:81
std::string sequence
Peptide sequence, if present in the transition experiment.
Definition TransitionListEvidenceFilter.h:46
OpenSwath::LightTargetedExperiment filtered_targets
Target-only filtered transition experiment for auto-iRT sampling.
Definition TransitionListEvidenceFilter.h:79
Result filter(const std::vector< OpenSwath::SwathMap > &swath_maps, const OpenSwath::LightTargetedExperiment &transition_exp, const ChromExtractParams &ms1_params, const ChromExtractParams &ms2_params, bool pasef, int threads=1) const
Filter target precursors by MS1/MS2 evidence observed in the current run.
void updateMembers_() override
Synchronize members with the parameter object.
std::string compound_id
Compound/peptide identifier in the transition experiment.
Definition TransitionListEvidenceFilter.h:44
Compact evidence summary for one target precursor candidate.
Definition TransitionListEvidenceFilter.h:42
Result of filtering one run against one transition experiment.
Definition TransitionListEvidenceFilter.h:77
size_t Size
Size type e.g. used as variable which can hold result of size()
Definition Types.h:97
Main OpenMS namespace.
Definition openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19
ChromatogramExtractor parameters.
Definition OpenSwathWorkflow.h:54
Definition TransitionExperiment.h:369