v2.0.0
Loading...
Searching...
No Matches
epoch_extractor.h
Go to the documentation of this file.
1//=============================================================================================================
20
21#ifndef EPOCH_EXTRACTOR_DSP_H
22#define EPOCH_EXTRACTOR_DSP_H
23
24//=============================================================================================================
25// INCLUDES
26//=============================================================================================================
27
28#include "dsp_global.h"
29
30#include <mne/mne_epoch_data.h>
31
32//=============================================================================================================
33// EIGEN INCLUDES
34//=============================================================================================================
35
36#include <Eigen/Core>
37
38//=============================================================================================================
39// QT INCLUDES
40//=============================================================================================================
41
42#include <QVector>
43
44//=============================================================================================================
45// DEFINE NAMESPACE UTILSLIB
46//=============================================================================================================
47
48namespace UTILSLIB
49{
50
51//=============================================================================================================
58{
59 double dTmin = -0.2;
60 double dTmax = 0.5;
61 double dBaseMin = -0.2;
62 double dBaseMax = 0.0;
63 double dThreshold = 0.0;
65 bool bApplyBaseline = true;
66};
67
68//=============================================================================================================
75{
76public:
78
79 //=========================================================================================================
100 static QVector<MNELIB::MNEEpochData> extract(const Eigen::MatrixXd& matData,
101 const QVector<int>& eventSamples,
102 double dSFreq,
103 const Params& params = Params(),
104 const QVector<int>& eventCodes = QVector<int>());
105
106 //=========================================================================================================
114 static Eigen::MatrixXd average(const QVector<MNELIB::MNEEpochData>& epochs);
115
116 //=========================================================================================================
124 static QVector<MNELIB::MNEEpochData> rejectMarked(const QVector<MNELIB::MNEEpochData>& epochs);
125
126private:
127 //=========================================================================================================
138 static void applyBaseline(Eigen::MatrixXd& matEpoch, int iBase0, int iBase1);
139};
140
141} // namespace UTILSLIB
142
143#endif // EPOCH_EXTRACTOR_DSP_H
Export/import macros and namespace declaration for the DSP library.
#define DSPSHARED_EXPORT
Definition dsp_global.h:50
Single epoch (one trial slice of preprocessed sensor data) with timing and rejection metadata.
Shared utilities (I/O helpers, spectral analysis, layout management, warp algorithms).
Epoch extraction parameters (defined outside class to avoid Clang/GCC default-argument issues with ne...
Segments continuous raw data into fixed-length epochs locked to events.
static QVector< MNELIB::MNEEpochData > rejectMarked(const QVector< MNELIB::MNEEpochData > &epochs)
static QVector< MNELIB::MNEEpochData > extract(const Eigen::MatrixXd &matData, const QVector< int > &eventSamples, double dSFreq, const Params &params=Params(), const QVector< int > &eventCodes=QVector< int >())
EpochExtractorParams Params
static Eigen::MatrixXd average(const QVector< MNELIB::MNEEpochData > &epochs)