Skip to content

Commit

Permalink
add schema files and update default version
Browse files Browse the repository at this point in the history
lawrence-mbf committed Dec 16, 2022
1 parent cf16d37 commit 65f9cc1
Showing 20 changed files with 3,314 additions and 1 deletion.
2 changes: 1 addition & 1 deletion generateCore.m
Original file line number Diff line number Diff line change
@@ -23,7 +23,7 @@ function generateCore(varargin)
%
% See also GENERATEEXTENSION

latestVersion = '2.5.0';
latestVersion = '2.6.0';

if nargin == 0 || strcmp(varargin{1}, 'savedir')
version = latestVersion;
264 changes: 264 additions & 0 deletions nwb-schema/2.6.0/core/nwb.base.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,264 @@
datasets:
- neurodata_type_def: NWBData
neurodata_type_inc: Data
doc: An abstract data type for a dataset.

- neurodata_type_def: TimeSeriesReferenceVectorData
neurodata_type_inc: VectorData
default_name: timeseries
dtype:
- name: idx_start
dtype: int32
doc: Start index into the TimeSeries 'data' and 'timestamp' datasets of the referenced
TimeSeries. The first dimension of those arrays is always time.
- name: count
dtype: int32
doc: Number of data samples available in this time series, during this epoch
- name: timeseries
dtype:
target_type: TimeSeries
reftype: object
doc: The TimeSeries that this index applies to
doc: Column storing references to a TimeSeries (rows). For each TimeSeries this
VectorData column stores the start_index and count to indicate the range in time
to be selected as well as an object reference to the TimeSeries.

- neurodata_type_def: Image
neurodata_type_inc: NWBData
dtype: numeric
dims:
- - x
- y
- - x
- y
- r, g, b
- - x
- y
- r, g, b, a
shape:
- - null
- null
- - null
- null
- 3
- - null
- null
- 4
doc: An abstract data type for an image. Shape can be 2-D (x, y), or 3-D where the
third dimension can have three or four elements, e.g. (x, y, (r, g, b)) or
(x, y, (r, g, b, a)).
attributes:
- name: resolution
dtype: float32
doc: Pixel resolution of the image, in pixels per centimeter.
required: false
- name: description
dtype: text
doc: Description of the image.
required: false

- neurodata_type_def: ImageReferences
neurodata_type_inc: NWBData
dtype:
target_type: Image
reftype: object
dims:
- num_images
shape:
- null
doc: Ordered dataset of references to Image objects.

groups:
- neurodata_type_def: NWBContainer
neurodata_type_inc: Container
doc: An abstract data type for a generic container storing collections of data and
metadata. Base type for all data and metadata containers.

- neurodata_type_def: NWBDataInterface
neurodata_type_inc: NWBContainer
doc: An abstract data type for a generic container storing collections of data,
as opposed to metadata.

- neurodata_type_def: TimeSeries
neurodata_type_inc: NWBDataInterface
doc: General purpose time series.
attributes:
- name: description
dtype: text
default_value: no description
doc: Description of the time series.
required: false
- name: comments
dtype: text
default_value: no comments
doc: Human-readable comments about the TimeSeries. This second descriptive field
can be used to store additional information, or descriptive information if the
primary description field is populated with a computer-readable string.
required: false
datasets:
- name: data
dims:
- - num_times
- - num_times
- num_DIM2
- - num_times
- num_DIM2
- num_DIM3
- - num_times
- num_DIM2
- num_DIM3
- num_DIM4
shape:
- - null
- - null
- null
- - null
- null
- null
- - null
- null
- null
- null
doc: Data values. Data can be in 1-D, 2-D, 3-D, or 4-D. The first dimension
should always represent time. This can also be used to store binary data
(e.g., image frames). This can also be a link to data stored in an external file.
attributes:
- name: conversion
dtype: float32
default_value: 1.0
doc: Scalar to multiply each element in data to convert it to the specified 'unit'.
If the data are stored in acquisition system units or other units
that require a conversion to be interpretable, multiply the data by 'conversion'
to convert the data to the specified 'unit'. e.g. if the data acquisition system
stores values in this object as signed 16-bit integers (int16 range
-32,768 to 32,767) that correspond to a 5V range (-2.5V to 2.5V), and the data
acquisition system gain is 8000X, then the 'conversion' multiplier to get from
raw data acquisition values to recorded volts is 2.5/32768/8000 = 9.5367e-9.
required: false
- name: offset
dtype: float32
default_value: 0.0
doc: Scalar to add to the data after scaling by 'conversion' to finalize its coercion
to the specified 'unit'. Two common examples of this include (a) data stored in an
unsigned type that requires a shift after scaling to re-center the data,
and (b) specialized recording devices that naturally cause a scalar offset with
respect to the true units.
required: false
- name: resolution
dtype: float32
default_value: -1.0
doc: Smallest meaningful difference between values in data, stored in the specified
by unit, e.g., the change in value of the least significant bit, or a larger
number if signal noise is known to be present. If unknown, use -1.0.
required: false
- name: unit
dtype: text
doc: Base unit of measurement for working with the data. Actual stored values are
not necessarily stored in these units. To access the data in these units,
multiply 'data' by 'conversion' and add 'offset'.
- name: continuity
dtype: text
doc: Optionally describe the continuity of the data. Can be "continuous", "instantaneous", or
"step". For example, a voltage trace would be "continuous", because samples
are recorded from a continuous process. An array of lick times would be "instantaneous",
because the data represents distinct moments in time. Times of image presentations would be
"step" because the picture remains the same until the next timepoint. This field is optional,
but is useful in providing information about the underlying data. It may inform the way this
data is interpreted, the way it is visualized, and what analysis methods are applicable.
required: false
- name: starting_time
dtype: float64
doc: Timestamp of the first sample in seconds. When timestamps are uniformly
spaced, the timestamp of the first sample can be specified and all subsequent
ones calculated from the sampling rate attribute.
quantity: '?'
attributes:
- name: rate
dtype: float32
doc: Sampling rate, in Hz.
- name: unit
dtype: text
value: seconds
doc: Unit of measurement for time, which is fixed to 'seconds'.
- name: timestamps
dtype: float64
dims:
- num_times
shape:
- null
doc: Timestamps for samples stored in data, in seconds, relative to the
common experiment master-clock stored in NWBFile.timestamps_reference_time.
quantity: '?'
attributes:
- name: interval
dtype: int32
value: 1
doc: Value is '1'
- name: unit
dtype: text
value: seconds
doc: Unit of measurement for timestamps, which is fixed to 'seconds'.
- name: control
dtype: uint8
dims:
- num_times
shape:
- null
doc: Numerical labels that apply to each time point in data for the purpose of
querying and slicing data by these values. If present, the length of this
array should be the same size as the first dimension of data.
quantity: '?'
- name: control_description
dtype: text
dims:
- num_control_values
shape:
- null
doc: Description of each control value. Must be present if control is present.
If present, control_description[0] should describe time points where control == 0.
quantity: '?'
groups:
- name: sync
doc: Lab-specific time and sync information as provided directly from hardware
devices and that is necessary for aligning all acquired time information to
a common timebase. The timestamp array stores time in the common timebase.
This group will usually only be populated in TimeSeries that are
stored external to the NWB file, in files storing raw data. Once timestamp
data is calculated, the contents of 'sync' are mostly for archival purposes.
quantity: '?'

- neurodata_type_def: ProcessingModule
neurodata_type_inc: NWBContainer
doc: A collection of processed data.
attributes:
- name: description
dtype: text
doc: Description of this collection of processed data.
groups:
- neurodata_type_inc: NWBDataInterface
doc: Data objects stored in this collection.
quantity: '*'
- neurodata_type_inc: DynamicTable
doc: Tables stored in this collection.
quantity: '*'

- neurodata_type_def: Images
neurodata_type_inc: NWBDataInterface
default_name: Images
doc: A collection of images with an optional way to specify the order of the images
using the "order_of_images" dataset. An order must be specified if the images are
referenced by index, e.g., from an IndexSeries.
attributes:
- name: description
dtype: text
doc: Description of this collection of images.
datasets:
- neurodata_type_inc: Image
doc: Images stored in this collection.
quantity: '+'
- name: order_of_images
neurodata_type_inc: ImageReferences
doc: Ordered dataset of references to Image objects stored in the parent group.
Each Image object in the Images group should be stored once and only once, so
the dataset should have the same length as the number of images.
quantity: '?'
124 changes: 124 additions & 0 deletions nwb-schema/2.6.0/core/nwb.behavior.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
groups:
- neurodata_type_def: SpatialSeries
neurodata_type_inc: TimeSeries
doc: "Direction, e.g., of gaze or travel, or position. The TimeSeries::data field\
\ is a 2D array storing position or direction relative to some reference frame.\
\ Array structure: [num measurements] [num dimensions]. Each SpatialSeries has\
\ a text dataset reference_frame that indicates the zero-position, or the zero-axes\
\ for direction. For example, if representing gaze direction, 'straight-ahead'\
\ might be a specific pixel on the monitor, or some other point in space. For\
\ position data, the 0,0 point might be the top-left corner of an enclosure, as\
\ viewed from the tracking camera. The unit of data will indicate how to interpret\
\ SpatialSeries values."
datasets:
- name: data
dtype: numeric
dims:
- - num_times
- - num_times
- x
- - num_times
- x,y
- - num_times
- x,y,z
shape:
- - null
- - null
- 1
- - null
- 2
- - null
- 3
doc: 1-D or 2-D array storing position or direction relative to some reference frame.
attributes:
- name: unit
dtype: text
default_value: meters
doc: Base unit of measurement for working with the data. The default value
is 'meters'. Actual stored values are not necessarily stored in these units.
To access the data in these units, multiply 'data' by 'conversion' and add 'offset'.
required: false
- name: reference_frame
dtype: text
doc: Description defining what exactly 'straight-ahead' means.
quantity: '?'

- neurodata_type_def: BehavioralEpochs
neurodata_type_inc: NWBDataInterface
default_name: BehavioralEpochs
doc: TimeSeries for storing behavioral epochs. The objective of this and the other
two Behavioral interfaces (e.g. BehavioralEvents and BehavioralTimeSeries) is
to provide generic hooks for software tools/scripts. This allows a tool/script
to take the output one specific interface (e.g., UnitTimes) and plot that data
relative to another data modality (e.g., behavioral events) without having to
define all possible modalities in advance. Declaring one of these interfaces means
that one or more TimeSeries of the specified type is published. These TimeSeries
should reside in a group having the same name as the interface. For example, if
a BehavioralTimeSeries interface is declared, the module will have one or more
TimeSeries defined in the module sub-group 'BehavioralTimeSeries'. BehavioralEpochs
should use IntervalSeries. BehavioralEvents is used for irregular events. BehavioralTimeSeries
is for continuous data.
groups:
- neurodata_type_inc: IntervalSeries
doc: IntervalSeries object containing start and stop times of epochs.
quantity: '*'

- neurodata_type_def: BehavioralEvents
neurodata_type_inc: NWBDataInterface
default_name: BehavioralEvents
doc: TimeSeries for storing behavioral events. See description of <a href="#BehavioralEpochs">BehavioralEpochs</a>
for more details.
groups:
- neurodata_type_inc: TimeSeries
doc: TimeSeries object containing behavioral events.
quantity: '*'

- neurodata_type_def: BehavioralTimeSeries
neurodata_type_inc: NWBDataInterface
default_name: BehavioralTimeSeries
doc: TimeSeries for storing Behavoioral time series data. See description of <a href="#BehavioralEpochs">BehavioralEpochs</a>
for more details.
groups:
- neurodata_type_inc: TimeSeries
doc: TimeSeries object containing continuous behavioral data.
quantity: '*'

- neurodata_type_def: PupilTracking
neurodata_type_inc: NWBDataInterface
default_name: PupilTracking
doc: Eye-tracking data, representing pupil size.
groups:
- neurodata_type_inc: TimeSeries
doc: TimeSeries object containing time series data on pupil size.
quantity: '+'

- neurodata_type_def: EyeTracking
neurodata_type_inc: NWBDataInterface
default_name: EyeTracking
doc: Eye-tracking data, representing direction of gaze.
groups:
- neurodata_type_inc: SpatialSeries
doc: SpatialSeries object containing data measuring direction of gaze.
quantity: '*'

- neurodata_type_def: CompassDirection
neurodata_type_inc: NWBDataInterface
default_name: CompassDirection
doc: With a CompassDirection interface, a module publishes a SpatialSeries object
representing a floating point value for theta. The SpatialSeries::reference_frame
field should indicate what direction corresponds to 0 and which is the direction
of rotation (this should be clockwise). The si_unit for the SpatialSeries should
be radians or degrees.
groups:
- neurodata_type_inc: SpatialSeries
doc: SpatialSeries object containing direction of gaze travel.
quantity: '*'

- neurodata_type_def: Position
neurodata_type_inc: NWBDataInterface
default_name: Position
doc: Position data, whether along the x, x/y or x/y/z axis.
groups:
- neurodata_type_inc: SpatialSeries
doc: SpatialSeries object containing position data.
quantity: '+'
14 changes: 14 additions & 0 deletions nwb-schema/2.6.0/core/nwb.device.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
groups:
- neurodata_type_def: Device
neurodata_type_inc: NWBContainer
doc: Metadata about a data acquisition device, e.g., recording system, electrode, microscope.
attributes:
- name: description
dtype: text
doc: Description of the device (e.g., model, firmware version, processing software version, etc.)
as free-form text.
required: false
- name: manufacturer
dtype: text
doc: The name of the manufacturer of the device.
required: false
333 changes: 333 additions & 0 deletions nwb-schema/2.6.0/core/nwb.ecephys.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,333 @@
groups:
- neurodata_type_def: ElectricalSeries
neurodata_type_inc: TimeSeries
doc: A time series of acquired voltage data from extracellular recordings.
The data field is an int or float array storing data in volts. The first
dimension should always represent time. The second dimension, if present,
should represent channels.
attributes:
- name: filtering
dtype: text
doc: Filtering applied to all channels of the data. For example, if this ElectricalSeries represents
high-pass-filtered data (also known as AP Band), then this value could be "High-pass 4-pole Bessel filter
at 500 Hz". If this ElectricalSeries represents low-pass-filtered LFP data and the type of filter is unknown,
then this value could be "Low-pass filter at 300 Hz". If a non-standard filter type is used, provide as much
detail about the filter properties as possible.
required: false
datasets:
- name: data
dtype: numeric
dims:
- - num_times
- - num_times
- num_channels
- - num_times
- num_channels
- num_samples
shape:
- - null
- - null
- null
- - null
- null
- null
doc: Recorded voltage data.
attributes:
- name: unit
dtype: text
value: volts
doc: Base unit of measurement for working with the data. This value is fixed to
'volts'. Actual stored values are not necessarily stored in these units. To
access the data in these units, multiply 'data' by 'conversion', followed by
'channel_conversion' (if present), and then add 'offset'.
- name: electrodes
neurodata_type_inc: DynamicTableRegion
doc: DynamicTableRegion pointer to the electrodes that this time series was generated from.
- name: channel_conversion
dtype: float32
dims:
- num_channels
shape:
- null
doc: Channel-specific conversion factor. Multiply the data in the 'data' dataset by these
values along the channel axis (as indicated by axis attribute) AND by the global
conversion factor in the 'conversion' attribute of 'data' to get the data values in
Volts, i.e, data in Volts = data * data.conversion * channel_conversion. This
approach allows for both global and per-channel data conversion factors needed
to support the storage of electrical recordings as native values generated by data
acquisition systems. If this dataset is not present, then there is no channel-specific
conversion factor, i.e. it is 1 for all channels.
quantity: '?'
attributes:
- name: axis
dtype: int32
value: 1
doc: The zero-indexed axis of the 'data' dataset that the channel-specific conversion
factor corresponds to. This value is fixed to 1.

- neurodata_type_def: SpikeEventSeries
neurodata_type_inc: ElectricalSeries
doc: "Stores snapshots/snippets of recorded spike events (i.e., threshold crossings). This
may also be raw data, as reported by ephys hardware. If so, the TimeSeries::description
field should describe how events were detected. All SpikeEventSeries should
reside in a module (under EventWaveform interface) even if the spikes were reported
and stored by hardware. All events span the same recording channels and store
snapshots of equal duration. TimeSeries::data array structure: [num events]
[num channels] [num samples] (or [num events] [num samples] for single electrode)."
datasets:
- name: data
dtype: numeric
dims:
- - num_events
- num_samples
- - num_events
- num_channels
- num_samples
shape:
- - null
- null
- - null
- null
- null
doc: Spike waveforms.
attributes:
- name: unit
dtype: text
value: volts
doc: Unit of measurement for waveforms, which is fixed to 'volts'.
- name: timestamps
dtype: float64
dims:
- num_times
shape:
- null
doc: Timestamps for samples stored in data, in seconds, relative to the
common experiment master-clock stored in NWBFile.timestamps_reference_time.
Timestamps are required for the events. Unlike for TimeSeries, timestamps are
required for SpikeEventSeries and are thus re-specified here.
attributes:
- name: interval
dtype: int32
value: 1
doc: Value is '1'
- name: unit
dtype: text
value: seconds
doc: Unit of measurement for timestamps, which is fixed to 'seconds'.

- neurodata_type_def: FeatureExtraction
neurodata_type_inc: NWBDataInterface
default_name: FeatureExtraction
doc: Features, such as PC1 and PC2, that are extracted from signals stored in a
SpikeEventSeries or other source.
datasets:
- name: description
dtype: text
dims:
- num_features
shape:
- null
doc: Description of features (eg, ''PC1'') for each of the extracted features.
- name: features
dtype: float32
dims:
- num_events
- num_channels
- num_features
shape:
- null
- null
- null
doc: Multi-dimensional array of features extracted from each event.
- name: times
dtype: float64
dims:
- num_events
shape:
- null
doc: Times of events that features correspond to (can be a link).
- name: electrodes
neurodata_type_inc: DynamicTableRegion
doc: DynamicTableRegion pointer to the electrodes that this time series was generated from.

- neurodata_type_def: EventDetection
neurodata_type_inc: NWBDataInterface
default_name: EventDetection
doc: Detected spike events from voltage trace(s).
datasets:
- name: detection_method
dtype: text
doc: Description of how events were detected, such as voltage threshold, or dV/dT
threshold, as well as relevant values.
- name: source_idx
dtype: int32
dims:
- num_events
shape:
- null
doc: Indices (zero-based) into source ElectricalSeries::data array corresponding
to time of event. ''description'' should define what is meant by time of
event (e.g., .25 ms before action potential peak, zero-crossing time, etc).
The index points to each event from the raw data.
- name: times
dtype: float64
dims:
- num_events
shape:
- null
doc: Timestamps of events, in seconds.
attributes:
- name: unit
dtype: text
value: seconds
doc: Unit of measurement for event times, which is fixed to 'seconds'.
links:
- name: source_electricalseries
target_type: ElectricalSeries
doc: Link to the ElectricalSeries that this data was calculated from. Metadata
about electrodes and their position can be read from that ElectricalSeries so
it's not necessary to include that information here.

- neurodata_type_def: EventWaveform
neurodata_type_inc: NWBDataInterface
default_name: EventWaveform
doc: Represents either the waveforms of detected events, as extracted from a raw
data trace in /acquisition, or the event waveforms that were stored during experiment
acquisition.
groups:
- neurodata_type_inc: SpikeEventSeries
doc: SpikeEventSeries object(s) containing detected spike event waveforms.
quantity: '*'

- neurodata_type_def: FilteredEphys
neurodata_type_inc: NWBDataInterface
default_name: FilteredEphys
doc: Electrophysiology data from one or more channels that has been subjected to filtering.
Examples of filtered data include Theta and Gamma (LFP has its own interface).
FilteredEphys modules publish an ElectricalSeries for each filtered channel or
set of channels. The name of each ElectricalSeries is arbitrary but should be
informative. The source of the filtered data, whether this is from analysis of
another time series or as acquired by hardware, should be noted in each's TimeSeries::description
field. There is no assumed 1::1 correspondence between filtered ephys signals
and electrodes, as a single signal can apply to many nearby electrodes, and one
electrode may have different filtered (e.g., theta and/or gamma) signals represented.
Filter properties should be noted in the ElectricalSeries 'filtering' attribute.
groups:
- neurodata_type_inc: ElectricalSeries
doc: ElectricalSeries object(s) containing filtered electrophysiology data.
quantity: '+'

- neurodata_type_def: LFP
neurodata_type_inc: NWBDataInterface
default_name: LFP
doc: LFP data from one or more channels. The electrode map in each published ElectricalSeries
will identify which channels are providing LFP data. Filter properties should
be noted in the ElectricalSeries 'filtering' attribute.
groups:
- neurodata_type_inc: ElectricalSeries
doc: ElectricalSeries object(s) containing LFP data for one or more channels.
quantity: '+'

- neurodata_type_def: ElectrodeGroup
neurodata_type_inc: NWBContainer
doc: A physical grouping of electrodes, e.g. a shank of an array.
attributes:
- name: description
dtype: text
doc: Description of this electrode group.
- name: location
dtype: text
doc: Location of electrode group. Specify the area, layer, comments on estimation
of area/layer, etc. Use standard atlas names for anatomical regions when possible.
datasets:
- name: position
dtype:
- name: x
dtype: float32
doc: x coordinate
- name: y
dtype: float32
doc: y coordinate
- name: z
dtype: float32
doc: z coordinate
doc: stereotaxic or common framework coordinates
quantity: '?'
links:
- name: device
target_type: Device
doc: Link to the device that was used to record from this electrode group.

# The types below have been deprecated
- neurodata_type_def: ClusterWaveforms
neurodata_type_inc: NWBDataInterface
default_name: ClusterWaveforms
doc: DEPRECATED The mean waveform shape, including standard deviation, of the different
clusters. Ideally, the waveform analysis should be performed on data that is only
high-pass filtered. This is a separate module because it is expected to require
updating. For example, IMEC probes may require different storage requirements
to store/display mean waveforms, requiring a new interface or an extension of
this one.
datasets:
- name: waveform_filtering
dtype: text
doc: Filtering applied to data before generating mean/sd
- name: waveform_mean
dtype: float32
dims:
- num_clusters
- num_samples
shape:
- null
- null
doc: The mean waveform for each cluster, using the same indices for each wave
as cluster numbers in the associated Clustering module (i.e, cluster 3 is in
array slot [3]). Waveforms corresponding to gaps in cluster sequence should
be empty (e.g., zero- filled)
- name: waveform_sd
dtype: float32
dims:
- num_clusters
- num_samples
shape:
- null
- null
doc: Stdev of waveforms for each cluster, using the same indices as in mean
links:
- name: clustering_interface
target_type: Clustering
doc: Link to Clustering interface that was the source of the clustered data

- neurodata_type_def: Clustering
neurodata_type_inc: NWBDataInterface
default_name: Clustering
doc: DEPRECATED Clustered spike data, whether from automatic clustering tools (e.g.,
klustakwik) or as a result of manual sorting.
datasets:
- name: description
dtype: text
doc: Description of clusters or clustering, (e.g. cluster 0 is noise, clusters
curated using Klusters, etc)
- name: num
dtype: int32
dims:
- num_events
shape:
- null
doc: Cluster number of each event
- name: peak_over_rms
dtype: float32
dims:
- num_clusters
shape:
- null
doc: Maximum ratio of waveform peak to RMS on any channel in the cluster (provides
a basic clustering metric).
- name: times
dtype: float64
dims:
- num_events
shape:
- null
doc: Times of clustered events, in seconds. This may be a link to times field
in associated FeatureExtraction module.
31 changes: 31 additions & 0 deletions nwb-schema/2.6.0/core/nwb.epoch.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
groups:
- neurodata_type_def: TimeIntervals
neurodata_type_inc: DynamicTable
doc: A container for aggregating epoch data and the TimeSeries that each epoch applies
to.
datasets:
- name: start_time
neurodata_type_inc: VectorData
dtype: float32
doc: Start time of epoch, in seconds.
- name: stop_time
neurodata_type_inc: VectorData
dtype: float32
doc: Stop time of epoch, in seconds.
- name: tags
neurodata_type_inc: VectorData
dtype: text
doc: User-defined tags that identify or categorize events.
quantity: '?'
- name: tags_index
neurodata_type_inc: VectorIndex
doc: Index for tags.
quantity: '?'
- name: timeseries
neurodata_type_inc: TimeSeriesReferenceVectorData
doc: An index into a TimeSeries object.
quantity: '?'
- name: timeseries_index
neurodata_type_inc: VectorIndex
doc: Index for timeseries.
quantity: '?'
502 changes: 502 additions & 0 deletions nwb-schema/2.6.0/core/nwb.file.yaml

Large diffs are not rendered by default.

426 changes: 426 additions & 0 deletions nwb-schema/2.6.0/core/nwb.icephys.yaml

Large diffs are not rendered by default.

222 changes: 222 additions & 0 deletions nwb-schema/2.6.0/core/nwb.image.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,222 @@
datasets:
- neurodata_type_def: GrayscaleImage
neurodata_type_inc: Image
dims:
- x
- y
shape:
- null
- null
doc: A grayscale image.
dtype: numeric

- neurodata_type_def: RGBImage
neurodata_type_inc: Image
dims:
- x
- y
- r, g, b
shape:
- null
- null
- 3
doc: A color image.
dtype: numeric

- neurodata_type_def: RGBAImage
neurodata_type_inc: Image
dims:
- x
- y
- r, g, b, a
shape:
- null
- null
- 4
doc: A color image with transparency.
dtype: numeric

groups:
- neurodata_type_def: ImageSeries
neurodata_type_inc: TimeSeries
doc: General image data that is common between acquisition and stimulus time series.
Sometimes the image data is stored in the file in a raw format while other
times it will be stored as a series of external image files in the host file system.
The data field will either be binary data, if the data is stored in the NWB file, or
empty, if the data is stored in an external image stack. [frame][x][y] or [frame][x][y][z].
datasets:
- name: data
dtype: numeric
dims:
- - frame
- x
- y
- - frame
- x
- y
- z
shape:
- - null
- null
- null
- - null
- null
- null
- null
doc: Binary data representing images across frames. If data are stored in an external
file, this should be an empty 3D array.
- name: dimension
dtype: int32
dims:
- rank
shape:
- null
doc: Number of pixels on x, y, (and z) axes.
quantity: '?'
- name: external_file
dtype: text
dims:
- num_files
shape:
- null
doc: Paths to one or more external file(s). The field is only present if format='external'.
This is only relevant if the image series is stored in the file system as one
or more image file(s). This field should NOT be used if the image is stored
in another NWB file and that file is linked to this file.
quantity: '?'
attributes:
- name: starting_frame
dtype: int32
dims:
- num_files
shape:
- null
doc: Each external image may contain one or more consecutive frames of the full
ImageSeries. This attribute serves as an index to indicate which frames each file
contains, to faciliate random access. The 'starting_frame' attribute, hence,
contains a list of frame numbers within the full ImageSeries of the first frame
of each file listed in the parent 'external_file' dataset. Zero-based indexing is
used (hence, the first element will always be zero). For example, if the
'external_file' dataset has three paths to files and the first file has 5 frames,
the second file has 10 frames, and the third file has 20 frames, then this
attribute will have values [0, 5, 15]. If there is a single external file that
holds all of the frames of the ImageSeries (and so there is a single element in
the 'external_file' dataset), then this attribute should have value [0].
- name: format
dtype: text
default_value: raw
doc: Format of image. If this is 'external', then the attribute 'external_file'
contains the path information to the image files. If this is 'raw', then the raw
(single-channel) binary data is stored in the 'data' dataset. If this attribute
is not present, then the default format='raw' case is assumed.
quantity: '?'
links:
- name: device
target_type: Device
doc: Link to the Device object that was used to capture these images.
quantity: '?'

- neurodata_type_def: ImageMaskSeries
neurodata_type_inc: ImageSeries
doc: An alpha mask that is applied to a presented visual stimulus. The 'data' array
contains an array of mask values that are applied to the displayed image. Mask
values are stored as RGBA. Mask can vary with time. The timestamps array indicates
the starting time of a mask, and that mask pattern continues until it's explicitly
changed.
links:
- name: masked_imageseries
target_type: ImageSeries
doc: Link to ImageSeries object that this image mask is applied to.

- neurodata_type_def: OpticalSeries
neurodata_type_inc: ImageSeries
doc: Image data that is presented or recorded. A stimulus template movie will be
stored only as an image. When the image is presented as stimulus, additional data
is required, such as field of view (e.g., how much of the visual field the image
covers, or how what is the area of the target being imaged). If the OpticalSeries
represents acquired imaging data, orientation is also important.
datasets:
- name: distance
dtype: float32
doc: Distance from camera/monitor to target/eye.
quantity: '?'
- name: field_of_view
dtype: float32
dims:
- - width, height
- - width, height, depth
shape:
- - 2
- - 3
doc: Width, height and depth of image, or imaged area, in meters.
quantity: '?'
- name: data
dtype: numeric
dims:
- - frame
- x
- y
- - frame
- x
- y
- r, g, b
shape:
- - null
- null
- null
- - null
- null
- null
- 3
doc: Images presented to subject, either grayscale or RGB
- name: orientation
dtype: text
doc: Description of image relative to some reference frame (e.g., which way is
up). Must also specify frame of reference.
quantity: '?'

- neurodata_type_def: IndexSeries
neurodata_type_inc: TimeSeries
doc: Stores indices to image frames stored in an ImageSeries. The purpose of the
IndexSeries is to allow a static image stack to be stored in an Images
object, and the images in the stack to be referenced out-of-order. This can be for
the display of individual images, or of movie segments (as a movie is simply a
series of images). The data field stores the index of the frame in the referenced
Images object, and the timestamps array indicates when that image
was displayed.
datasets:
- name: data
dtype: uint32
dims:
- num_times
shape:
- null
doc: Index of the image (using zero-indexing) in the linked Images object.
attributes:
- name: conversion
dtype: float32
doc: This field is unused by IndexSeries.
required: false
- name: resolution
dtype: float32
doc: This field is unused by IndexSeries.
required: false
- name: offset
dtype: float32
doc: This field is unused by IndexSeries.
required: false
- name: unit
dtype: text
value: N/A
doc: This field is unused by IndexSeries and has the value N/A.
links:
- name: indexed_timeseries
target_type: ImageSeries
doc: Link to ImageSeries object containing images that are indexed. Use of this link
is discouraged and will be deprecated. Link to an Images type instead.
quantity: '?'
- name: indexed_images
target_type: Images
doc: Link to Images object containing an ordered set of images that are indexed. The Images object
must contain a 'ordered_images' dataset specifying the order of the images in the Images type.
quantity: '?'
329 changes: 329 additions & 0 deletions nwb-schema/2.6.0/core/nwb.misc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,329 @@
groups:
- neurodata_type_def: AbstractFeatureSeries
neurodata_type_inc: TimeSeries
doc: Abstract features, such as quantitative descriptions of sensory stimuli. The
TimeSeries::data field is a 2D array, storing those features (e.g., for visual
grating stimulus this might be orientation, spatial frequency and contrast). Null
stimuli (eg, uniform gray) can be marked as being an independent feature (eg,
1.0 for gray, 0.0 for actual stimulus) or by storing NaNs for feature values,
or through use of the TimeSeries::control fields. A set of features is considered
to persist until the next set of features is defined. The final set of features
stored should be the null set. This is useful when storing the raw stimulus
is impractical.
datasets:
- name: data
dtype: numeric
dims:
- - num_times
- - num_times
- num_features
shape:
- - null
- - null
- null
doc: Values of each feature at each time.
attributes:
- name: unit
dtype: text
default_value: see 'feature_units'
doc: Since there can be different units for different features, store the units
in 'feature_units'. The default value for this attribute is "see 'feature_units'".
required: false
- name: feature_units
dtype: text
dims:
- num_features
shape:
- null
doc: Units of each feature.
quantity: '?'
- name: features
dtype: text
dims:
- num_features
shape:
- null
doc: Description of the features represented in TimeSeries::data.

- neurodata_type_def: AnnotationSeries
neurodata_type_inc: TimeSeries
doc: Stores user annotations made during an experiment. The data[]
field stores a text array, and timestamps are stored for each annotation (ie,
interval=1). This is largely an alias to a standard TimeSeries storing a text
array but that is identifiable as storing annotations in a machine-readable way.
datasets:
- name: data
dtype: text
dims:
- num_times
shape:
- null
doc: Annotations made during an experiment.
attributes:
- name: resolution
dtype: float32
value: -1.0
doc: Smallest meaningful difference between values in data. Annotations have
no units, so the value is fixed to -1.0.
- name: unit
dtype: text
value: n/a
doc: Base unit of measurement for working with the data. Annotations have
no units, so the value is fixed to 'n/a'.

- neurodata_type_def: IntervalSeries
neurodata_type_inc: TimeSeries
doc: Stores intervals of data. The timestamps field stores the beginning and end
of intervals. The data field stores whether the interval just started (>0 value)
or ended (<0 value). Different interval types can be represented in the same series
by using multiple key values (eg, 1 for feature A, 2 for feature B, 3 for feature
C, etc). The field data stores an 8-bit integer. This is largely an alias of a
standard TimeSeries but that is identifiable as representing time intervals in
a machine-readable way.
datasets:
- name: data
dtype: int8
dims:
- num_times
shape:
- null
doc: Use values >0 if interval started, <0 if interval ended.
attributes:
- name: resolution
dtype: float32
value: -1.0
doc: Smallest meaningful difference between values in data. Annotations have
no units, so the value is fixed to -1.0.
- name: unit
dtype: text
value: n/a
doc: Base unit of measurement for working with the data. Annotations have
no units, so the value is fixed to 'n/a'.

- neurodata_type_def: DecompositionSeries
neurodata_type_inc: TimeSeries
doc: Spectral analysis of a time series, e.g. of an LFP or a speech signal.
datasets:
- name: data
dtype: numeric
dims:
- num_times
- num_channels
- num_bands
shape:
- null
- null
- null
doc: Data decomposed into frequency bands.
attributes:
- name: unit
dtype: text
default_value: no unit
doc: Base unit of measurement for working with the data. Actual stored values are
not necessarily stored in these units. To access the data in these units,
multiply 'data' by 'conversion'.
- name: metric
dtype: text
doc: The metric used, e.g. phase, amplitude, power.
- name: source_channels
neurodata_type_inc: DynamicTableRegion
doc: DynamicTableRegion pointer to the channels that this decomposition series was generated from.
quantity: '?'
groups:
- name: bands
neurodata_type_inc: DynamicTable
doc: Table for describing the bands that this series was generated from. There
should be one row in this table for each band.
datasets:
- name: band_name
neurodata_type_inc: VectorData
dtype: text
doc: Name of the band, e.g. theta.
- name: band_limits
neurodata_type_inc: VectorData
dtype: float32
dims:
- num_bands
- low, high
shape:
- null
- 2
doc: Low and high limit of each band in Hz. If it is a Gaussian filter, use
2 SD on either side of the center.
- name: band_mean
neurodata_type_inc: VectorData
dtype: float32
dims:
- num_bands
shape:
- null
doc: The mean Gaussian filters, in Hz.
- name: band_stdev
neurodata_type_inc: VectorData
dtype: float32
dims:
- num_bands
shape:
- null
doc: The standard deviation of Gaussian filters, in Hz.
links:
- name: source_timeseries
target_type: TimeSeries
doc: Link to TimeSeries object that this data was calculated from. Metadata about
electrodes and their position can be read from that ElectricalSeries so it is
not necessary to store that information here.
quantity: '?'

- neurodata_type_def: Units
neurodata_type_inc: DynamicTable
default_name: Units
doc: Data about spiking units. Event times of observed units (e.g. cell, synapse,
etc.) should be concatenated and stored in spike_times.
datasets:
- name: spike_times_index
neurodata_type_inc: VectorIndex
doc: Index into the spike_times dataset.
quantity: '?'
- name: spike_times
neurodata_type_inc: VectorData
dtype: float64
doc: Spike times for each unit in seconds.
quantity: '?'
attributes:
- name: resolution
dtype: float64
doc: The smallest possible difference between two spike times. Usually 1 divided by the acquisition sampling rate
from which spike times were extracted, but could be larger if the acquisition time series was downsampled or
smaller if the acquisition time series was smoothed/interpolated and it is possible for the spike time to be
between samples.
required: false
- name: obs_intervals_index
neurodata_type_inc: VectorIndex
doc: Index into the obs_intervals dataset.
quantity: '?'
- name: obs_intervals
neurodata_type_inc: VectorData
dtype: float64
dims:
- num_intervals
- start|end
shape:
- null
- 2
doc: Observation intervals for each unit.
quantity: '?'
- name: electrodes_index
neurodata_type_inc: VectorIndex
doc: Index into electrodes.
quantity: '?'
- name: electrodes
neurodata_type_inc: DynamicTableRegion
doc: Electrode that each spike unit came from, specified using a DynamicTableRegion.
quantity: '?'
- name: electrode_group
neurodata_type_inc: VectorData
dtype:
target_type: ElectrodeGroup
reftype: object
doc: Electrode group that each spike unit came from.
quantity: '?'
- name: waveform_mean
neurodata_type_inc: VectorData
dtype: float32
dims:
- - num_units
- num_samples
- - num_units
- num_samples
- num_electrodes
shape:
- - null
- null
- - null
- null
- null
doc: Spike waveform mean for each spike unit.
quantity: '?'
attributes:
- name: sampling_rate
dtype: float32
doc: Sampling rate, in hertz.
required: false
- name: unit
dtype: text
value: volts
doc: Unit of measurement. This value is fixed to 'volts'.
required: false
- name: waveform_sd
neurodata_type_inc: VectorData
dtype: float32
dims:
- - num_units
- num_samples
- - num_units
- num_samples
- num_electrodes
shape:
- - null
- null
- - null
- null
- null
doc: Spike waveform standard deviation for each spike unit.
quantity: '?'
attributes:
- name: sampling_rate
dtype: float32
doc: Sampling rate, in hertz.
required: false
- name: unit
dtype: text
value: volts
doc: Unit of measurement. This value is fixed to 'volts'.
required: false
- name: waveforms
neurodata_type_inc: VectorData
dtype: numeric
dims:
- num_waveforms
- num_samples
shape:
- null
- null
doc: "Individual waveforms for each spike on each electrode. This is a doubly indexed column. The 'waveforms_index'
column indexes which waveforms in this column belong to the same spike event for a given unit, where each waveform
was recorded from a different electrode. The 'waveforms_index_index' column indexes the 'waveforms_index' column
to indicate which spike events belong to a given unit. For example, if the
'waveforms_index_index' column has values [2, 5, 6], then the first 2 elements of the 'waveforms_index' column
correspond to the 2 spike events of the first unit, the next 3 elements of the 'waveforms_index' column correspond
to the 3 spike events of the second unit, and the next 1 element of the 'waveforms_index' column corresponds to
the 1 spike event of the third unit. If the 'waveforms_index' column has values [3, 6, 8, 10, 12, 13], then
the first 3 elements of the 'waveforms' column contain the 3 spike waveforms that were recorded from 3 different
electrodes for the first spike time of the first unit. See
https://nwb-schema.readthedocs.io/en/stable/format_description.html#doubly-ragged-arrays for a graphical
representation of this example. When there is only one electrode for each unit (i.e., each spike time is
associated with a single waveform), then the 'waveforms_index' column will have values 1, 2, ..., N, where N is
the number of spike events. The number of electrodes for each spike event should be the same within a given unit.
The 'electrodes' column should be used to indicate which electrodes are associated with each unit, and the order
of the waveforms within a given unit x spike event should be in the same order as the electrodes referenced in
the 'electrodes' column of this table. The number of samples for each waveform must be the same."
quantity: '?'
attributes:
- name: sampling_rate
dtype: float32
doc: Sampling rate, in hertz.
required: false
- name: unit
dtype: text
value: volts
doc: Unit of measurement. This value is fixed to 'volts'.
required: false
- name: waveforms_index
neurodata_type_inc: VectorIndex
doc: Index into the waveforms dataset. One value for every spike event. See 'waveforms' for more detail.
quantity: '?'
- name: waveforms_index_index
neurodata_type_inc: VectorIndex
doc: Index into the waveforms_index dataset. One value for every unit (row in the table). See 'waveforms' for more
detail.
quantity: '?'
60 changes: 60 additions & 0 deletions nwb-schema/2.6.0/core/nwb.namespace.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
namespaces:
- name: core
doc: NWB namespace
author:
- Andrew Tritt
- Oliver Ruebel
- Ryan Ly
- Ben Dichter
- Keith Godfrey
- Jeff Teeters
contact:
- ajtritt@lbl.gov
- oruebel@lbl.gov
- rly@lbl.gov
- bdichter@lbl.gov
- keithg@alleninstitute.org
- jteeters@berkeley.edu
full_name: NWB core
schema:
- namespace: hdmf-common
- doc: This source module contains base data types used throughout the NWB:N data
format.
source: nwb.base.yaml
title: Base data types
- doc: This source module contains neurodata_types for device data.
source: nwb.device.yaml
title: Devices
- doc: This source module contains neurodata_types for epoch data.
source: nwb.epoch.yaml
title: Epochs
- doc: This source module contains neurodata_types for image data.
source: nwb.image.yaml
title: Image data
- doc: Main NWB:N file specification.
source: nwb.file.yaml
title: NWB:N file
- doc: Miscellaneous types.
source: nwb.misc.yaml
title: Miscellaneous neurodata_types.
- doc: This source module contains neurodata_types for behavior data.
source: nwb.behavior.yaml
title: Behavior
- doc: This source module contains neurodata_types for extracellular electrophysiology
data.
source: nwb.ecephys.yaml
title: Extracellular electrophysiology
- doc: This source module contains neurodata_types for intracellular electrophysiology
data.
source: nwb.icephys.yaml
title: Intracellular electrophysiology
- doc: This source module contains neurodata_types for opto-genetics data.
source: nwb.ogen.yaml
title: Optogenetics
- doc: This source module contains neurodata_types for optical physiology data.
source: nwb.ophys.yaml
title: Optical physiology
- doc: This source module contains neurodata_type for retinotopy data.
source: nwb.retinotopy.yaml
title: Retinotopy
version: "2.6.0-alpha"
42 changes: 42 additions & 0 deletions nwb-schema/2.6.0/core/nwb.ogen.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
groups:
- neurodata_type_def: OptogeneticSeries
neurodata_type_inc: TimeSeries
doc: An optogenetic stimulus.
datasets:
- name: data
dtype: numeric
dims:
- num_times
shape:
- null
doc: Applied power for optogenetic stimulus, in watts.
attributes:
- name: unit
dtype: text
value: watts
doc: Unit of measurement for data, which is fixed to 'watts'.
links:
- name: site
target_type: OptogeneticStimulusSite
doc: Link to OptogeneticStimulusSite object that describes the site to which this
stimulus was applied.

- neurodata_type_def: OptogeneticStimulusSite
neurodata_type_inc: NWBContainer
doc: A site of optogenetic stimulation.
datasets:
- name: description
dtype: text
doc: Description of stimulation site.
- name: excitation_lambda
dtype: float32
doc: Excitation wavelength, in nm.
- name: location
dtype: text
doc: Location of the stimulation site. Specify the area, layer, comments on estimation
of area/layer, stereotaxic coordinates if in vivo, etc. Use standard atlas
names for anatomical regions when possible.
links:
- name: device
target_type: Device
doc: Device that generated the stimulus.
360 changes: 360 additions & 0 deletions nwb-schema/2.6.0/core/nwb.ophys.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,360 @@
groups:
- neurodata_type_def: OnePhotonSeries
neurodata_type_inc: ImageSeries
doc: Image stack recorded over time from 1-photon microscope.
attributes:
- name: pmt_gain
dtype: float32
doc: Photomultiplier gain.
required: false
- name: scan_line_rate
dtype: float32
doc: Lines imaged per second. This is also stored in /general/optophysiology but
is kept here as it is useful information for analysis, and so good to be stored
w/ the actual data.
required: false
- name: exposure_time
dtype: float32
doc: Exposure time of the sample; often the inverse of the frequency.
required: false
- name: binning
dtype: uint8
doc: Amount of pixels combined into 'bins'; could be 1, 2, 4, 8, etc.
required: false
- name: power
dtype: float32
doc: Power of the excitation in mW, if known.
required: false
- name: intensity
dtype: float32
doc: Intensity of the excitation in mW/mm^2, if known.
required: false
links:
- name: imaging_plane
target_type: ImagingPlane
doc: Link to ImagingPlane object from which this TimeSeries data was generated.

- neurodata_type_def: TwoPhotonSeries
neurodata_type_inc: ImageSeries
doc: Image stack recorded over time from 2-photon microscope.
attributes:
- name: pmt_gain
dtype: float32
doc: Photomultiplier gain.
required: false
- name: scan_line_rate
dtype: float32
doc: Lines imaged per second. This is also stored in /general/optophysiology but
is kept here as it is useful information for analysis, and so good to be stored
w/ the actual data.
required: false
datasets:
- name: field_of_view
dtype: float32
dims:
- - width|height
- - width|height|depth
shape:
- - 2
- - 3
doc: Width, height and depth of image, or imaged area, in meters.
quantity: '?'
links:
- name: imaging_plane
target_type: ImagingPlane
doc: Link to ImagingPlane object from which this TimeSeries data was generated.

- neurodata_type_def: RoiResponseSeries
neurodata_type_inc: TimeSeries
doc: ROI responses over an imaging plane. The first dimension represents time.
The second dimension, if present, represents ROIs.
datasets:
- name: data
dtype: numeric
dims:
- - num_times
- - num_times
- num_ROIs
shape:
- - null
- - null
- null
doc: Signals from ROIs.
- name: rois
neurodata_type_inc: DynamicTableRegion
doc: DynamicTableRegion referencing into an ROITable containing information on the ROIs
stored in this timeseries.

- neurodata_type_def: DfOverF
neurodata_type_inc: NWBDataInterface
default_name: DfOverF
doc: dF/F information about a region of interest (ROI). Storage hierarchy of dF/F
should be the same as for segmentation (i.e., same names for ROIs and for image
planes).
groups:
- neurodata_type_inc: RoiResponseSeries
doc: RoiResponseSeries object(s) containing dF/F for a ROI.
quantity: '+'

- neurodata_type_def: Fluorescence
neurodata_type_inc: NWBDataInterface
default_name: Fluorescence
doc: Fluorescence information about a region of interest (ROI). Storage hierarchy
of fluorescence should be the same as for segmentation (ie, same names for ROIs
and for image planes).
groups:
- neurodata_type_inc: RoiResponseSeries
doc: RoiResponseSeries object(s) containing fluorescence data for a ROI.
quantity: '+'

- neurodata_type_def: ImageSegmentation
neurodata_type_inc: NWBDataInterface
default_name: ImageSegmentation
doc: Stores pixels in an image that represent different regions of interest (ROIs)
or masks. All segmentation for a given imaging plane is stored together, with
storage for multiple imaging planes (masks) supported. Each ROI is stored in its
own subgroup, with the ROI group containing both a 2D mask and a list of pixels
that make up this mask. Segments can also be used for masking neuropil. If segmentation
is allowed to change with time, a new imaging plane (or module) is required and
ROI names should remain consistent between them.
groups:
- neurodata_type_inc: PlaneSegmentation
doc: Results from image segmentation of a specific imaging plane.
quantity: '+'

- neurodata_type_def: PlaneSegmentation
neurodata_type_inc: DynamicTable
doc: Results from image segmentation of a specific imaging plane.
datasets:
- name: image_mask
neurodata_type_inc: VectorData
dims:
- - num_roi
- num_x
- num_y
- - num_roi
- num_x
- num_y
- num_z
shape:
- - null
- null
- null
- - null
- null
- null
- null
doc: ROI masks for each ROI. Each image mask is the size of the original imaging
plane (or volume) and members of the ROI are finite non-zero.
quantity: '?'
- name: pixel_mask_index
neurodata_type_inc: VectorIndex
doc: Index into pixel_mask.
quantity: '?'
- name: pixel_mask
neurodata_type_inc: VectorData
dtype:
- name: x
dtype: uint32
doc: Pixel x-coordinate.
- name: y
dtype: uint32
doc: Pixel y-coordinate.
- name: weight
dtype: float32
doc: Weight of the pixel.
doc: 'Pixel masks for each ROI: a list of indices and weights for the ROI. Pixel
masks are concatenated and parsing of this dataset is maintained by the PlaneSegmentation'
quantity: '?'
- name: voxel_mask_index
neurodata_type_inc: VectorIndex
doc: Index into voxel_mask.
quantity: '?'
- name: voxel_mask
neurodata_type_inc: VectorData
dtype:
- name: x
dtype: uint32
doc: Voxel x-coordinate.
- name: y
dtype: uint32
doc: Voxel y-coordinate.
- name: z
dtype: uint32
doc: Voxel z-coordinate.
- name: weight
dtype: float32
doc: Weight of the voxel.
doc: 'Voxel masks for each ROI: a list of indices and weights for the ROI. Voxel
masks are concatenated and parsing of this dataset is maintained by the PlaneSegmentation'
quantity: '?'
groups:
- name: reference_images
doc: Image stacks that the segmentation masks apply to.
groups:
- neurodata_type_inc: ImageSeries
doc: One or more image stacks that the masks apply to (can be one-element
stack).
quantity: '*'
links:
- name: imaging_plane
target_type: ImagingPlane
doc: Link to ImagingPlane object from which this data was generated.

- neurodata_type_def: ImagingPlane
neurodata_type_inc: NWBContainer
doc: An imaging plane and its metadata.
datasets:
- name: description
dtype: text
doc: Description of the imaging plane.
quantity: '?'
- name: excitation_lambda
dtype: float32
doc: Excitation wavelength, in nm.
- name: imaging_rate
dtype: float32
doc: Rate that images are acquired, in Hz. If the corresponding TimeSeries is present, the rate should be stored
there instead.
quantity: '?'
- name: indicator
dtype: text
doc: Calcium indicator.
- name: location
dtype: text
doc: Location of the imaging plane. Specify the area, layer, comments on estimation
of area/layer, stereotaxic coordinates if in vivo, etc. Use standard atlas
names for anatomical regions when possible.
- name: manifold
dtype: float32
dims:
- - height
- width
- x, y, z
- - height
- width
- depth
- x, y, z
shape:
- - null
- null
- 3
- - null
- null
- null
- 3
doc: "DEPRECATED Physical position of each pixel. 'xyz' represents the position\
\ of the pixel relative to the defined coordinate space. Deprecated in favor of origin_coords and grid_spacing."
quantity: '?'
attributes:
- name: conversion
dtype: float32
default_value: 1.0
doc: Scalar to multiply each element in data to convert it to the specified 'unit'.
If the data are stored in acquisition system units or other units
that require a conversion to be interpretable, multiply the data by 'conversion'
to convert the data to the specified 'unit'. e.g. if the data acquisition system
stores values in this object as pixels from x = -500 to 499, y = -500 to 499
that correspond to a 2 m x 2 m range, then the 'conversion' multiplier to get
from raw data acquisition pixel units to meters is 2/1000.
required: false
- name: unit
dtype: text
default_value: meters
doc: Base unit of measurement for working with the data. The default value is 'meters'.
required: false
- name: origin_coords
dtype: float32
dims:
- - x, y
- - x, y, z
shape:
- - 2
- - 3
doc: Physical location of the first element of the imaging plane (0, 0) for 2-D data or (0, 0, 0) for 3-D data.
See also reference_frame for what the physical location is relative to (e.g., bregma).
quantity: '?'
attributes:
- name: unit
dtype: text
default_value: meters
doc: Measurement units for origin_coords. The default value is 'meters'.
- name: grid_spacing
dtype: float32
dims:
- - x, y
- - x, y, z
shape:
- - 2
- - 3
doc: Space between pixels in (x, y) or voxels in (x, y, z) directions, in the specified unit.
Assumes imaging plane is a regular grid. See also reference_frame to interpret the grid.
quantity: '?'
attributes:
- name: unit
dtype: text
default_value: meters
doc: Measurement units for grid_spacing. The default value is 'meters'.
- name: reference_frame
dtype: text
doc: Describes reference frame of origin_coords and grid_spacing.
For example, this can be a text description of the anatomical location and orientation of the grid
defined by origin_coords and grid_spacing or the vectors needed to transform or rotate the grid to
a common anatomical axis (e.g., AP/DV/ML). This field is necessary to interpret origin_coords and grid_spacing.
If origin_coords and grid_spacing are not present, then this field is not required.
For example, if the microscope takes 10 x 10 x 2 images, where the first value of the data matrix
(index (0, 0, 0)) corresponds to (-1.2, -0.6, -2) mm relative to bregma, the spacing between pixels is 0.2 mm in
x, 0.2 mm in y and 0.5 mm in z, and larger numbers in x means more anterior, larger numbers in y means more
rightward, and larger numbers in z means more ventral, then enter the following --
origin_coords = (-1.2, -0.6, -2)
grid_spacing = (0.2, 0.2, 0.5)
reference_frame = "Origin coordinates are relative to bregma. First dimension corresponds to anterior-posterior
axis (larger index = more anterior). Second dimension corresponds to medial-lateral axis (larger index = more
rightward). Third dimension corresponds to dorsal-ventral axis (larger index = more ventral)."
quantity: '?'
groups:
- neurodata_type_inc: OpticalChannel
doc: An optical channel used to record from an imaging plane.
quantity: '+'
links:
- name: device
target_type: Device
doc: Link to the Device object that was used to record from this electrode.

- neurodata_type_def: OpticalChannel
neurodata_type_inc: NWBContainer
doc: An optical channel used to record from an imaging plane.
datasets:
- name: description
dtype: text
doc: Description or other notes about the channel.
- name: emission_lambda
dtype: float32
doc: Emission wavelength for channel, in nm.

- neurodata_type_def: MotionCorrection
neurodata_type_inc: NWBDataInterface
default_name: MotionCorrection
doc: 'An image stack where all frames are shifted (registered) to a common coordinate
system, to account for movement and drift between frames. Note: each frame at
each point in time is assumed to be 2-D (has only x & y dimensions).'
groups:
- neurodata_type_inc: CorrectedImageStack
doc: Reuslts from motion correction of an image stack.
quantity: '+'

- neurodata_type_def: CorrectedImageStack
neurodata_type_inc: NWBDataInterface
doc: Reuslts from motion correction of an image stack.
groups:
- name: corrected
neurodata_type_inc: ImageSeries
doc: Image stack with frames shifted to the common coordinates.
- name: xy_translation
neurodata_type_inc: TimeSeries
doc: Stores the x,y delta necessary to align each frame to the common coordinates,
for example, to align each frame to a reference image.
links:
- name: original
target_type: ImageSeries
doc: Link to ImageSeries object that is being registered.
234 changes: 234 additions & 0 deletions nwb-schema/2.6.0/core/nwb.retinotopy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,234 @@
groups:
- neurodata_type_def: ImagingRetinotopy
neurodata_type_inc: NWBDataInterface
default_name: ImagingRetinotopy
doc: 'Intrinsic signal optical imaging or widefield imaging for measuring retinotopy.
Stores orthogonal maps (e.g., altitude/azimuth; radius/theta) of responses to
specific stimuli and a combined polarity map from which to identify visual areas.
This group does not store the raw responses imaged during retinotopic mapping or the
stimuli presented, but rather the resulting phase and power maps after applying a Fourier
transform on the averaged responses.
Note: for data consistency, all images and arrays are stored in the format [row][column]
and [row, col], which equates to [y][x]. Field of view and dimension arrays may
appear backward (i.e., y before x).'
datasets:
- name: axis_1_phase_map
dtype: float32
dims:
- num_rows
- num_cols
shape:
- null
- null
doc: Phase response to stimulus on the first measured axis.
attributes:
- name: dimension
dtype: int32
dims:
- num_rows, num_cols
shape:
- 2
doc: 'Number of rows and columns in the image. NOTE: row, column representation
is equivalent to height, width.'
- name: field_of_view
dtype: float32
dims:
- height, width
shape:
- 2
doc: Size of viewing area, in meters.
- name: unit
dtype: text
doc: Unit that axis data is stored in (e.g., degrees).
- name: axis_1_power_map
dtype: float32
dims:
- num_rows
- num_cols
shape:
- null
- null
doc: Power response on the first measured axis. Response is scaled so 0.0 is no
power in the response and 1.0 is maximum relative power.
quantity: '?'
attributes:
- name: dimension
dtype: int32
dims:
- num_rows, num_cols
shape:
- 2
doc: 'Number of rows and columns in the image. NOTE: row, column representation
is equivalent to height, width.'
- name: field_of_view
dtype: float32
dims:
- height, width
shape:
- 2
doc: Size of viewing area, in meters.
- name: unit
dtype: text
doc: Unit that axis data is stored in (e.g., degrees).
- name: axis_2_phase_map
dtype: float32
dims:
- num_rows
- num_cols
shape:
- null
- null
doc: Phase response to stimulus on the second measured axis.
attributes:
- name: dimension
dtype: int32
dims:
- num_rows, num_cols
shape:
- 2
doc: 'Number of rows and columns in the image. NOTE: row, column representation
is equivalent to height, width.'
- name: field_of_view
dtype: float32
dims:
- height, width
shape:
- 2
doc: Size of viewing area, in meters.
- name: unit
dtype: text
doc: Unit that axis data is stored in (e.g., degrees).
- name: axis_2_power_map
dtype: float32
dims:
- num_rows
- num_cols
shape:
- null
- null
doc: Power response on the second measured axis. Response is scaled so 0.0 is
no power in the response and 1.0 is maximum relative power.
quantity: '?'
attributes:
- name: dimension
dtype: int32
dims:
- num_rows, num_cols
shape:
- 2
doc: 'Number of rows and columns in the image. NOTE: row, column representation
is equivalent to height, width.'
- name: field_of_view
dtype: float32
dims:
- height, width
shape:
- 2
doc: Size of viewing area, in meters.
- name: unit
dtype: text
doc: Unit that axis data is stored in (e.g., degrees).
- name: axis_descriptions
dtype: text
dims:
- axis_1, axis_2
shape:
- 2
doc: Two-element array describing the contents of the two response axis fields.
Description should be something like ['altitude', 'azimuth'] or '['radius',
'theta'].
- name: focal_depth_image
dtype: uint16
dims:
- num_rows
- num_cols
shape:
- null
- null
doc: 'Gray-scale image taken with same settings/parameters (e.g., focal depth,
wavelength) as data collection. Array format: [rows][columns].'
quantity: '?'
attributes:
- name: bits_per_pixel
dtype: int32
doc: Number of bits used to represent each value. This is necessary to determine
maximum (white) pixel value.
- name: dimension
dtype: int32
dims:
- num_rows, num_cols
shape:
- 2
doc: 'Number of rows and columns in the image. NOTE: row, column representation
is equivalent to height, width.'
- name: field_of_view
dtype: float32
dims:
- height, width
shape:
- 2
doc: Size of viewing area, in meters.
- name: focal_depth
dtype: float32
doc: Focal depth offset, in meters.
- name: format
dtype: text
doc: Format of image. Right now only 'raw' is supported.
- name: sign_map
dtype: float32
dims:
- num_rows
- num_cols
shape:
- null
- null
doc: Sine of the angle between the direction of the gradient in axis_1 and axis_2.
quantity: '?'
attributes:
- name: dimension
dtype: int32
dims:
- num_rows, num_cols
shape:
- 2
doc: 'Number of rows and columns in the image. NOTE: row, column representation
is equivalent to height, width.'
- name: field_of_view
dtype: float32
dims:
- height, width
shape:
- 2
doc: Size of viewing area, in meters.
- name: vasculature_image
dtype: uint16
dims:
- num_rows
- num_cols
shape:
- null
- null
doc: 'Gray-scale anatomical image of cortical surface. Array structure: [rows][columns]'
attributes:
- name: bits_per_pixel
dtype: int32
doc: Number of bits used to represent each value. This is necessary to determine
maximum (white) pixel value
- name: dimension
dtype: int32
dims:
- num_rows, num_cols
shape:
- 2
doc: 'Number of rows and columns in the image. NOTE: row, column representation
is equivalent to height, width.'
- name: field_of_view
dtype: float32
dims:
- height, width
shape:
- 2
doc: Size of viewing area, in meters.
- name: format
dtype: text
doc: Format of image. Right now only 'raw' is supported.
21 changes: 21 additions & 0 deletions nwb-schema/2.6.0/hdmf-common-schema/common/base.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# hdmf-schema-language=2.0.2
datasets:
- data_type_def: Data
doc: An abstract data type for a dataset.

groups:
- data_type_def: Container
doc: An abstract data type for a group storing collections of data and
metadata. Base type for all data and metadata containers.

- data_type_def: SimpleMultiContainer
data_type_inc: Container
doc: A simple Container for holding onto multiple containers.
datasets:
- data_type_inc: Data
quantity: '*'
doc: Data objects held within this SimpleMultiContainer.
groups:
- data_type_inc: Container
quantity: '*'
doc: Container objects held within this SimpleMultiContainer.
14 changes: 14 additions & 0 deletions nwb-schema/2.6.0/hdmf-common-schema/common/experimental.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
groups: []
datasets:
- data_type_def: EnumData
data_type_inc: VectorData
dtype: uint8
doc: Data that come from a fixed set of values. A data value of i corresponds
to the i-th value in the VectorData referenced by the 'elements' attribute.
attributes:
- name: elements
dtype:
target_type: VectorData
reftype: object
doc: Reference to the VectorData object that contains the enumerable elements

49 changes: 49 additions & 0 deletions nwb-schema/2.6.0/hdmf-common-schema/common/namespace.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# hdmf-schema-language=2.0.2
namespaces:
- name: hdmf-common
doc: Common data structures provided by HDMF
author:
- Andrew Tritt
- Oliver Ruebel
- Ryan Ly
- Ben Dichter
contact:
- ajtritt@lbl.gov
- oruebel@lbl.gov
- rly@lbl.gov
- bdichter@lbl.gov
full_name: HDMF Common
schema:
- doc: base data types
source: base.yaml
title: Base data types
- doc: data types for a column-based table
source: table.yaml
title: Table data types
- doc: data types for different types of sparse matrices
source: sparse.yaml
title: Sparse data types
version: 1.5.0

- name: hdmf-experimental
doc: Experimental data structures provided by HDMF. These are not guaranteed to be available in the future
author:
- Andrew Tritt
- Oliver Ruebel
- Ryan Ly
- Ben Dichter
contact:
- ajtritt@lbl.gov
- oruebel@lbl.gov
- rly@lbl.gov
- bdichter@lbl.gov
full_name: HDMF Experimental
schema:
- namespace: hdmf-common
- doc: Experimental data types
source: experimental.yaml
title: Experimental data types
- doc: data types for storing references to web accessible resources
source: resources.yaml
title: Resource reference data types
version: 0.1.0
85 changes: 85 additions & 0 deletions nwb-schema/2.6.0/hdmf-common-schema/common/resources.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
# hdmf-schema-language=2.0.2
groups:
- data_type_def: ExternalResources
data_type_inc: Container
doc: "A set of four tables for tracking external resource references in a file. NOTE: this data type is in beta
testing and is subject to change in a later version."
datasets:
- data_type_inc: Data
name: keys
doc: A table for storing user terms that are used to refer to external resources.
dtype:
- name: key
dtype: text
doc: The user term that maps to one or more resources in the 'resources' table.
dims:
- num_rows
shape:
- null

- data_type_inc: Data
name: entities
doc: A table for mapping user terms (i.e., keys) to resource entities.
dtype:
- name: keys_idx
dtype: uint
doc: The index to the key in the 'keys' table.
- name: resources_idx
dtype: uint
doc: The index into the 'resources' table
- name: entity_id
dtype: text
doc: The unique identifier entity.
- name: entity_uri
dtype: text
doc: The URI for the entity this reference applies to. This can be an empty string.
dims:
- num_rows
shape:
- null

- data_type_inc: Data
name: resources
doc: A table for mapping user terms (i.e., keys) to resource entities.
dtype:
- name: resource
dtype: text
doc: The name of the resource.
- name: resource_uri
dtype: text
doc: The URI for the resource. This can be an empty string.
dims:
- num_rows
shape:
- null

- data_type_inc: Data
name: objects
doc: A table for identifying which objects in a file contain references to external resources.
dtype:
- name: object_id
dtype: text
doc: The UUID for the object.
- name: field
dtype: text
doc: The field of the object. This can be an empty string if the object is a dataset and the field is the
dataset values.
dims:
- num_rows
shape:
- null

- data_type_inc: Data
name: object_keys
doc: A table for identifying which objects use which keys.
dtype:
- name: objects_idx
dtype: uint
doc: The index to the 'objects' table for the object that holds the key.
- name: keys_idx
dtype: uint
doc: The index to the 'keys' table for the key.
dims:
- num_rows
shape:
- null
35 changes: 35 additions & 0 deletions nwb-schema/2.6.0/hdmf-common-schema/common/sparse.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# hdmf-schema-language=2.0.2
groups:
- data_type_def: CSRMatrix
data_type_inc: Container
doc: 'A compressed sparse row matrix. Data are stored in the standard CSR format, where column indices for row i are
stored in indices[indptr[i]:indptr[i+1]] and their corresponding values are stored in data[indptr[i]:indptr[i+1]].'
attributes:
- name: shape
dtype: uint
dims:
- number of rows, number of columns
shape:
- 2
doc: The shape (number of rows, number of columns) of this sparse matrix.
datasets:
- name: indices
dtype: uint
dims:
- number of non-zero values
shape:
- null
doc: The column indices.
- name: indptr
dtype: uint
dims:
- number of rows in the matrix + 1
shape:
- null
doc: The row index pointer.
- name: data
dims:
- number of non-zero values
shape:
- null
doc: The non-zero values in the matrix.
168 changes: 168 additions & 0 deletions nwb-schema/2.6.0/hdmf-common-schema/common/table.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,168 @@
# hdmf-schema-language=2.0.2
datasets:

- data_type_def: VectorData
data_type_inc: Data
doc: An n-dimensional dataset representing a column of a DynamicTable.
If used without an accompanying VectorIndex, first dimension is
along the rows of the DynamicTable and each step along the first
dimension is a cell of the larger table. VectorData can also be
used to represent a ragged array if paired with a VectorIndex.
This allows for storing arrays of varying length in a single cell
of the DynamicTable by indexing into this VectorData. The first
vector is at VectorData[0:VectorIndex[0]]. The second vector is at
VectorData[VectorIndex[0]:VectorIndex[1]], and so on.
dims:
- - dim0
- - dim0
- dim1
- - dim0
- dim1
- dim2
- - dim0
- dim1
- dim2
- dim3
shape:
- - null
- - null
- null
- - null
- null
- null
- - null
- null
- null
- null
attributes:
- name: description
dtype: text
doc: Description of what these vectors represent.

- data_type_def: VectorIndex
data_type_inc: VectorData
dtype: uint8
doc: Used with VectorData to encode a ragged array. An array of indices
into the first dimension of the target VectorData, and forming a map
between the rows of a DynamicTable and the indices of the VectorData.
The name of the VectorIndex is expected to be the name of the target
VectorData object followed by "_index".
dims:
- num_rows
shape:
- null
attributes:
- name: target
dtype:
target_type: VectorData
reftype: object
doc: Reference to the target dataset that this index applies to.

- data_type_def: ElementIdentifiers
data_type_inc: Data
default_name: element_id
dtype: int
dims:
- num_elements
shape:
- null
doc: A list of unique identifiers for values within a dataset, e.g. rows of a DynamicTable.

- data_type_def: DynamicTableRegion
data_type_inc: VectorData
dtype: int
doc: DynamicTableRegion provides a link from one table to an index or region of another. The `table` attribute is a
link to another `DynamicTable`, indicating which table is referenced, and the data is int(s) indicating the row(s)
(0-indexed) of the target array. `DynamicTableRegion`s can be used to associate rows with repeated meta-data without
data duplication. They can also be used to create hierarchical relationships between multiple `DynamicTable`s.
`DynamicTableRegion` objects may be paired with a `VectorIndex` object to create ragged references, so a single cell
of a `DynamicTable` can reference many rows of another `DynamicTable`.
dims:
- num_rows
shape:
- null
attributes:
- name: table
dtype:
target_type: DynamicTable
reftype: object
doc: Reference to the DynamicTable object that this region applies to.
- name: description
dtype: text
doc: Description of what this table region points to.

groups:

- data_type_def: DynamicTable
data_type_inc: Container
doc: A group containing multiple datasets that are aligned on the first dimension
(Currently, this requirement if left up to APIs to check and enforce). These datasets
represent different columns in the table. Apart from a column that contains unique
identifiers for each row, there are no other required datasets. Users are free to add
any number of custom VectorData objects (columns) here. DynamicTable also supports
ragged array columns, where each element can be of a different size. To add a ragged
array column, use a VectorIndex type to index the corresponding VectorData type.
See documentation for VectorData and VectorIndex for more details.
Unlike a compound data type, which is analogous to storing an
array-of-structs, a DynamicTable can be thought of as a struct-of-arrays. This provides
an alternative structure to choose from when optimizing storage for anticipated access
patterns. Additionally, this type provides a way of creating a table without having to
define a compound type up front. Although this convenience may be attractive, users
should think carefully about how data will be accessed. DynamicTable is more appropriate
for column-centric access, whereas a dataset with a compound type would be more
appropriate for row-centric access. Finally, data size should also be taken into account.
For small tables, performance loss may be an acceptable trade-off for the flexibility of
a DynamicTable.
attributes:
- name: colnames
dtype: text
dims:
- num_columns
shape:
- null
doc: The names of the columns in this table. This should be used to specify
an order to the columns.
- name: description
dtype: text
doc: Description of what is in this dynamic table.
datasets:
- name: id
data_type_inc: ElementIdentifiers
dtype: int
dims:
- num_rows
shape:
- null
doc: Array of unique identifiers for the rows of this dynamic table.
- data_type_inc: VectorData
doc: Vector columns, including index columns, of this dynamic table.
quantity: '*'

- data_type_def: AlignedDynamicTable
data_type_inc: DynamicTable
doc: DynamicTable container that supports storing a collection of sub-tables. Each
sub-table is a DynamicTable itself that is aligned with the main table by row
index. I.e., all DynamicTables stored in this group MUST have the same number
of rows. This type effectively defines a 2-level table in which the main data
is stored in the main table implemented by this type and additional columns of
the table are grouped into categories, with each category being represented by
a separate DynamicTable stored within the group.
attributes:
- name: categories
dtype: text
dims:
- num_categories
shape:
- null
doc: The names of the categories in this AlignedDynamicTable. Each category is
represented by one DynamicTable stored in the parent group. This attribute should
be used to specify an order of categories and the category names must match
the names of the corresponding DynamicTable in the group.
groups:
- data_type_inc: DynamicTable
doc: A DynamicTable representing a particular category for columns in the AlignedDynamicTable
parent container. The table MUST be aligned with (i.e., have the same number
of rows) as all other DynamicTables stored in the AlignedDynamicTable parent
container. The name of the category is given by the name of the DynamicTable
and its description by the description attribute of the DynamicTable.
quantity: '*'

0 comments on commit 65f9cc1

Please sign in to comment.