NeurodataWithoutBorders / nwb-schema

Data format specification schema for the NWB neurophysiology data format
http://nwb-schema.readthedocs.io
Other
53 stars 16 forks source link

Intracellular Units #413

Open rly opened 4 years ago

rly commented 4 years ago

The Units table is designed for storing extracellular units: it contains optional references to the electrodes table and electrode group, which are both defined in the context of ecephys. The Svoboda lab has a dataset with units for intracellular data.

Since there is currently not a good way to store those units in NWB, @bendichter and I advised them to store the data as a PatchClampSeries with binary data that mirrored the PatchClampSeries with the voltage recordings. Importantly, both PatchClampSeries have links to the same IntracellularElectrode that was used, so their relationship with each other is encoded.

It would be better to have an ICEphysUnits table that is similar to the Units table, except have a column with references to IntracellularElectrode objects, instead of a column with a DynamicTableRegion for electrodes.

We could have the Units table hold both extracellular and intracellular ephys data for datasets that have both, but that could get confusing. I think it would be better to separate them.

Questions:

  1. Are intracellular units recorded from one and only one intracellular electrode? i.e., are there ever tetrode arrangements for intracellular recordings?
  2. Ideally, both the Units table and ICEphysUnits table would inherit from the same base BaseUnits table type. And the Units table would have additional columns for ecephys and the ICEphysUnits table would have additional columns for icephys. Would it be possible to insert that hierarchy or would that break things?

I mocked up an extension for this here: https://github.com/rly/ndx-icephys-units This extension copies much of the schema and PyNWB code for the current Units table.

@oruebel @bendichter @ajtritt @t-b

bendichter commented 4 years ago

I think I'd rather spike times go in the intracellular_recordings table as an optional column. It seems like a lot of that would need to be replicated for an IcephysUnits table. For extracellular electrophysiology, it made more sense because users want to use the spikes without worrying about the original recordings, but that is never the case with icephys. The spike times are used to calculate metrics on the shape of the waveforms in the trace. Separating them does not have much value here.

lvsltz commented 4 years ago

Are intracellular units recorded from one and only one intracellular electrode? i.e., are there ever tetrode arrangements for intracellular recordings?

FYI, you could have 2 pipettes on a single cell. Look up "dual patch"

t-b commented 4 years ago

I think I'd rather spike times go in the intracellular_recordings table as an optional column.

I second that.