aqnwb 0.1.0
Loading...
Searching...
No Matches
ElectrodeTable.hpp
Go to the documentation of this file.
1#pragma once
2
3#include <string>
4
5#include "BaseIO.hpp"
9
10namespace AQNWB::NWB
11{
16{
17public:
24 ElectrodeTable(std::shared_ptr<BaseIO> io,
25 const std::string& description =
26 "metadata about extracellular electrodes");
27
32
39 void initialize();
40
47 void finalize();
48
53 void addElectrodes(std::vector<Channel> channels);
54
59 inline std::string getGroupPath() const
60 {
61 // all channels in ChannelVector should have the same groupName
62 return groupReferences[0];
63 }
64
69 void setGroupPath(const std::string& groupPath);
70
71 std::unique_ptr<ElementIdentifiers> electrodeDataset =
72 std::make_unique<ElementIdentifiers>();
73 std::unique_ptr<VectorData> groupNamesDataset =
74 std::make_unique<VectorData>();
75 std::unique_ptr<VectorData> locationsDataset =
76 std::make_unique<VectorData>();
81 inline const static std::string electrodeTablePath =
82 "/general/extracellular_ephys/electrodes/";
83
84private:
88 std::vector<Channel> channels;
89
93 std::vector<int> electrodeNumbers;
94
98 std::vector<std::string> groupNames;
99
103 std::vector<std::string> locationNames;
104
108 std::vector<std::string> groupReferences;
109
113 std::string groupPathBase = "/general/extracellular_ephys/";
114};
115} // namespace AQNWB::NWB
Represents a group containing multiple datasets that are aligned on the first dimension.
Definition DynamicTable.hpp:20
Represents a table containing electrode metadata.
Definition ElectrodeTable.hpp:16
ElectrodeTable(std::shared_ptr< BaseIO > io, const std::string &description="metadata about extracellular electrodes")
Constructor.
Definition ElectrodeTable.cpp:10
static const std::string electrodeTablePath
The path to the ElectrodeTable.
Definition ElectrodeTable.hpp:81
void addElectrodes(std::vector< Channel > channels)
Sets up the ElectrodeTable by adding electrodes and their metadata.
Definition ElectrodeTable.cpp:43
std::unique_ptr< VectorData > groupNamesDataset
Definition ElectrodeTable.hpp:73
void setGroupPath(const std::string &groupPath)
Sets the group path of the ElectrodeTable.
std::unique_ptr< VectorData > locationsDataset
Definition ElectrodeTable.hpp:75
std::string getGroupPath() const
Gets the group path of the ElectrodeTable.
Definition ElectrodeTable.hpp:59
std::unique_ptr< ElementIdentifiers > electrodeDataset
Definition ElectrodeTable.hpp:71
~ElectrodeTable()
Destructor.
Definition ElectrodeTable.cpp:20
void finalize()
Finalizes the ElectrodeTable.
Definition ElectrodeTable.cpp:54
void initialize()
Initializes the ElectrodeTable.
Definition ElectrodeTable.cpp:23
Namespace for all classes related to the NWB data standard.
Definition TimeSeries.hpp:9