OpenWalnut  1.5.0dev
Public Member Functions | Static Public Member Functions | Static Protected Attributes | Private Attributes | List of all members
WEEG Class Reference

Contains EEG recording data. More...

#include <WEEG.h>

+ Inheritance diagram for WEEG:
+ Collaboration diagram for WEEG:

Public Member Functions

 WEEG (const WEEGSegmentArray &data, const WEEGElectrodeLibrary &electrodeLib, const WEEGChannelLabels &channelLabels)
 Constructs a WEEG object from the give infos. More...
 
 WEEG ()
 Constructor creating a quite unusable instance. More...
 
const double & operator() (size_t segment, size_t signal, size_t sample) const
 Access operator for single samples. More...
 
size_t getNumberOfSamples (size_t segmentId) const
 Returns number of samples of a given segment. More...
 
size_t getNumberOfChannels () const
 Return the number of channels this EEG has. More...
 
size_t getNumberOfSegments () const
 Return the number of segments this EEG consists of. More...
 
std::string getChannelLabel (size_t channelId) const
 Return the label of a certain channel. More...
 
WPosition getChannelPosition (size_t channelId) const
 Return the position of the sensor for a certain channel. More...
 
virtual bool isTexture () const
 Determines whether this dataset can be used as a texture. More...
 
virtual const std::string getName () const
 Gets the name of this prototype. More...
 
virtual const std::string getDescription () const
 Gets the description for this prototype. More...
 
- Public Member Functions inherited from WRecording
 WRecording ()
 Empty standard constructor for recordings. More...
 
- Public Member Functions inherited from WDataSet
 WDataSet ()
 This constructor should be used if a dataSet does not stem from a file. More...
 
virtual ~WDataSet ()
 Since WDataSet is a base class and thus should be polymorphic we add virtual destructor. More...
 
void setFilename (const std::string filename)
 Set the name of the file that this data set stems from. More...
 
std::string getFilename () const
 Get the name of the file that this data set stems from. More...
 
OW_API_DEPRECATED void setFileName (const std::string filename)
 Set the name of the file that this data set stems from. More...
 
OW_API_DEPRECATED std::string getFileName () const
 Get the name of the file that this data set stems from. More...
 
virtual std::shared_ptr< WDataSetVectorisVectorDataSet ()
 Checks if this dataset is a vector dataset. More...
 
virtual osg::ref_ptr< WDataTexture3DgetTexture () const
 Returns the texture- representation of the dataset. More...
 
std::shared_ptr< WPropertiesgetProperties () const
 Return a pointer to the properties object of the dataset. More...
 
std::shared_ptr< WPropertiesgetInformationProperties () const
 Return a pointer to the information properties object of the dataset. More...
 
- Public Member Functions inherited from WTransferable
 WTransferable ()
 Default constructor. More...
 
virtual ~WTransferable ()
 Destructor. More...
 
- Public Member Functions inherited from WPrototyped
 WPrototyped ()
 Default constructor. More...
 
virtual ~WPrototyped ()
 Destructor. More...
 
template<typename T >
bool isA ()
 Checks whether the actual prototype has the specified runtime type. More...
 

Static Public Member Functions

static std::shared_ptr< WPrototypedgetPrototype ()
 Returns a prototype instantiated with the true type of the deriving class. More...
 
- Static Public Member Functions inherited from WRecording
static std::shared_ptr< WPrototypedgetPrototype ()
 Returns a prototype instantiated with the true type of the deriving class. More...
 
- Static Public Member Functions inherited from WDataSet
static std::shared_ptr< WPrototypedgetPrototype ()
 Returns a prototype instantiated with the true type of the deriving class. More...
 

Static Protected Attributes

static std::shared_ptr< WPrototypedm_prototype = std::shared_ptr< WPrototyped >()
 The prototype as singleton. More...
 
- Static Protected Attributes inherited from WRecording
static std::shared_ptr< WPrototypedm_prototype = std::shared_ptr< WPrototyped >()
 The prototype as singleton. More...
 
- Static Protected Attributes inherited from WDataSet
static std::shared_ptr< WPrototypedm_prototype = std::shared_ptr< WPrototyped >()
 The prototype as singleton. More...
 

Private Attributes

std::map< std::string, size_t > m_electrodeDescriptions
 Description of electrodes. More...
 
WEEGElectrodeLibrary m_electrodeLibrary
 Information about the electrodes. More...
 
WEEGSegmentArray m_segments
 Contains the EEG data as an arry of segements of data which consist of an array of electrodes which again consist of an array of samples over time. More...
 
WEEGChannelLabels m_channelLabels
 Label for each channel. More...
 
std::vector< bool > m_channelEnabled
 Is the channel enabled? More...
 

Additional Inherited Members

- Public Types inherited from WDataSet
typedef std::shared_ptr< WDataSetSPtr
 Shared pointer abbreviation to a instance of this class. More...
 
typedef std::shared_ptr< const WDataSetConstSPtr
 Shared pointer abbreviation to a const instance of this class. More...
 
- Static Public Attributes inherited from WRecording
static const unsigned int MAX_RECORDING_CHANNELS = 1024
 Maximum number of channels for a certain modality. More...
 
static const unsigned int MAX_RECORDING_SAMPLES = 4294967295U
 Maximum number of samples of a recording. More...
 
static const unsigned int MAX_RECORDING_SEGMENTS = 128
 Maximum number of segments of a recording. More...
 
static const unsigned int MAX_RECORDING_SAMPLING_FREQUENCY = 20000
 Maximum samplimg frequency of a recording. More...
 
- Protected Attributes inherited from WDataSet
std::shared_ptr< WPropertiesm_properties
 The property object for the dataset. More...
 
std::shared_ptr< WPropertiesm_infoProperties
 The property object for the dataset containing only props whose purpose is "PV_PURPOSE_INFORMNATION". More...
 

Detailed Description

Contains EEG recording data.

Definition at line 70 of file WEEG.h.

Constructor & Destructor Documentation

◆ WEEG() [1/2]

WEEG::WEEG ( const WEEGSegmentArray &  data,
const WEEGElectrodeLibrary &  electrodeLib,
const WEEGChannelLabels &  channelLabels 
)
explicit

Constructs a WEEG object from the give infos.

Parameters
dataArray of segments
electrodeLibInformation about the electrodes
channelLabelsThe names of the channels.

Definition at line 34 of file WEEG.cpp.

References m_channelLabels, m_electrodeLibrary, m_segments, WRecording::MAX_RECORDING_CHANNELS, WRecording::MAX_RECORDING_SAMPLES, and WRecording::MAX_RECORDING_SEGMENTS.

◆ WEEG() [2/2]

WEEG::WEEG ( )

Constructor creating a quite unusable instance.

Useful for prototype mechanism.

Definition at line 56 of file WEEG.cpp.

Referenced by getPrototype().

+ Here is the caller graph for this function:

Member Function Documentation

◆ getChannelLabel()

std::string WEEG::getChannelLabel ( size_t  channelId) const
inline

Return the label of a certain channel.

Parameters
channelIdid of channel beeing inspected.
Returns
Name of channel with channelId

Definition at line 213 of file WEEG.h.

References m_channelLabels.

◆ getChannelPosition()

WPosition WEEG::getChannelPosition ( size_t  channelId) const
inline

Return the position of the sensor for a certain channel.

Parameters
channelIdid of channel beeing inspected.
Returns
Position of sensor of channel channelId

Definition at line 219 of file WEEG.h.

References m_electrodeLibrary.

◆ getDescription()

const std::string WEEG::getDescription ( ) const
virtual

Gets the description for this prototype.

Returns
the description

Reimplemented from WRecording.

Definition at line 72 of file WEEG.cpp.

◆ getName()

const std::string WEEG::getName ( ) const
virtual

Gets the name of this prototype.

Returns
the name.

Reimplemented from WRecording.

Definition at line 67 of file WEEG.cpp.

◆ getNumberOfChannels()

size_t WEEG::getNumberOfChannels ( ) const
inline

Return the number of channels this EEG has.

Returns
Number of channels.

Definition at line 203 of file WEEG.h.

References m_segments.

◆ getNumberOfSamples()

size_t WEEG::getNumberOfSamples ( size_t  segmentId) const
inline

Returns number of samples of a given segment.

Parameters
segmentIdid of segment beeing inspected.
Returns
Number of samples of segment with segmentId.

Definition at line 198 of file WEEG.h.

References m_segments.

◆ getNumberOfSegments()

size_t WEEG::getNumberOfSegments ( ) const
inline

Return the number of segments this EEG consists of.

Returns
Number of segments.

Definition at line 208 of file WEEG.h.

References m_segments.

◆ getPrototype()

std::shared_ptr< WPrototyped > WEEG::getPrototype ( )
static

Returns a prototype instantiated with the true type of the deriving class.

Returns
the prototype.

Definition at line 77 of file WEEG.cpp.

References m_prototype, and WEEG().

+ Here is the call graph for this function:

◆ isTexture()

bool WEEG::isTexture ( ) const
virtual

Determines whether this dataset can be used as a texture.

Returns
true if usable as texture.

Reimplemented from WDataSet.

Definition at line 62 of file WEEG.cpp.

◆ operator()()

const double & WEEG::operator() ( size_t  segment,
size_t  signal,
size_t  sample 
) const
inline

Access operator for single samples.

Parameters
segmentid of segment to access
signalid of signal to access
sampleid of sample to access
Returns
The data sample at the given location

Definition at line 193 of file WEEG.h.

References m_segments.

Member Data Documentation

◆ m_channelEnabled

std::vector< bool > WEEG::m_channelEnabled
private

Is the channel enabled?

Definition at line 190 of file WEEG.h.

◆ m_channelLabels

WEEGChannelLabels WEEG::m_channelLabels
private

Label for each channel.

Definition at line 185 of file WEEG.h.

Referenced by getChannelLabel(), and WEEG().

◆ m_electrodeDescriptions

std::map< std::string, size_t > WEEG::m_electrodeDescriptions
private

Description of electrodes.

Definition at line 168 of file WEEG.h.

◆ m_electrodeLibrary

WEEGElectrodeLibrary WEEG::m_electrodeLibrary
private

Information about the electrodes.

Definition at line 173 of file WEEG.h.

Referenced by getChannelPosition(), and WEEG().

◆ m_prototype

std::shared_ptr< WPrototyped > WEEG::m_prototype = std::shared_ptr< WPrototyped >()
staticprotected

The prototype as singleton.

Definition at line 162 of file WEEG.h.

Referenced by getPrototype().

◆ m_segments

WEEGSegmentArray WEEG::m_segments
private

Contains the EEG data as an arry of segements of data which consist of an array of electrodes which again consist of an array of samples over time.

Definition at line 180 of file WEEG.h.

Referenced by getNumberOfChannels(), getNumberOfSamples(), getNumberOfSegments(), operator()(), and WEEG().


The documentation for this class was generated from the following files: