DataExport
From SpinozaWiki
Exporting data as PAR/REC files
The standard Philips format for exporting MRI images is the PAR/REC file pair. The pair consists of a PAR file (a plain text file that contains the parameters/metadata of the scan), and the REC file (a binary file that contains the raw image data). This format is different from the DICOM file format in several ways;
- It is a single file pair even for fMRI acquisitions, not many separate files as in DICOM files,
- It contains slightly less meta-data than dicom files, and importantly for Spinoza,
- Its export is implemented much more robustly on Philips, and important for this wiki page:
- It is not exported (reaped) automatically like DICOM files, meaning that this has to be done manually.
This page shows you how to perform this manual export of your data.
Where to store your data
First, you export your files to a local drive, and then copy the exported files to the server. On both these drives you will have access to a project folder, and this folder is named according to the project under which you are scanning at Spinoza. The workflow is as follows:
Export to local drive project folder -> Copy to server project folder

Inside these projects folder, we propose you follow the following structure to ensure easy conversion and archiving of your data. In the example below the project is called knapen_FAM, and this folder would exist both on W:\ (local export drive), and Z:\projects (spinoza server drive)
The folder structure you would follow inside your project folder would look like so:
The sub-folders for bids and mriqc are there for the data after it's converted to BIDS format (see below), and for the standard quality-control we'll be running on all of your data automatically.
Exporting your data
In the scanner software interface, select ‘Administration’ from the File menu up top. This will pop up the interface window in the figure. It contains a list of folders, one for each session. You can click the sessions to expand the view, and have it show the different acquisitions, as shown in the example screenshot. In this interface, you select the acquisitions you want to export – in the example, acquisitions 4 to 8 are selected for subsequent export. Now, click the ‘Disk Files’ button at the bottom, in the middle, here outlined with a green rectangle.

This will pop up an interface from which you can export data to disk, shown here in 3 iterations from left to right. This window will open to a “Dicom Export” tab (left), but we want “Non Dicom Export”. Click that tab.

First, select where you want to save your data. Click “Browse”. If the required folder (according to the folder structure outlined above) doesn’t exist yet, create it in the right place. Select the folder in which your PAR/REC data should be put. Then, select how and which data format to export. Select the “Use Scan Name” and the “Sort” tick options. Deselect the “XML-REC” and “Nifti” options, and select the “PAR-REC” option. Click Proceed to export the data to the selected folder. You can follow the progress of your export by clicking the “Manage Job Queue” button, outlined in red above.
Copying your data to the projects folder on the server
After the PAR/REC export has finished (and it will finish much, much faster than equivalent DICOM exports!), you’ll need to copy the new folder/files to your project folder on the server. The easiest way to do this is to use the Windows file explorer, to copy-paste the new folder from the W:\ drive to the Z:\projects folder. Make sure to maintain the same folder structure in the projects folder on the server as exists on the local export drive W:\.
Remote access
At this point, you will have access to the PAR-REC files over sFTP (log in to sftp://minerva.spinozacentre.nl with your Spinoza credentials), and can download them to your own computer for further processing. But we also provide an automatic data conversion and quality control service. For that, see below.
Automatic BIDS conversion at Spinoza
We are implementing a system that automatically converts Spinoza-acquired data to BIDS format. This format allows easy archiving and preprocessing of your Spinoza data. To learn more about the BIDS format, see the BIDS website.
During the night after your scans, our server will go through your project folder and identify newly acquired data. It will then attempt to automatically convert your data to BIDS format. The goal is to also automatically run quality control analyses on all acquired data in the near future.
The automatic conversion tool bidsify is based on earlier efforts by Lukas Snoek at Spinoza REC. Its successful use depends on your using specific names for your runs in the scanner console, and on using the standard (f)MRI sequences we provide at Spinoza. The conversion is flexible, so when you start a project you should get in touch with Tomas to set up the conversion for your specific project. In short, the conversion is specified by a .yml file, a plain text file that contains the text bidsify should search for to identify certain types of scans, and the rules bidsify should use to convert those scans to valid BIDS data.
This .yml file will be stored in the root of your project folder on the server.