Real-time averaging worker.
More...
#include <rtaveraging.h>
|
| | RtAveragingWorker (quint32 numAverages, quint32 iPreStimSamples, quint32 iPostStimSamples, quint32 iBaselineFromMSecs, quint32 iBaselineToMSecs, quint32 iTriggerIndex, FIFFLIB::FiffInfo::SPtr pFiffInfo) |
| |
| void | doWork (const Eigen::MatrixXd &matData) |
| |
| void | setAverageNumber (qint32 numAve) |
| |
| void | setPreStim (qint32 samples, qint32 secs) |
| |
| void | setPostStim (qint32 samples, qint32 secs) |
| |
| void | setTriggerChIndx (qint32 idx) |
| |
| void | setArtifactReduction (const QMap< QString, double > &mapThresholds) |
| |
| void | setBaselineActive (bool activate) |
| |
| void | setBaselineFrom (int fromSamp, int fromMSec) |
| |
| void | setBaselineTo (int toSamp, int toMSec) |
| |
| void | reset () |
| |
Real-time averaging worker.
Real-time averaging worker
Definition at line 83 of file rtaveraging.h.
◆ RtAveragingWorker()
| RtAveragingWorker::RtAveragingWorker |
( |
quint32 |
numAverages, |
|
|
quint32 |
iPreStimSamples, |
|
|
quint32 |
iPostStimSamples, |
|
|
quint32 |
iBaselineFromMSecs, |
|
|
quint32 |
iBaselineToMSecs, |
|
|
quint32 |
iTriggerIndex, |
|
|
FIFFLIB::FiffInfo::SPtr |
pFiffInfo |
|
) |
| |
Creates the real-time averaging object.
- Parameters
-
| [in] | numAverages | Number of evkos to average. |
| [in] | iPreStimSamples | Number of samples averaged before the stimulus. |
| [in] | iPostStimSamples | Number of samples averaged after the stimulus (including the stimulus). |
| [in] | iBaselineFromMSecs | Start of baseline area which was/is used for correction in msecs. |
| [in] | iBaselineToMSecs | End of baseline area which was/is used for correction in msecs. |
| [in] | iTriggerIndex | Row in dex of channel which is to be scanned for triggers. |
| [in] | pFiffInfo | Associated Fiff Information. |
Definition at line 72 of file rtaveraging.cpp.
◆ controlValuesChanged()
| bool RTPROCESSINGLIB::RtAveragingWorker::controlValuesChanged |
( |
| ) |
|
|
inlineprotected |
Check if control values have been changed
Definition at line 465 of file rtaveraging.h.
◆ doAveraging()
| void RtAveragingWorker::doAveraging |
( |
const Eigen::MatrixXd & |
rawSegment | ) |
|
|
protected |
◆ doWork()
| void RtAveragingWorker::doWork |
( |
const Eigen::MatrixXd & |
matData | ) |
|
Perform one single HPI fit.
- Parameters
-
| [in] | t_mat | Data to estimate the HPI positions from. |
Definition at line 106 of file rtaveraging.cpp.
◆ fillBackBuffer()
| void RtAveragingWorker::fillBackBuffer |
( |
const Eigen::MatrixXd & |
data, |
|
|
double |
dTriggerType |
|
) |
| |
|
protected |
Prepends incoming data to back/post stim buffer.
Definition at line 363 of file rtaveraging.cpp.
◆ fillFrontBuffer()
| void RtAveragingWorker::fillFrontBuffer |
( |
const Eigen::MatrixXd & |
data, |
|
|
double |
dTriggerType |
|
) |
| |
|
protected |
Prepends incoming data to front/pre stim buffer.
Definition at line 378 of file rtaveraging.cpp.
◆ generateEvoked()
| void RtAveragingWorker::generateEvoked |
( |
double |
dTriggerType | ) |
|
|
protected |
◆ mergeData()
| void RtAveragingWorker::mergeData |
( |
double |
dTriggerType | ) |
|
|
protected |
Packs the buffers togehter as one and calcualtes the current running average and emits the result if number of averages has been reached.
Definition at line 419 of file rtaveraging.cpp.
◆ reset()
| void RtAveragingWorker::reset |
( |
| ) |
|
◆ resultReady
| void RTPROCESSINGLIB::RtAveragingWorker::resultReady |
( |
const FIFFLIB::FiffEvokedSet & |
evokedStimSet, |
|
|
const QStringList & |
lResponsibleTriggerTypes |
|
) |
| |
|
signal |
Signal which is emitted when new evoked stimulus data are available.
- Parameters
-
| [in] | evokedStimSet | The evoked stimulus data set. |
| [in] | lResponsibleTriggerTypes | List of all trigger types which lead to the recent emit of a new evoked set. |
◆ setArtifactReduction()
| void RtAveragingWorker::setArtifactReduction |
( |
const QMap< QString, double > & |
mapThresholds | ) |
|
Sets the artifact reduction
- Parameters
-
| [in] | mapThresholds | The new map including the current thresholds for the channels. |
Definition at line 176 of file rtaveraging.cpp.
◆ setAverageNumber()
| void RtAveragingWorker::setAverageNumber |
( |
qint32 |
numAve | ) |
|
Sets the number of averages
- Parameters
-
| [in] | numAve | new number of averages. |
Definition at line 121 of file rtaveraging.cpp.
◆ setBaselineActive()
| void RtAveragingWorker::setBaselineActive |
( |
bool |
activate | ) |
|
Sets the baseline correction on or off
- Parameters
-
| [in] | activate | activate baseline correction. |
Definition at line 189 of file rtaveraging.cpp.
◆ setBaselineFrom()
| void RtAveragingWorker::setBaselineFrom |
( |
int |
fromSamp, |
|
|
int |
fromMSec |
|
) |
| |
Sets the from mSeconds of the baseline area
- Parameters
-
| [in] | fromSamp | from of baseline area in samples. |
| [in] | fromMSec | from of baseline area in mSeconds. |
Definition at line 206 of file rtaveraging.cpp.
◆ setBaselineTo()
| void RtAveragingWorker::setBaselineTo |
( |
int |
toSamp, |
|
|
int |
toMSec |
|
) |
| |
Sets the to mSeconds of the baseline area
- Parameters
-
| [in] | toSamp | to of baseline area in samples. |
| [in] | toMSec | to of baseline area in mSeconds. |
Definition at line 219 of file rtaveraging.cpp.
◆ setPostStim()
| void RtAveragingWorker::setPostStim |
( |
qint32 |
samples, |
|
|
qint32 |
secs |
|
) |
| |
Sets the number of post stimulus samples
- Parameters
-
| [in] | samples | new number of post stimulus samples. |
| [in] | secs | new number of pre stimulus seconds. |
Definition at line 160 of file rtaveraging.cpp.
◆ setPreStim()
| void RtAveragingWorker::setPreStim |
( |
qint32 |
samples, |
|
|
qint32 |
secs |
|
) |
| |
Sets the number of pre stimulus samples
- Parameters
-
| [in] | samples | new number of pre stimulus samples. |
| [in] | secs | new number of pre stimulus seconds. |
Definition at line 151 of file rtaveraging.cpp.
◆ setTriggerChIndx()
| void RtAveragingWorker::setTriggerChIndx |
( |
qint32 |
idx | ) |
|
Sets the index of the trigger channel which is to be scanned fo triggers
- Parameters
-
| [in] | idx | trigger channel index. |
Definition at line 169 of file rtaveraging.cpp.
◆ m_bActivateThreshold
| bool RTPROCESSINGLIB::RtAveragingWorker::m_bActivateThreshold |
|
protected |
Whether to do threshold artifact reduction or not.
Definition at line 249 of file rtaveraging.h.
◆ m_bDoBaselineCorrection
| bool RTPROCESSINGLIB::RtAveragingWorker::m_bDoBaselineCorrection |
|
protected |
Whether to perform baseline correction.
Definition at line 251 of file rtaveraging.h.
◆ m_fTriggerThreshold
| float RTPROCESSINGLIB::RtAveragingWorker::m_fTriggerThreshold |
|
protected |
◆ m_iNewPostStimSamples
| qint32 RTPROCESSINGLIB::RtAveragingWorker::m_iNewPostStimSamples |
|
protected |
New amount of samples averaged after the stimulus, including the stimulus sample.
Definition at line 242 of file rtaveraging.h.
◆ m_iNewPreStimSamples
| qint32 RTPROCESSINGLIB::RtAveragingWorker::m_iNewPreStimSamples |
|
protected |
New amount of samples averaged before the stimulus.
Definition at line 239 of file rtaveraging.h.
◆ m_iNewTriggerIndex
| qint32 RTPROCESSINGLIB::RtAveragingWorker::m_iNewTriggerIndex |
|
protected |
Old row index of the data matrix which is to be scanned for triggers.
Definition at line 245 of file rtaveraging.h.
◆ m_iNumAverages
| qint32 RTPROCESSINGLIB::RtAveragingWorker::m_iNumAverages |
|
protected |
◆ m_iPostStimSamples
| qint32 RTPROCESSINGLIB::RtAveragingWorker::m_iPostStimSamples |
|
protected |
Amount of samples averaged after the stimulus, including the stimulus sample.
Definition at line 241 of file rtaveraging.h.
◆ m_iPreStimSamples
| qint32 RTPROCESSINGLIB::RtAveragingWorker::m_iPreStimSamples |
|
protected |
Amount of samples averaged before the stimulus.
Definition at line 238 of file rtaveraging.h.
◆ m_iTriggerChIndex
| qint32 RTPROCESSINGLIB::RtAveragingWorker::m_iTriggerChIndex |
|
protected |
Current row index of the data matrix which is to be scanned for triggers.
Definition at line 244 of file rtaveraging.h.
◆ m_mapDataPost
| QMap<double,Eigen::MatrixXd> RTPROCESSINGLIB::RtAveragingWorker::m_mapDataPost |
|
protected |
The matrix holding post stim data.
Definition at line 262 of file rtaveraging.h.
◆ m_mapDataPre
| QMap<double,Eigen::MatrixXd> RTPROCESSINGLIB::RtAveragingWorker::m_mapDataPre |
|
protected |
◆ m_mapFillingBackBuffer
| QMap<double,bool> RTPROCESSINGLIB::RtAveragingWorker::m_mapFillingBackBuffer |
|
protected |
Whether the back buffer is currently getting filled.
Definition at line 264 of file rtaveraging.h.
◆ m_mapMatDataPostIdx
| QMap<double,qint32> RTPROCESSINGLIB::RtAveragingWorker::m_mapMatDataPostIdx |
|
protected |
Current index inside of the matrix m_matDataPost.
Definition at line 263 of file rtaveraging.h.
◆ m_mapStimAve
| QMap<double,QList<Eigen::MatrixXd> > RTPROCESSINGLIB::RtAveragingWorker::m_mapStimAve |
|
protected |
the current stimulus average buffer. Holds m_iNumAverages vectors.
Definition at line 260 of file rtaveraging.h.
◆ m_mapThresholds
| QMap<QString,double> RTPROCESSINGLIB::RtAveragingWorker::m_mapThresholds |
|
protected |
Holds the current thresholds for artifact rejection.
Definition at line 259 of file rtaveraging.h.
◆ m_pairBaselineSamp
| QPair<float,float> RTPROCESSINGLIB::RtAveragingWorker::m_pairBaselineSamp |
|
protected |
Baseline information in samples form where the seconds are seen relative to the trigger, meaning they can also be negative [from to]
Definition at line 254 of file rtaveraging.h.
◆ m_pairBaselineSec
| QPair<float,float> RTPROCESSINGLIB::RtAveragingWorker::m_pairBaselineSec |
|
protected |
Baseline information in seconds form where the seconds are seen relative to the trigger, meaning they can also be negative [from to]
Definition at line 253 of file rtaveraging.h.
◆ m_pFiffInfo
Holds the fiff measurement information.
Definition at line 256 of file rtaveraging.h.
◆ m_stimEvokedSet
The documentation for this class was generated from the following files: