Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpticalChannel for TwoPhotonSeries #338

Open
luiztauffer opened this issue Dec 8, 2019 · 2 comments
Open

OpticalChannel for TwoPhotonSeries #338

luiztauffer opened this issue Dec 8, 2019 · 2 comments
Labels
category: proposal proposed enhancements or new features priority: medium non-critical problem and/or affecting only a small set of NWB users

Comments

@luiztauffer
Copy link

For an Ophys dataset, I have:
2 OpticalChannels (Yellow and Red wavelenghts)
2 TwoPhotonSeries to be stored in acquisitions (Yellow and Red wavelenghts)
1 DfOverF signal to be stored in processing, that’s composed out of a ratio between the two channels raw signals

How many ImagingPlane objects should I have?

As I understand it, only one ImagingPlane would be necessary, since it accepts a list of OpticalChannels. Also, that would be the ImagingPlane associated with the ROIs in the processing modules.
TwoPhotonSeries, however, do not specify which OpticalChannel was used to record the data, so if the 2 TwoPhotonSeries above would have the same ImagingPlane, it would not be possible to tell which comes from Red and which comes from Yellow.

Should TwoPhotonSeries have a field linking it to a specific OpticalChannel?

@ageorgou
Copy link

I have a similar question.

Using pynwb, it is possible to create an ImagingPlane with multiple OpticalChannels (this is also explicitly mentioned in the documentation and type checks). However, reading this with matnwb fails -- as far as I could tell from debugging it, this is because it does not expect the extra OpticalChannel. Looking at the schema, it also seems to me that an ImagingPlane should have exactly one associated OpticalChannel, as there is no quantity specified.

It seems that there is a discrepancy between the schema and what the two APIs allow.

If only one channel is allowed, then the TwoPhotonSeries also doesn't need a direct link to the OpticalChannel.

@bendichter
Copy link
Contributor

@ageorgou and @luiztauffer are right. The API documentation allows you to enter a list of OpticalChannel objects:

https://pynwb.readthedocs.io/en/stable/pynwb.ophys.html#pynwb.ophys.ImagingPlane

but the nwb-schema only allows one:

groups:
- 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.

We should allow more than one. That would be a non-breaking schema change.

@stephprince stephprince added category: proposal proposed enhancements or new features priority: medium non-critical problem and/or affecting only a small set of NWB users labels May 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: proposal proposed enhancements or new features priority: medium non-critical problem and/or affecting only a small set of NWB users
Projects
None yet
Development

No branches or pull requests

4 participants