aqnwb 0.1.0
Loading...
Searching...
No Matches
SpikeEventSeries.hpp
Go to the documentation of this file.
1#pragma once
2
3#include <string>
4
5#include "BaseIO.hpp"
6#include "Channel.hpp"
8
9namespace AQNWB::NWB
10{
16{
17public:
39 SpikeEventSeries(const std::string& path,
40 std::shared_ptr<BaseIO> io,
43 const std::string& description,
44 const SizeArray& dsetSize,
45 const SizeArray& chunkSize,
46 const float& conversion = 1.0f,
47 const float& resolution = -1.0f,
48 const float& offset = 0.0f);
49
54
58 void initialize();
59
67 Status writeSpike(const SizeType& numSamples,
68 const SizeType& numChannels,
69 const void* data,
70 const void* timestamps);
71
72private:
76 std::string neurodataType = "SpikeEventSeries";
77
81 SizeType eventsRecorded;
82};
83} // namespace AQNWB::NWB
AQNWB::Types::SizeType SizeType
Definition BaseIO.hpp:16
AQNWB::Types::SizeArray SizeArray
Definition BaseIO.hpp:15
Represents a base data type.
Definition BaseIO.hpp:35
General purpose time series.
Definition ElectricalSeries.hpp:15
Types::ChannelVector channelVector
Channel group that this time series is associated with.
Definition ElectricalSeries.hpp:75
Stores snapshots/snippets of recorded spike events (i.e., threshold crossings).
Definition SpikeEventSeries.hpp:16
~SpikeEventSeries()
Destructor.
Definition SpikeEventSeries.cpp:32
void initialize()
Initializes the Electrical Series.
Definition SpikeEventSeries.cpp:34
SpikeEventSeries(const std::string &path, std::shared_ptr< BaseIO > io, const BaseDataType &dataType, const Types::ChannelVector &channelVector, const std::string &description, const SizeArray &dsetSize, const SizeArray &chunkSize, const float &conversion=1.0f, const float &resolution=-1.0f, const float &offset=0.0f)
Constructor.
Definition SpikeEventSeries.cpp:8
Status writeSpike(const SizeType &numSamples, const SizeType &numChannels, const void *data, const void *timestamps)
Write a single spike series event.
Definition SpikeEventSeries.cpp:41
std::unique_ptr< BaseRecordingData > timestamps
Pointer to timestamp values.
Definition TimeSeries.hpp:79
SizeArray chunkSize
Chunking size used in dataset creation.
Definition TimeSeries.hpp:117
float conversion
Scalar to multiply each element in data to convert it to the specified ‘unit’.
Definition TimeSeries.hpp:123
SizeArray dsetSize
Size used in dataset creation. Can be expanded when writing if needed.
Definition TimeSeries.hpp:112
float resolution
Smallest meaningful difference between values in data, stored in the specified by unit.
Definition TimeSeries.hpp:129
BaseDataType dataType
Data type of the data.
Definition TimeSeries.hpp:84
float offset
Scalar to add to the data after scaling by ‘conversion’ to finalize its coercion to the specified ‘un...
Definition TimeSeries.hpp:135
std::unique_ptr< BaseRecordingData > data
Pointer to data values.
Definition TimeSeries.hpp:74
std::string description
The description of the TimeSeries.
Definition TimeSeries.hpp:101
std::vector< Channel > ChannelVector
Alias for a vector of channels.
Definition Types.hpp:40
Status
Represents the status of an operation.
Definition Types.hpp:22
Namespace for all classes related to the NWB data standard.
Definition TimeSeries.hpp:9