libpappsomspp
Library for mass spectrometry
Toggle main menu visibility
Loading...
Searching...
No Matches
msrunxicextractorinterface.h
Go to the documentation of this file.
1
/**
2
* \file pappsomspp/xicextractor/msrunxicextractor.h
3
* \date 07/05/2018
4
* \author Olivier Langella
5
* \brief base interface to build XICs on an MsRun file
6
*/
7
8
/*******************************************************************************
9
* Copyright (c) 2018 Olivier Langella <Olivier.Langella@u-psud.fr>.
10
*
11
* This file is part of the PAPPSOms++ library.
12
*
13
* PAPPSOms++ is free software: you can redistribute it and/or modify
14
* it under the terms of the GNU General Public License as published by
15
* the Free Software Foundation, either version 3 of the License, or
16
* (at your option) any later version.
17
*
18
* PAPPSOms++ is distributed in the hope that it will be useful,
19
* but WITHOUT ANY WARRANTY; without even the implied warranty of
20
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21
* GNU General Public License for more details.
22
*
23
* You should have received a copy of the GNU General Public License
24
* along with PAPPSOms++. If not, see <http://www.gnu.org/licenses/>.
25
*
26
******************************************************************************/
27
28
#pragma once
29
30
31
#include "
pappsomspp/core/msrun/msrunreader.h
"
32
#include <memory>
33
#include <vector>
34
#include <limits>
35
#include "
pappsomspp/core/processing/uimonitor/uimonitorinterface.h
"
36
37
38
namespace
pappso
39
{
40
41
class
MsRunXicExtractorInterface
;
42
typedef
std::shared_ptr<MsRunXicExtractorInterface>
MsRunXicExtractorInterfaceSp
;
43
44
class
PMSPP_LIB_DECL
MsRunXicExtractorInterface
45
{
46
47
public
:
48
/** @brief set the XIC extraction method
49
*/
50
void
setXicExtractMethod
(
Enums::XicExtractMethod
method);
// sum or max
51
52
/** @brief set the retention time range in seconds around the target rt
53
*
54
* only the interesting part of the xic will be extracted, form the rt target
55
* - range_in_seconds to rt target + range in seconds by default, all the LC
56
* run time is extracted
57
*
58
* @param range_in_seconds range in seconds
59
*/
60
void
setRetentionTimeAroundTarget
(
double
range_in_seconds);
61
62
63
/** @brief extract a list of XIC given a list of xic coordinates to extract
64
*
65
* XicCoord is a vessel containing the xic to fill and coordinates of this XIC
66
* in the MS run
67
*
68
* @param monitor process monitoring
69
* @param xic_coord_list list of xic coordinates to extract. The order of xic
70
* coordinates may change.
71
*/
72
virtual
void
extractXicCoordSPtrList
(
UiMonitorInterface
&monitor,
73
std::vector<XicCoordSPtr> &xic_coord_list)
final
;
74
75
76
/** @brief multithreaded XIC extraction
77
*
78
* divide xic_coord_list and run extractXicCoordSPtrList separated threads
79
*
80
* @param monitor process monitoring
81
* @param xic_coord_list list of xic coordinates to extract. The order of xic
82
* coordinates may change.
83
*/
84
virtual
void
extractXicCoordSPtrListParallelized
(
UiMonitorInterface
&monitor,
85
std::vector<XicCoordSPtr> &xic_coord_list)
final
;
86
87
const
MsRunIdCstSPtr
&
getMsRunId
()
const
;
88
89
/** @brief get the msrunreader currently used for XIC extraction
90
*/
91
const
MsRunReaderSPtr
&
getMsRunReaderSPtr
()
const
;
92
93
/** @brief filter interface to apply just after XIC extration on each trace
94
*/
95
void
setPostExtractionTraceFilterCstSPtr
(
pappso::FilterInterfaceCstSPtr
&
filter
);
96
97
98
protected
:
99
/** @brief constructor is private, use the MsRunXicExtractorFactory
100
*/
101
MsRunXicExtractorInterface
(
MsRunReaderSPtr
&msrun_reader);
102
MsRunXicExtractorInterface
(
const
MsRunXicExtractorInterface
&other);
103
virtual
~MsRunXicExtractorInterface
();
104
105
/** @brief possible post extraction process, eventually trace filters
106
*/
107
virtual
void
postExtractionProcess
(
UiMonitorInterface
&monitor,
108
std::vector<XicCoordSPtr>::iterator it_xic_coord_list_begin,
109
std::vector<XicCoordSPtr>::iterator it_xic_coord_list_end);
110
111
virtual
void
112
protectedExtractXicCoordSPtrList
(
UiMonitorInterface
&monitor,
113
std::vector<XicCoordSPtr>::iterator it_xic_coord_list_begin,
114
std::vector<XicCoordSPtr>::iterator it_xic_coord_list_end) = 0;
115
116
117
protected
:
118
MsRunReaderSPtr
msp_msrun_reader
;
119
Enums::XicExtractMethod
m_xicExtractMethod
=
Enums::XicExtractMethod::max
;
120
double
m_retentionTimeAroundTarget
= std::numeric_limits<double>::max();
121
pappso::FilterInterfaceCstSPtr
mcsp_postExtractionTraceFilter
=
nullptr
;
122
};
123
124
125
}
// namespace pappso
pappso::MsRunXicExtractorInterface
Definition
msrunxicextractorinterface.h:45
pappso::MsRunXicExtractorInterface::extractXicCoordSPtrListParallelized
virtual void extractXicCoordSPtrListParallelized(UiMonitorInterface &monitor, std::vector< XicCoordSPtr > &xic_coord_list) final
multithreaded XIC extraction
Definition
msrunxicextractorinterface.cpp:89
pappso::MsRunXicExtractorInterface::m_retentionTimeAroundTarget
double m_retentionTimeAroundTarget
Definition
msrunxicextractorinterface.h:120
pappso::MsRunXicExtractorInterface::m_xicExtractMethod
Enums::XicExtractMethod m_xicExtractMethod
Definition
msrunxicextractorinterface.h:119
pappso::MsRunXicExtractorInterface::postExtractionProcess
virtual void postExtractionProcess(UiMonitorInterface &monitor, std::vector< XicCoordSPtr >::iterator it_xic_coord_list_begin, std::vector< XicCoordSPtr >::iterator it_xic_coord_list_end)
possible post extraction process, eventually trace filters
Definition
msrunxicextractorinterface.cpp:184
pappso::MsRunXicExtractorInterface::msp_msrun_reader
MsRunReaderSPtr msp_msrun_reader
Definition
msrunxicextractorinterface.h:118
pappso::MsRunXicExtractorInterface::setPostExtractionTraceFilterCstSPtr
void setPostExtractionTraceFilterCstSPtr(pappso::FilterInterfaceCstSPtr &filter)
filter interface to apply just after XIC extration on each trace
Definition
msrunxicextractorinterface.cpp:81
pappso::MsRunXicExtractorInterface::protectedExtractXicCoordSPtrList
virtual void protectedExtractXicCoordSPtrList(UiMonitorInterface &monitor, std::vector< XicCoordSPtr >::iterator it_xic_coord_list_begin, std::vector< XicCoordSPtr >::iterator it_xic_coord_list_end)=0
pappso::MsRunXicExtractorInterface::extractXicCoordSPtrList
virtual void extractXicCoordSPtrList(UiMonitorInterface &monitor, std::vector< XicCoordSPtr > &xic_coord_list) final
extract a list of XIC given a list of xic coordinates to extract
Definition
msrunxicextractorinterface.cpp:172
pappso::MsRunXicExtractorInterface::getMsRunReaderSPtr
const MsRunReaderSPtr & getMsRunReaderSPtr() const
get the msrunreader currently used for XIC extraction
Definition
msrunxicextractorinterface.cpp:75
pappso::MsRunXicExtractorInterface::setXicExtractMethod
void setXicExtractMethod(Enums::XicExtractMethod method)
set the XIC extraction method
Definition
msrunxicextractorinterface.cpp:57
pappso::MsRunXicExtractorInterface::getMsRunId
const MsRunIdCstSPtr & getMsRunId() const
Definition
msrunxicextractorinterface.cpp:69
pappso::MsRunXicExtractorInterface::setRetentionTimeAroundTarget
void setRetentionTimeAroundTarget(double range_in_seconds)
set the retention time range in seconds around the target rt
Definition
msrunxicextractorinterface.cpp:63
pappso::MsRunXicExtractorInterface::mcsp_postExtractionTraceFilter
pappso::FilterInterfaceCstSPtr mcsp_postExtractionTraceFilter
Definition
msrunxicextractorinterface.h:121
pappso::MsRunXicExtractorInterface::MsRunXicExtractorInterface
MsRunXicExtractorInterface(MsRunReaderSPtr &msrun_reader)
constructor is private, use the MsRunXicExtractorFactory
Definition
msrunxicextractorinterface.cpp:40
pappso::UiMonitorInterface
Definition
uimonitorinterface.h:50
PMSPP_LIB_DECL
#define PMSPP_LIB_DECL
Definition
export-import-config.h:14
msrunreader.h
pappso::Enums::XicExtractMethod
XicExtractMethod
Definition
types.h:264
pappso::Enums::XicExtractMethod::max
@ max
maximum of intensities
Definition
types.h:266
pappso
tries to keep as much as possible monoisotopes, removing any possible C13 peaks and changes multichar...
Definition
aa.cpp:39
pappso::MsRunReaderSPtr
std::shared_ptr< MsRunReader > MsRunReaderSPtr
Definition
msrunreader.h:57
pappso::ProjectParamCategory::filter
@ filter
concerning filters (psm, peptide, protein validation)
Definition
projectparameters.h:48
pappso::MsRunIdCstSPtr
std::shared_ptr< const MsRunId > MsRunIdCstSPtr
Definition
msrunid.h:46
pappso::FilterInterfaceCstSPtr
std::shared_ptr< const FilterInterface > FilterInterfaceCstSPtr
Definition
filterinterface.h:47
pappso::MsRunXicExtractorInterfaceSp
std::shared_ptr< MsRunXicExtractorInterface > MsRunXicExtractorInterfaceSp
Definition
msrunxicextractorinterface.h:42
uimonitorinterface.h
pappsomspp
core
xicextractor
msrunxicextractorinterface.h
Generated on
for libpappsomspp by
1.17.0