|  | OpenMS
    2.6.0
    | 
 
 
  
  
 
Go to the documentation of this file.
   51 #include <boost/unordered_set.hpp> 
  179       current_step_ref_(processing_steps_.end())
 
  188       input_files_(std::move(other.input_files_)),
 
  189       processing_softwares_(std::move(other.processing_softwares_)),
 
  190       processing_steps_(std::move(other.processing_steps_)),
 
  191       db_search_params_(std::move(other.db_search_params_)),
 
  192       db_search_steps_(std::move(other.db_search_steps_)),
 
  193       score_types_(std::move(other.score_types_)),
 
  194       data_queries_(std::move(other.data_queries_)),
 
  195       parent_molecules_(std::move(other.parent_molecules_)),
 
  196       parent_molecule_groupings_(std::move(other.parent_molecule_groupings_)),
 
  197       identified_peptides_(std::move(other.identified_peptides_)),
 
  198       identified_compounds_(std::move(other.identified_compounds_)),
 
  199       identified_oligos_(std::move(other.identified_oligos_)),
 
  200       query_matches_(std::move(other.query_matches_)),
 
  201       query_match_groups_(std::move(other.query_match_groups_)),
 
  202       current_step_ref_(std::move(other.current_step_ref_)),
 
  204       data_query_lookup_(std::move(other.data_query_lookup_)),
 
  205       parent_molecule_lookup_(std::move(other.parent_molecule_lookup_)),
 
  206       identified_peptide_lookup_(std::move(other.identified_peptide_lookup_)),
 
  207       identified_compound_lookup_(std::move(other.identified_compound_lookup_)),
 
  208       identified_oligo_lookup_(std::move(other.identified_oligo_lookup_)),
 
  209       query_match_lookup_(std::move(other.query_match_lookup_))
 
  224       const DataProcessingSoftware& software);
 
  265     void registerParentMoleculeGrouping(
const ParentMoleculeGrouping& grouping);
 
  291     QueryMatchRef registerMoleculeQueryMatch(
const MoleculeQueryMatch& match);
 
  297     MatchGroupRef registerQueryMatchGroup(
const QueryMatchGroup& group);
 
  308       return processing_softwares_;
 
  314       return processing_steps_;
 
  320       return db_search_params_;
 
  326       return db_search_steps_;
 
  338       return data_queries_;
 
  344       return parent_molecules_;
 
  350       return parent_molecule_groupings_;
 
  356       return identified_peptides_;
 
  362       return identified_compounds_;
 
  368       return identified_oligos_;
 
  374       return query_matches_;
 
  380       return query_match_groups_;
 
  405     void clearCurrentProcessingStep();
 
  409     std::vector<QueryMatchRef> getBestMatchPerQuery(
ScoreTypeRef 
  416     std::pair<ScoreTypeRef, bool> findScoreType(
const String& score_name) 
const;
 
  419     void calculateCoverages(
bool check_molecule_length = 
false);
 
  432     void cleanup(
bool require_query_match = 
true,
 
  433                  bool require_identified_sequence = 
true,
 
  434                  bool require_parent_match = 
true,
 
  435                  bool require_parent_group = 
false,
 
  436                  bool require_match_group = 
false);
 
  441       if (higher_better) 
return first > second;
 
  442       return first < second;
 
  478     void checkScoreTypes_(
const std::map<ScoreTypeRef, double>& scores) 
const;
 
  482                                       steps_and_scores) 
const;
 
  493     template <
typename ElementType>
 
  503         element.addProcessingStep(step_ref);
 
  514     template <
typename ElementType>
 
  518         score_type_ref(score_type_ref), value(value)
 
  524         if (element.steps_and_scores.empty())
 
  526           element.addScore(score_type_ref, value);
 
  530           element.addScore(score_type_ref, value,
 
  531                            element.steps_and_scores.back().processing_step_opt);
 
  544     template <
typename ElementType>
 
  554         removeFromSetIf_(element.parent_matches,
 
  555                          [&](
const ParentMatches::iterator it)
 
  557                            return !lookup.count(it->first);
 
  566     template <
typename ContainerType, 
typename ElementType>
 
  568       ContainerType& container, 
const ElementType& element)
 
  570       checkAppliedProcessingSteps_(element.steps_and_scores);
 
  572       auto result = container.insert(element);
 
  575         container.modify(result.first, [&element](ElementType& existing)
 
  582       if (current_step_ref_ != processing_steps_.end())
 
  585           modifier(current_step_ref_);
 
  586         container.modify(result.first, modifier);
 
  593     template <
typename ContainerType, 
typename ElementType>
 
  595       ContainerType& container, 
const ElementType& element,
 
  598       typename ContainerType::iterator ref =
 
  599         insertIntoMultiIndex_(container, element);
 
  600       lookup.insert(uintptr_t(&(*ref)));
 
  605     template <
typename RefType, 
typename ContainerType>
 
  608       for (
auto it = container.begin(); it != container.end(); ++it)
 
  610         if (ref == it) 
return true;
 
  616     template <
typename RefType>
 
  620       return lookup.count(ref);
 
  624     template <
typename ContainerType, 
typename PredicateType>
 
  628       for (
auto it = container.begin(); it != container.end(); )
 
  632           it = container.erase(it);
 
  642     template <
typename ContainerType>
 
  646       removeFromSetIf_(container, [&lookup](
typename ContainerType::iterator it)
 
  648                          return !lookup.count(uintptr_t(&(*it)));
 
  653     template <
typename ContainerType>
 
  658       lookup.reserve(container.size());
 
  659       for (
const auto& element : container)
 
  661         lookup.insert(uintptr_t(&element));
 
  
MoleculeQueryMatches query_matches_
Definition: IdentificationData.h:462
AddressLookup parent_molecule_lookup_
Definition: IdentificationData.h:470
IdentificationDataInternal::ParentMoleculeGroupings ParentMoleculeGroupings
Definition: IdentificationData.h:172
IdentifiedSequence< NASequence > IdentifiedOligo
Definition: IdentifiedSequence.h:107
MoleculeType
Definition: MetaData.h:63
MassType
Definition: MetaData.h:72
IteratorWrapper< DataProcessingSteps::iterator > ProcessingStepRef
Definition: DataProcessingStep.h:93
DBSearchSteps db_search_steps_
Definition: IdentificationData.h:454
ProcessingStepRef current_step_ref_
Reference to the current data processing step (see setCurrentProcessingStep())
Definition: IdentificationData.h:466
IdentificationDataInternal::QueryMatchGroups QueryMatchGroups
Definition: IdentificationData.h:162
IdentifiedSequence< AASequence > IdentifiedPeptide
Definition: IdentifiedSequence.h:106
IdentificationDataInternal::IdentifiedPeptides IdentifiedPeptides
Definition: IdentificationData.h:137
IteratorWrapper< ParentMolecules::iterator > ParentMoleculeRef
Definition: ParentMolecule.h:100
IdentificationDataInternal::AppliedProcessingSteps AppliedProcessingSteps
Definition: IdentificationData.h:123
static bool isValidReference_(RefType ref, ContainerType &container)
Check whether a reference points to an element in a container.
Definition: IdentificationData.h:606
boost::multi_index_container< ParentMoleculeGroup, boost::multi_index::indexed_by< boost::multi_index::ordered_unique< boost::multi_index::member< ParentMoleculeGroup, std::set< ParentMoleculeRef >, &ParentMoleculeGroup::parent_molecule_refs > > > > ParentMoleculeGroups
Definition: ParentMoleculeGroup.h:64
IteratorWrapper< DataProcessingSoftwares::iterator > ProcessingSoftwareRef
Definition: DataProcessingSoftware.h:69
AddressLookup data_query_lookup_
Definition: IdentificationData.h:469
AddressLookup query_match_lookup_
Definition: IdentificationData.h:475
DataQueries data_queries_
Definition: IdentificationData.h:456
const ParentMolecules & getParentMolecules() const
Return the registered parent molecules (immutable)
Definition: IdentificationData.h:342
boost::multi_index_container< ParentMolecule, boost::multi_index::indexed_by< boost::multi_index::ordered_unique< boost::multi_index::member< ParentMolecule, String, &ParentMolecule::accession > > > > ParentMolecules
Definition: ParentMolecule.h:99
A more convenient string class.
Definition: String.h:59
IdentificationDataInternal::ParentMolecules ParentMolecules
Definition: IdentificationData.h:130
std::set< DBSearchParam > DBSearchParams
Definition: DBSearchParam.h:126
Helper functor for adding processing steps to elements in a boost::multi_index_container structure.
Definition: IdentificationData.h:494
boost::multi_index_container< IdentifiedOligo, boost::multi_index::indexed_by< boost::multi_index::ordered_unique< boost::multi_index::member< IdentifiedOligo, NASequence, &IdentifiedOligo::sequence > > > > IdentifiedOligos
Definition: IdentifiedSequence.h:124
ContainerType::iterator insertIntoMultiIndex_(ContainerType &container, const ElementType &element)
Helper function for adding entries (derived from ScoredProcessingResult) to a boost::multi_index_cont...
Definition: IdentificationData.h:567
ScoreTypeRef score_type_ref
Definition: IdentificationData.h:535
AddressLookup identified_oligo_lookup_
Definition: IdentificationData.h:474
const MoleculeQueryMatches & getMoleculeQueryMatches() const
Return the registered molecule-query matches (immutable)
Definition: IdentificationData.h:372
IteratorWrapper< ParentMoleculeGroups::iterator > ParentGroupRef
Definition: ParentMoleculeGroup.h:65
IdentificationDataInternal::DBSearchParams DBSearchParams
Definition: IdentificationData.h:112
const AddressLookup & lookup
Definition: IdentificationData.h:561
ModifyMultiIndexAddProcessingStep(ProcessingStepRef step_ref)
Definition: IdentificationData.h:496
const ParentMoleculeGroupings & getParentMoleculeGroupings() const
Return the registered parent molecule groupings (immutable)
Definition: IdentificationData.h:348
Information about a score type.
Definition: ScoreType.h:45
const InputFiles & getInputFiles() const
Return the registered input files (immutable)
Definition: IdentificationData.h:300
Information about software used for data processing.
Definition: DataProcessingSoftware.h:49
static void removeFromSetIfNotHashed_(ContainerType &container, const AddressLookup &lookup)
Remove elements from a set (or ordered multi_index_container) if they don't occur in a look-up table.
Definition: IdentificationData.h:643
IdentificationDataInternal::PeakAnnotations PeakAnnotations
Definition: IdentificationData.h:150
IdentificationDataInternal::InputFiles InputFiles
Definition: IdentificationData.h:97
std::set< DataProcessingStep > DataProcessingSteps
Definition: DataProcessingStep.h:92
IdentificationDataInternal::MoleculeQueryMatches MoleculeQueryMatches
Definition: IdentificationData.h:156
Parameters specific to a database search step.
Definition: DBSearchParam.h:47
IteratorWrapper< MoleculeQueryMatches::iterator > QueryMatchRef
Definition: MoleculeQueryMatch.h:164
IdentifiedCompounds identified_compounds_
Definition: IdentificationData.h:460
double value
Definition: IdentificationData.h:536
ScoreTypes score_types_
Definition: IdentificationData.h:455
void operator()(ElementType &element)
Definition: IdentificationData.h:501
ModifyMultiIndexRemoveParentMatches(const AddressLookup &lookup)
Definition: IdentificationData.h:547
IdentificationData(IdentificationData &&other)
Move constructor.
Definition: IdentificationData.h:187
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:46
IteratorWrapper< DBSearchParams::iterator > SearchParamRef
Definition: DBSearchParam.h:127
const DBSearchParams & getDBSearchParams() const
Return the registered database search parameters (immutable)
Definition: IdentificationData.h:318
static void updateAddressLookup_(const ContainerType &container, AddressLookup &lookup)
Recreate the address look-up table for a container.
Definition: IdentificationData.h:654
std::vector< PeptideHit::PeakAnnotation > PeakAnnotations
Definition: MoleculeQueryMatch.h:52
boost::multi_index_container< QueryMatchGroup, boost::multi_index::indexed_by< boost::multi_index::ordered_unique< boost::multi_index::member< QueryMatchGroup, std::set< QueryMatchRef >, &QueryMatchGroup::query_match_refs > > > > QueryMatchGroups
Definition: QueryMatchGroup.h:99
IteratorWrapper< IdentifiedOligos::iterator > IdentifiedOligoRef
Definition: IdentifiedSequence.h:125
ModifyMultiIndexAddScore(ScoreTypeRef score_type_ref, double value)
Definition: IdentificationData.h:517
std::map< ProcessingStepRef, SearchParamRef > DBSearchSteps
Definition: DBSearchParam.h:128
ParentMolecules parent_molecules_
Definition: IdentificationData.h:457
DataProcessingSoftwares processing_softwares_
Definition: IdentificationData.h:449
std::set< DataProcessingSoftware > DataProcessingSoftwares
Definition: DataProcessingSoftware.h:68
std::vector< ParentMoleculeGrouping > ParentMoleculeGroupings
Definition: ParentMoleculeGroup.h:75
InputFiles input_files_
Definition: IdentificationData.h:448
Helper functor for adding scores to elements in a boost::multi_index_container structure.
Definition: IdentificationData.h:515
static void removeFromSetIf_(ContainerType &container, PredicateType predicate)
Remove elements from a set (or ordered multi_index_container) if they fulfill a predicate.
Definition: IdentificationData.h:626
: Group of ambiguously identified parent molecules (e.g. protein group)
Definition: ParentMoleculeGroup.h:50
IdentificationDataInternal::ParentMatches ParentMatches
Definition: IdentificationData.h:134
IdentifiedPeptides identified_peptides_
Definition: IdentificationData.h:459
const DataQueries & getDataQueries() const
Return the registered data queries (immutable)
Definition: IdentificationData.h:336
Collection of functions for filtering peptide and protein identifications.
Definition: IDFilter.h:77
Wrapper that adds operator< to iterators, so they can be used as (part of) keys in maps/sets or multi...
Definition: MetaData.h:43
IdentificationDataInternal::ParentMoleculeGroups ParentMoleculeGroups
Definition: IdentificationData.h:167
ParentMoleculeGroupings parent_molecule_groupings_
Definition: IdentificationData.h:458
Search query, e.g. spectrum or feature.
Definition: DataQuery.h:47
IdentifiedOligos identified_oligos_
Definition: IdentificationData.h:461
std::set< String > InputFiles
Definition: MetaData.h:79
const IdentifiedCompounds & getIdentifiedCompounds() const
Return the registered compounds (immutable)
Definition: IdentificationData.h:360
IdentificationDataInternal::DataProcessingSoftwares DataProcessingSoftwares
Definition: IdentificationData.h:103
IdentificationDataInternal::IdentifiedOligos IdentifiedOligos
Definition: IdentificationData.h:147
ContainerType::iterator insertIntoMultiIndex_(ContainerType &container, const ElementType &element, AddressLookup &lookup)
Variant of insertIntoMultiIndex_() that also updates a look-up table of valid references (addresses)
Definition: IdentificationData.h:594
Meta data for a search hit (e.g. peptide-spectrum match).
Definition: MoleculeQueryMatch.h:61
boost::variant< IdentifiedPeptideRef, IdentifiedCompoundRef, IdentifiedOligoRef > IdentifiedMoleculeRef
Definition: MoleculeQueryMatch.h:57
boost::multi_index_container< MoleculeQueryMatch, boost::multi_index::indexed_by< boost::multi_index::ordered_unique< boost::multi_index::composite_key< MoleculeQueryMatch, boost::multi_index::member< MoleculeQueryMatch, DataQueryRef, &MoleculeQueryMatch::data_query_ref >, boost::multi_index::member< MoleculeQueryMatch, IdentifiedMoleculeRef, &MoleculeQueryMatch::identified_molecule_ref > > > > > MoleculeQueryMatches
Definition: MoleculeQueryMatch.h:163
const DataProcessingSteps & getDataProcessingSteps() const
Return the registered data processing steps (immutable)
Definition: IdentificationData.h:312
const DataProcessingSoftwares & getDataProcessingSoftwares() const
Return the registered data processing software (immutable)
Definition: IdentificationData.h:306
const DBSearchSteps & getDBSearchSteps() const
Return the registered database search steps (immutable)
Definition: IdentificationData.h:324
DataProcessingSteps processing_steps_
Definition: IdentificationData.h:450
Representation of a parent molecule that is identified only indirectly (e.g. a protein).
Definition: ParentMolecule.h:49
IdentificationDataInternal::DataProcessingSteps DataProcessingSteps
Definition: IdentificationData.h:108
ProcessingStepRef step_ref
Definition: IdentificationData.h:506
IdentificationDataInternal::IdentifiedCompounds IdentifiedCompounds
Definition: IdentificationData.h:142
A processing step that was applied to a data item, possibly with associated scores.
Definition: AppliedProcessingStep.h:52
const ScoreTypes & getScoreTypes() const
Return the registered score types (immutable)
Definition: IdentificationData.h:330
DBSearchParams db_search_params_
Definition: IdentificationData.h:451
const QueryMatchGroups & getQueryMatchGroups() const
Return the registered groups of molecule-query matches (immutable)
Definition: IdentificationData.h:378
QueryMatchGroups query_match_groups_
Definition: IdentificationData.h:463
IteratorWrapper< InputFiles::iterator > InputFileRef
Definition: MetaData.h:80
boost::multi_index_container< AppliedProcessingStep, boost::multi_index::indexed_by< boost::multi_index::sequenced<>, boost::multi_index::ordered_unique< boost::multi_index::member< AppliedProcessingStep, boost::optional< ProcessingStepRef >, &AppliedProcessingStep::processing_step_opt > > > > AppliedProcessingSteps
Definition: AppliedProcessingStep.h:116
std::map< ParentMoleculeRef, std::set< MoleculeParentMatch > > ParentMatches
mapping: parent molecule -> match information
Definition: MoleculeParentMatch.h:101
Representation of spectrum identification results and associated data.
Definition: IdentificationData.h:89
AddressLookup identified_peptide_lookup_
Definition: IdentificationData.h:472
Helper functor for removing invalid parent matches from elements in a boost::multi_index_container st...
Definition: IdentificationData.h:545
IdentificationData()
Default constructor.
Definition: IdentificationData.h:178
void operator()(ElementType &element)
Definition: IdentificationData.h:522
Identified sequence (peptide or oligonucleotide)
Definition: IdentifiedSequence.h:52
std::set< ScoreType > ScoreTypes
Definition: ScoreType.h:85
boost::unordered_set< uintptr_t > AddressLookup
Definition: IdentificationData.h:174
void operator()(ElementType &element)
Definition: IdentificationData.h:552
const IdentifiedOligos & getIdentifiedOligos() const
Return the registered identified oligonucleotides (immutable)
Definition: IdentificationData.h:366
IdentificationDataInternal::IdentifiedMoleculeRef IdentifiedMoleculeRef
Definition: IdentificationData.h:152
Meta data for the association between an identified molecule (e.g. peptide) and a parent molecule (e....
Definition: MoleculeParentMatch.h:45
AddressLookup identified_compound_lookup_
Definition: IdentificationData.h:473
Data processing step that is applied to the data (e.g. database search, PEP calculation,...
Definition: DataProcessingStep.h:46
IteratorWrapper< DataQueries::iterator > DataQueryRef
Definition: DataQuery.h:90
static bool isBetterScore(double first, double second, bool higher_better)
Helper function to compare two scores.
Definition: IdentificationData.h:439
Set of groups of ambiguously identified parent molecules (e.g. results of running a protein inference...
Definition: ParentMoleculeGroup.h:69
boost::multi_index_container< IdentifiedPeptide, boost::multi_index::indexed_by< boost::multi_index::ordered_unique< boost::multi_index::member< IdentifiedPeptide, AASequence, &IdentifiedPeptide::sequence > > > > IdentifiedPeptides
Definition: IdentifiedSequence.h:115
std::set< DataQuery > DataQueries
Definition: DataQuery.h:89
static bool isValidHashedReference_(RefType ref, const AddressLookup &lookup)
Check validity of a reference based on a look-up table of addresses.
Definition: IdentificationData.h:617
IteratorWrapper< QueryMatchGroups::iterator > MatchGroupRef
Definition: QueryMatchGroup.h:100
const IdentifiedPeptides & getIdentifiedPeptides() const
Return the registered identified peptides (immutable)
Definition: IdentificationData.h:354
IdentificationDataInternal::DataQueries DataQueries
Definition: IdentificationData.h:126
boost::multi_index_container< IdentifiedCompound, boost::multi_index::indexed_by< boost::multi_index::ordered_unique< boost::multi_index::member< IdentifiedCompound, String, &IdentifiedCompound::identifier > > > > IdentifiedCompounds
Definition: IdentifiedCompound.h:79
Definition: IdentifiedCompound.h:47
IdentificationDataInternal::DBSearchSteps DBSearchSteps
Definition: IdentificationData.h:114
: Group of related (co-identified) molecule-query matches
Definition: QueryMatchGroup.h:50
IteratorWrapper< IdentifiedPeptides::iterator > IdentifiedPeptideRef
Definition: IdentifiedSequence.h:116
IteratorWrapper< IdentifiedCompounds::iterator > IdentifiedCompoundRef
Definition: IdentifiedCompound.h:80
IteratorWrapper< ScoreTypes::iterator > ScoreTypeRef
Definition: ScoreType.h:86
IdentificationDataInternal::ScoreTypes ScoreTypes
Definition: IdentificationData.h:117