Skip to content

Commit 88829e5

Browse files
committed
Merge branch 'dev' into enh/append2
2 parents 7528b07 + a999785 commit 88829e5

File tree

3 files changed

+51
-2
lines changed

3 files changed

+51
-2
lines changed

.circleci/config.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,10 @@ conda-steps: &conda-steps
7070
conda config --add channels conda-forge
7171
conda install virtualenv
7272
pip install tox
73+
- run:
74+
name: Run the tests
75+
command: |
76+
tox -e $TEST_TOX_ENV
7377
- run:
7478
name: Build wheel and source distribution
7579
command: |

src/pynwb/file.py

Lines changed: 39 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,14 @@ class NWBFile(MultiContainerInterface):
143143
'session_id',
144144
'lab',
145145
'institution',
146+
'notes',
147+
'pharmacology',
148+
'protocol',
149+
'related_publications',
150+
'slices',
151+
'source_script',
152+
'surgery',
153+
'virus',
146154
{'name': 'ec_electrodes', 'child': True},
147155
{'name': 'epochs', 'child': True},
148156
{'name': 'subject', 'child': True},
@@ -161,6 +169,28 @@ class NWBFile(MultiContainerInterface):
161169
{'name': 'session_id', 'type': str, 'doc': 'lab-specific ID for the session', 'default': None},
162170
{'name': 'institution', 'type': str,
163171
'doc': 'institution(s) where experiment is performed', 'default': None},
172+
{'name': 'notes', 'type': str,
173+
'doc': 'Notes about the experiment.', 'default': None},
174+
{'name': 'pharmacology', 'type': str,
175+
'doc': 'Description of drugs used, including how and when they were administered. '
176+
'Anesthesia(s), painkiller(s), etc., plus dosage, concentration, etc.', 'default': None},
177+
{'name': 'protocol', 'type': str,
178+
'doc': 'Experimental protocol, if applicable. E.g., include IACUC protocol', 'default': None},
179+
{'name': 'related_publications', 'type': str,
180+
'doc': 'Publication information.'
181+
'PMID, DOI, URL, etc. If multiple, concatenate together and describe which is which. '
182+
'such as PMID, DOI, URL, etc', 'default': None},
183+
{'name': 'slices', 'type': str,
184+
'doc': 'Description of slices, including information about preparation '
185+
'thickness, orientation, temperature and bath solution', 'default': None},
186+
{'name': 'source_script', 'type': str,
187+
'doc': 'Script file used to create this NWB file.', 'default': None},
188+
{'name': 'surgery', 'type': str,
189+
'doc': 'Narrative description about surgery/surgeries, including date(s) '
190+
'and who performed surgery.', 'default': None},
191+
{'name': 'virus', 'type': str,
192+
'doc': 'Information about virus(es) used in experiments, including virus ID, '
193+
'source, date made, injection location, volume, etc.', 'default': None},
164194
{'name': 'lab', 'type': str, 'doc': 'lab where experiment was performed', 'default': None},
165195
{'name': 'acquisition', 'type': (list, tuple),
166196
'doc': 'Raw TimeSeries objects belonging to this NWBFile', 'default': None},
@@ -231,7 +261,15 @@ def __init__(self, **kwargs):
231261
'experiment_description',
232262
'session_id',
233263
'lab',
234-
'institution'
264+
'institution',
265+
'notes',
266+
'pharmacology',
267+
'protocol',
268+
'related_publications',
269+
'slices',
270+
'source_script',
271+
'surgery',
272+
'virus',
235273
]
236274
for attr in recommended:
237275
setattr(self, attr, kwargs.get(attr, None))

tests/unit/pynwb_tests/test_file.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,14 @@ def setUp(self):
2121
lab='a test lab',
2222
institution='a test institution',
2323
experiment_description='a test experiment description',
24-
session_id='test1')
24+
session_id='test1',
25+
notes='my notes',
26+
pharmacology='drugs',
27+
protocol='protocol',
28+
related_publications='my pubs',
29+
slices='my slices',
30+
surgery='surgery',
31+
virus='a virus')
2532

2633
def test_constructor(self):
2734
self.assertEqual(self.nwbfile.session_description, 'a test session description for a test NWBFile')

0 commit comments

Comments
 (0)