Onboarding HCP formatted data#

Human Connectome Project (HCP) uses a specific and well defined hierarchy of data with detailed information about each scan available in the accompanying json files. To optimize and simplify the importing and processing of HCP data, QuNex provides an import_hcp command, which maps data to the QuNex folder structure and prepares the session_hcp.txt files with detailed information on each image.

The naming conventions used in this chapter are explained on page about preparation of QuNex study folder hierarchy.

The main command for importing of HCP formatted datasets is:

  • import_hcp

    This command inspects the HCP dataset, which can be provided as a .zip, .tar.gz compressed package or a folder with either expanded data or multiple compressed packages, and maps the data into the correct folders. Specifically, sessions are mapped to <sessions folder>/<subject>_<session>/hcpls folders. Once the data is mapped, map_hcpls2nii command performs the mapping of MR images from sessions' hcpls folder to nii folder, creates session_hcp.txt file and a hcpls2nii.log, which lists the exact mapping that was performed. The command is run automatically as part of the import_hcp command.

Importantly, the two commands generate the session_hcp.txt file, which already contains the correct tags and labels to map the data to the hcp folder for further processing. If available in the json file, it also adds the relevant sequence information, such as phase encoding direction (phenc), echo spacing ('EchoSpacing'), dwell time (DwellTime), and unwarp direction (UnwarpDir). It also notes—if available—, which Spin-Echo pair of images (se) is to be used for the distortion correction for that scan.

For more detailed description of the command, its parameters and examples, please consult the online import_hcp command reference or see inline help by running qunex ?import_hcp.