OpenMS
FeatureFinder.h
Go to the documentation of this file.
1 // Copyright (c) 2002-2023, The OpenMS Team -- EKU Tuebingen, ETH Zurich, and FU Berlin
2 // SPDX-License-Identifier: BSD-3-Clause
3 //
4 // --------------------------------------------------------------------------
5 // $Maintainer: Timo Sachsenberg $
6 // $Authors: Marc Sturm, Clemens Groepl $
7 // --------------------------------------------------------------------------
8 
9 #pragma once
10 
16 
17 namespace OpenMS
18 {
19 
30  class OPENMS_DLLAPI FeatureFinder :
31  public ProgressLogger,
32  public FeatureFinderDefs
33  {
34 
35 public:
38 
40  ~FeatureFinder() override;
41 
60  void run(const String& algorithm_name, PeakMap& input_map, FeatureMap& features, const Param& param, const FeatureMap& seeds);
61 
63  const Flag& getPeakFlag(const IndexPair& index) const
64  {
65  return flags_[index.first][index.second];
66  }
67 
69  Flag& getPeakFlag(const IndexPair& index)
70  {
71  return flags_[index.first][index.second];
72  }
73 
75  Param getParameters(const String& algorithm_name) const;
76 
77 protected:
78 
80  std::vector<std::vector<Flag> > flags_;
81 
82  }; // class FeatureFinder
83 
84 } // namespace OpenMS
85 
The main feature finder class.
Definition: FeatureFinder.h:33
~FeatureFinder() override
Destructor.
const Flag & getPeakFlag(const IndexPair &index) const
Returns a non-mutable reference to a peak flag.
Definition: FeatureFinder.h:63
FeatureFinder()
Default constructor.
void run(const String &algorithm_name, PeakMap &input_map, FeatureMap &features, const Param &param, const FeatureMap &seeds)
Executes the FeatureFinder using the given algorithm.
std::vector< std::vector< Flag > > flags_
Container for flags attached to input data.
Definition: FeatureFinder.h:80
Param getParameters(const String &algorithm_name) const
Returns the default parameters for the algorithm with name algorithm_name.
Flag & getPeakFlag(const IndexPair &index)
Returns mutable reference to a peak flag.
Definition: FeatureFinder.h:69
A container for features.
Definition: FeatureMap.h:80
In-Memory representation of a mass spectrometry run.
Definition: MSExperiment.h:46
Management and storage of parameters / INI files.
Definition: Param.h:44
Base class for all classes that want to report their progress.
Definition: ProgressLogger.h:27
A more convenient string class.
Definition: String.h:34
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:22
The purpose of this struct is to provide definitions of classes and typedefs which are used throughou...
Definition: FeatureFinderDefs.h:25
Flag
Flags that indicate if a peak is already used in a feature.
Definition: FeatureFinderDefs.h:36
IsotopeCluster::IndexPair IndexPair
Index to peak consisting of two UInts (scan index / peak index)
Definition: FeatureFinderDefs.h:27