Converting a Single Session#

Let’s imagine you’ve just completed an experimental session and you’d like to convert your data to NWB right away.

Upon launching the GUIDE, you’ll begin on the Convert page. If you’re opening the application for the first time, there should be no pipelines listed on this page.

Home page

Press the Create a new conversion pipeline button to start the conversion process.

Project Structure#

Project Setup#

The Project Setup page will have you define two pieces of information about your pipeline: the name and, optionally, the output location for your NWB files.

You’ll notice that the name property has a red asterisk next to it, which identifies it as a required property.

Project Setup page with no name (invalid)

After specifying a unique project name, the colored background and error message will disappear, allowing you to advance to the next page.

Project Setup page with valid name

Workflow Configuration#

On this page, you’ll specify the type of workflow you’d like to follow for this conversion pipeline.

Since this is a single-session workflow, you’ll need to specify a Subject ID and Session ID to identify the data you’ll be converting.

Workflow page

Additionally, we’ll turn off the option to upload to the DANDI Archive and approach this in a later tutorial.

Data Formats#

Next, you’ll specify the data formats you’re working with on the Data Formats page. The GUIDE supports 40+ total neurophysiology formats. A full registry of available formats is available here.

Date Formats page

The tutorial we’re working with uses the SpikeGLX and Phy formats, a common output for Neuropixels recordings and subsequent spike sorting. To specify that your pipeline will handle these files, you’ll press the “Add Format” button.

Format pop-up on the Data Formats page

Then, select the relevant formats—in this case, SpikeGLX Recording and Phy Sorting—from the pop-up list. Use the search bar to filter for the format you need.

Searching for SpikeGLX in the format pop-up

The selected formats will then display above the button.

Data Formats page with SpikeGLX Recording added to the list

Advance to the next page when you have SpikeGLX Recording and Phy Sorting selected.

Data Formats page with both SpikeGLX Recording and Phy Sorting added to the list

Data Entry#

Source Data Information#

On this page, specify the .ap.bin (SpikeGLX) file and phy folder so that the GUIDE can find this source data to complete the conversion.

As discussed in the Dataset Generation tutorial, these can be found in the ~/NWB_GUIDE/test-data/data directory, where ~ is the home directory of your system.

You can either click the file selector to navigate to the file or drag-and-drop into the GUIDE from your file navigator.

Source Data page with source locations specified

Advance to the next page to extract metadata from the source data.

Session Metadata#

The file metadata page is a great opportunity to add rich annotations to the file, which will be read by anyone reusing your data in the future!

The Session Start Time in the General Metadata section is already specified because this field was automatically extracted from the SpikeGLX source data.

Metadata page with invalid Subject information

While the General Metadata section is complete, take some time to fill out additional information such as the Institutional Info box and the Experimenter field.

We also need to add the Subject information—as noted by the red accents around that item. Let’s say that our subject is a male mouse with an age of P25W, which represents 25 weeks old.

Metadata page with valid **Subject** information

The status of the Subject information will update in real-time as you fill out the form.#

This dataset will also have Ecephys metadata extracted from the SpikeGLX source data, though we aren’t interested in modifying this information at the moment.

Ecephys metadata extracted from the SpikeGLX source data

Let’s leave this as-is and advance to the next page. This will trigger the conversion of your source data into a preview NWB file.

File Conversion#

Inspector Report#

The Inspector Report page allows you to validate the preview file against the latest Best Practices and make suggestions to improve the content or representations.

NWB Inspector report

Advance to the next page when you are satisfied with the Inspector Report.

Conversion Preview#

On the Conversion Preview, Neurosift allows you to explore the structure of the NWB file and ensure the packaged data matches your expectations.

In particular, take a look at the lefthand metadata table and check that the information provided on the previous pages is present in the NWB file.

Neurosift preview visualization

Neurosift can be useful for many other exploration tasks—but this will not be covered in this tutorial.

Advancing from this page will trigger the full conversion of your data to the NWB format, a process that may take some time depending on the dataset size.

Conversion Review#

Congratulations on finishing your first conversion of neurophysiology files using the NWB GUIDE!

Conversion results page with a list of converted files

This was a straightforward workflow with only a single session… But what if you have multiple sessions to convert?