You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/tutorials/dataset.rst
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,8 +1,8 @@
1
1
Example Dataset Generation
2
2
==========================
3
3
4
-
Our tutorials focus on converting extracellular electrophysiology data in the SpikeGLX and Phy formats.
5
-
To get you started as quickly as possible, we’ve created a way to generate this Neuropixel-like dataset at the click of a button!
4
+
The NWB GUIDE tutorials focus on converting extracellular electrophysiology data in the SpikeGLX and Phy formats.
5
+
To get started as quickly as possible, you can use NWB GUIDE to generate a Neuropixels-like dataset at the click of a button!
6
6
7
7
.. note::
8
8
The **SpikeGLX** data format stores electrophysiology recordings.
@@ -17,7 +17,9 @@ Navigate to the **Settings** page using the button at the bottom of the main sid
17
17
18
18
Press the Generate button on the Settings page to create the dataset.
19
19
20
-
The generated data will populate in the ``~/NWB_GUIDE/test_data`` directory, where ``~`` is the home directory of your system. This includes both a ``single_session_data`` and ``multi_session_dataset`` folder to accompany the following tutorials.
20
+
The dataset will be generated in a new ``~/NWB_GUIDE/test_data`` directory, where ``~`` is the `home directory <https://en.wikipedia.org/wiki/Home_directory#Default_home_directory_per_operating_system>`_ of your system. This includes both a ``single_session_data`` and ``multi_session_dataset`` folder to use in the following tutorials.
21
+
22
+
The folder structure of the generated dataset is as follows:
21
23
22
24
.. code-block:: bash
23
25
@@ -52,6 +54,4 @@ The generated data will populate in the ``~/NWB_GUIDE/test_data`` directory, whe
52
54
│ │ └── mouse2_Session2/
53
55
│ │ ...
54
56
55
-
56
-
57
-
Now you’re ready to start your first conversion using the NWB GUIDE!
57
+
Now you're ready to start your first conversion using the NWB GUIDE!
Copy file name to clipboardExpand all lines: docs/tutorials/multiple_sessions.rst
+22-15Lines changed: 22 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
Managing Multiple Sessions
2
2
==========================
3
3
4
-
Now, let’s say that you’ve already run some of your experiments and now you want to convert them all at the same time. This is where a multi-session workflow will come in handy.
4
+
Now, let's imagine that you've already run multiple sessions of an experiment and now you want to convert them all to NWB at the same time. This is where a multi-session workflow will be useful.
5
5
6
6
Begin a new conversion on the **Convert** page and provide a name for your pipeline.
7
7
@@ -12,19 +12,23 @@ Update the Workflow page to indicate that you'll:
12
12
13
13
#. Run on multiple sessions
14
14
#. Locate the source data programmatically
15
-
#. Specify your dataset location ``~/NWB_GUIDE/test-data/multi_session_dataset``, where **~** is the home directory of your system.
15
+
#. Specify your dataset location ``~/NWB_GUIDE/test-data/multi_session_dataset``, where ``~`` is the home directory of your system.
@@ -34,33 +38,33 @@ This page helps you automatically identify source data for multiple subjects / s
34
38
File locations are specified as **format strings** that define source data paths of each selected data format.
35
39
36
40
.. note::
37
-
Format strings are one component of NeuroConv's **path expansion language**, which has some nifty features for manually specifying complex paths. Complete documentation of the path expansion feature of NeuroConv can be found :path-expansion-guide:`here <>`.
41
+
Format strings are one component of NeuroConv's **path expansion language**, which has nifty features for manually specifying complex paths. Complete documentation of the path expansion feature can be found :path-expansion-guide:`here <>`.
38
42
39
-
While you don’t have to specify format strings for all of the pipeline’s data formats, we’re going to find all of our data here for this tutorial. You'll always be able to confirm or manually select the final paths on the Source Data page later in the workflow.
43
+
While you don't have to specify format strings for all of the pipeline's data formats, we're going to find all of our data here for this tutorial. You'll always be able to confirm or manually select the final paths on the Source Data page later in the workflow.
40
44
41
45
Format strings are specified using two components: the **base directory**, which is the directory to search in, and the **format string path**, where the source data is within that directory.
42
46
43
47
The base directory has been pre-populated based on your selection on the Workflow page.
44
48
45
-
To avoid specifying the format string path by hand, we can take advantage of **Autocomplete**. Click the **Autocomplete** button to open a pop-up form that will derive the format string from a single example path.
49
+
To avoid specifying the format string path by hand, click the **Autocomplete** button to open a pop-up form that will derive the format string from a single example path.
Provide an example source data path (for example, the ``multi_session_dataset/mouse1/mouse1_Session2/mouse1_Session2_phy`` file for Phy), followed by the Subject (``mouse1``) and Session ID (``Session1``) for this particular path.
55
+
Provide a source data path for Phy by either dragging and dropping the folder ``multi_session_dataset/mouse1/mouse1_Session2/mouse1_Session2_phy`` into the **Example Folder** box or clicking the box and selecting a folder. Then enter the Subject ID (``mouse1``) and Session ID (``Session1``) for this particular path.
When you submit this form, you’ll notice that the Format String Path input has been auto-filled with a pattern for all the sessions.
61
+
When you submit this form, you'll notice that the Format String Path input has been auto-filled with a pattern for all of the sessions, and a list of all of the source data found is shown in the gray box. Confirm that this list contains all four Phy folders.
:alt:Path expansion page with autocompleted format string
62
66
63
-
Repeat this process for SpikeGLX, where ``multi_session_dataset/mouse1/mouse1_Session2/mouse1_Session2_g0/mouse1_Session2_g0_imec0/mouse1_Session1_g0_t0.imec0.lf.bin`` will be the example source data path.
67
+
Repeat this process for SpikeGLX, where ``multi_session_dataset/mouse1/mouse1_Session2/mouse1_Session2_g0/mouse1_Session2_g0_imec0/mouse1_Session1_g0_t0.imec0.ap.bin`` will be the example source data path.
In this case, we have two subjects with two sessions each. Let’s say that each of their sessions happened close enough in time that they can be identified using the same **age** entry: ``P29W`` for ``mouse1`` and ``P30W`` for ``mouse2``.
86
+
In this case, we have two subjects with two sessions each. Let's say that each of their sessions happened close enough in time that they can be identified using the same **age** entry: ``P29W`` for ``mouse1`` and ``P30W`` for ``mouse2``.
82
87
83
88
We should also indicate the ``sex`` of each subject since this is a requirement for `uploading to the DANDI Archive <https://www.dandiarchive.org/handbook/135_validation/#missing-dandi-metadata>`_.
84
89
@@ -90,16 +95,18 @@ Advance to the next page when you have entered subject metadata for all subjects
90
95
91
96
Source Data Information
92
97
-----------------------
93
-
Because we used the Locate Data page to programmatically identify our source data, this page should mostly be complete. You can use this opportunity to verify that the identified paths appear as expected for each session.
98
+
99
+
Because we used the Locate Data page to programmatically identify our source data, this page should mostly be complete. Verify that the identified paths appear as expected for each session by clicking the "Phy Sorting" header to expand the section for Phy data and examining the "Folder Path" value. Do the same for the SpikeGLX data.
One notable difference between this and the single-session workflow, however, is that the next few pages will allow you to toggle between sessions using the **session manager** sidebar on the left.
105
+
One notable difference between this and the single-session workflowis that the next few pages will allow you to toggle between sessions using the **session manager** sidebar on the left. Try this out. Under "Sessions", click "sub-mouse2" and "ses-Session1" to locate the source data for a different session from this subject.
100
106
101
107
Session Metadata
102
108
----------------
109
+
103
110
Aside from the session manager, the file metadata page in the multi-session workflow is nearly identical to the single-session version.
You'll notice that there's an **Edit Default Metadata** button at the top of the page. This feature allows you to specify a single default value for each property that is expected to be the same across all sessions. **Use this button to fill in general metadata for your sessions**, which will save you time and effort while ensuring your files still follow Best Practices.
126
+
You'll notice that there's an **Edit Default Metadata** button at the top of the page. This feature allows you to specify a single default value for each property that is expected to be the same across all sessions. **Use this button to fill in general metadata for your sessions**, such as the Institution, which will save you time and effort while ensuring your files still follow Best Practices.
120
127
121
128
Finish the rest of the workflow as you would for a single session by completing a full conversion after you review the preview files with the NWB Inspector and Neurosift.
0 commit comments