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

Add description and manufacturer to Device, extract to new file #326

Merged
merged 1 commit into from
Nov 13, 2019

Conversation

rly
Copy link
Contributor

@rly rly commented Nov 13, 2019

Partially handles #258 but we should consider eventually add more structured fields to Device aside from just manufacturer.

quantity: '+'
- neurodata_type_inc: Device
doc: Data acquisition devices.
quantity: '*'
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was there a reason why Device had quantity '+' (one or more)? I guess it makes sense that an NWB file should have some data and that data should have some device information attached to it. But then it means our barebones examples of making an NWBFile results in an invalid file (in practice, the validator says such a file is valid).

I lean toward saying that an NWB file can be valid without any data and without any device.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree

@rly rly merged commit ff42013 into dev Nov 13, 2019
@rly rly deleted the enh/device_desc branch November 13, 2019 22:33
@bendichter
Copy link
Contributor

@rly there's a problem here that I did not catch at first. Attributes cannot have the property "quantity". These two properties should instead say required: False. This is causing a problem when matnwb tried to auto-generate these classes because it does not read the quantity attribute and instead makes these attributes required, which is the default behavior.

@rly
Copy link
Contributor Author

rly commented Jan 2, 2020

@bendichter Good catch. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants