hcp-utils


Namehcp-utils JSON
Version 0.1.0 PyPI version JSON
download
home_pagehttps://github.com/rmldj/hcp-utils
SummaryA set of utilities for working with HCP-style fMRI data with nilearn.
upload_time2020-01-14 09:12:47
maintainer
docs_urlNone
authorRomuald A. Janik
requires_python>=3.6
license
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # hcp-utils

This package contains utilities to use  [Human Connectome Project](https://www.humanconnectome.org/) (HCP) data and HCP-like data (e.g. obtained from legacy data using [ciftify](https://github.com/edickie/ciftify)) as well as corresponding parcellations with [nilearn](https://nilearn.github.io/) and other Python tools. 

The HCP data differs from conventional volumetric fMRI data which records the BOLD signal from each *voxel* in a 3D volume in that the signal from the cortical surface is treated as a folded two dimensional surface, and hence the data is associated with vertices of a predefined surface mesh, while the subcortical structures are described volumetrically using voxels. 

The CIFTI (more precisely CIFTI-2) file format encompasses both the cortical 2D surface data as well as the subcortical volume data. However, only the voxels associated with relevant subcortical structures are kept.
Thus these data are quite richly structured. Although the standard Python tools for dealing with fMRI data like [nibabel](https://nipy.org/nibabel/) can read both the CIFTI-2 files containing the fMRI signals and the GIFTI files containing the surface mesh definitions, there is not much that one could do further out-of-the-box, in particular visualization using [nilearn](https://nilearn.github.io/) or processing parcellated data using e.g. machine learning tools which work exclusively with `numpy` arrays. The goal of this package is to ease the interoperability of HCP data and these standard Python tools.


![brain image](images/image.png)


The utilities mainly deal with plotting surface data, accessing the predefined subcortical structures as well as using various parcellations and identifying connected components on the cortical surface. Various helper functions aid e.g. in mapping the HCP fMRI cortical data to surface vertices for visualization etc. The functions work directly with numpy arrays of shape `Tx91282` or `91282` for fMRI data, with `T` being the number of time frames, while `91282` is the standard HCP dimensionality for the 3T cortical surface and subcortical data.

## Documentation

Find the documentation at [rmldj.github.io/hcp-utils](https://rmldj.github.io/hcp-utils/)

## Installation

Make sure that you have the following packages installed (e.g. using [miniconda](https://docs.conda.io/en/latest/miniconda.html))
```
nibabel, nilearn, numpy, scikit-learn, matplotlib, pandas, scipy
```
Then install with 
```
pip install hcp_utils
```
upgrade with
```
pip install --upgrade hcp_utils
```


## External data

### Surface meshes

The default surface meshes for 3D visualization come from the group average of the Human Connectome Project (HCP) 1200 Subjects (S1200) data release (March 2017) processed using HCP pipelines. They can be obtained on BALSA: https://balsa.wustl.edu/reference/show/pkXDZ 


These group average files are redistributed under the HCP Open Access Data Use Terms https://www.humanconnectome.org/study/hcp-young-adult/document/wu-minn-hcp-consortium-open-access-data-use-terms with the acknowledgment: 

*"Data were provided [in part] by the Human Connectome Project, WU-Minn Consortium (Principal Investigators: David Van Essen and Kamil Ugurbil; 1U54MH091657) funded by the 16 NIH Institutes and Centers that support the NIH Blueprint for Neuroscience Research; and by the McDonnell Center for Systems Neuroscience at Washington University."*


### Parcellations

When using the included parcellations, please cite the relevant papers, which include full details.

**The Glasser MMP1.0 Parcellation:** Glasser, Matthew F., Timothy S. Coalson, Emma C. Robinson, Carl D. Hacker, John Harwell, Essa Yacoub, Kamil Ugurbil, et al. 2016. “A Multi-Modal Parcellation of Human Cerebral Cortex.” Nature 536 (7615): 171–78.  http://doi.org/10.1038/nature18933 (see in particular the details in *Supplementary	Neuroanatomical	Results*).

**Yeo 7 or (17) Network Parcellation:** Yeo, B. T. Thomas, Fenna M. Krienen, Jorge Sepulcre, Mert R. Sabuncu, Danial Lashkari, Marisa Hollinshead, Joshua L. Roffman, et al. 2011. “The Organization of the Human Cerebral Cortex Estimated by Intrinsic Functional Connectivity.” Journal of Neurophysiology 106 (3): 1125–65. https://doi.org/10.1152/jn.00338.2011.

**The Cole-Anticevic Brain-wide Network Partition:** Ji JL*, Spronk M*, Kulkarni K, Repovs G, Anticevic A**, Cole MW** (2019). "Mapping the human brain's cortical-subcortical functional network organization". NeuroImage. 185:35–57. doi:10.1016/j.neuroimage.2018.10.006 [* = equal contribution; ** = senior authors] https://doi.org/10.1016/j.neuroimage.2018.10.006 (also available as an open access bioRxiv preprint: http://doi.org/10.1101/206292) and https://github.com/ColeLab/ColeAnticevicNetPartition/


* * *

*This package was initiated as a tool within the project ["Bio-inspired artificial neural networks"](http://bionn.matinf.uj.edu.pl/) funded by the Foundation for Polish Science (FNP).* 





            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/rmldj/hcp-utils",
    "name": "hcp-utils",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.6",
    "maintainer_email": "",
    "keywords": "",
    "author": "Romuald A. Janik",
    "author_email": "romuald.janik@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/16/65/7f5aca198b104b4833fc4cc67080d709a6ef08305051cdc3ff3a425d7126/hcp_utils-0.1.0.tar.gz",
    "platform": "",
    "description": "# hcp-utils\n\nThis package contains utilities to use  [Human Connectome Project](https://www.humanconnectome.org/) (HCP) data and HCP-like data (e.g. obtained from legacy data using [ciftify](https://github.com/edickie/ciftify)) as well as corresponding parcellations with [nilearn](https://nilearn.github.io/) and other Python tools. \n\nThe HCP data differs from conventional volumetric fMRI data which records the BOLD signal from each *voxel* in a 3D volume in that the signal from the cortical surface is treated as a folded two dimensional surface, and hence the data is associated with vertices of a predefined surface mesh, while the subcortical structures are described volumetrically using voxels. \n\nThe CIFTI (more precisely CIFTI-2) file format encompasses both the cortical 2D surface data as well as the subcortical volume data. However, only the voxels associated with relevant subcortical structures are kept.\nThus these data are quite richly structured. Although the standard Python tools for dealing with fMRI data like [nibabel](https://nipy.org/nibabel/) can read both the CIFTI-2 files containing the fMRI signals and the GIFTI files containing the surface mesh definitions, there is not much that one could do further out-of-the-box, in particular visualization using [nilearn](https://nilearn.github.io/) or processing parcellated data using e.g. machine learning tools which work exclusively with `numpy` arrays. The goal of this package is to ease the interoperability of HCP data and these standard Python tools.\n\n\n![brain image](images/image.png)\n\n\nThe utilities mainly deal with plotting surface data, accessing the predefined subcortical structures as well as using various parcellations and identifying connected components on the cortical surface. Various helper functions aid e.g. in mapping the HCP fMRI cortical data to surface vertices for visualization etc. The functions work directly with numpy arrays of shape `Tx91282` or `91282` for fMRI data, with `T` being the number of time frames, while `91282` is the standard HCP dimensionality for the 3T cortical surface and subcortical data.\n\n## Documentation\n\nFind the documentation at [rmldj.github.io/hcp-utils](https://rmldj.github.io/hcp-utils/)\n\n## Installation\n\nMake sure that you have the following packages installed (e.g. using [miniconda](https://docs.conda.io/en/latest/miniconda.html))\n```\nnibabel, nilearn, numpy, scikit-learn, matplotlib, pandas, scipy\n```\nThen install with \n```\npip install hcp_utils\n```\nupgrade with\n```\npip install --upgrade hcp_utils\n```\n\n\n## External data\n\n### Surface meshes\n\nThe default surface meshes for 3D visualization come from the group average of the Human Connectome Project (HCP) 1200 Subjects (S1200) data release (March 2017) processed using HCP pipelines. They can be obtained on BALSA: https://balsa.wustl.edu/reference/show/pkXDZ \n\n\nThese group average files are redistributed under the HCP Open Access Data Use Terms https://www.humanconnectome.org/study/hcp-young-adult/document/wu-minn-hcp-consortium-open-access-data-use-terms with the acknowledgment: \n\n*\"Data were provided [in part] by the Human Connectome Project, WU-Minn Consortium (Principal Investigators: David Van Essen and Kamil Ugurbil; 1U54MH091657) funded by the 16 NIH Institutes and Centers that support the NIH Blueprint for Neuroscience Research; and by the McDonnell Center for Systems Neuroscience at Washington University.\"*\n\n\n### Parcellations\n\nWhen using the included parcellations, please cite the relevant papers, which include full details.\n\n**The Glasser MMP1.0 Parcellation:** Glasser, Matthew F., Timothy S. Coalson, Emma C. Robinson, Carl D. Hacker, John Harwell, Essa Yacoub, Kamil Ugurbil, et al. 2016. \u201cA Multi-Modal Parcellation of Human Cerebral Cortex.\u201d Nature 536 (7615): 171\u201378.  http://doi.org/10.1038/nature18933 (see in particular the details in *Supplementary\tNeuroanatomical\tResults*).\n\n**Yeo 7 or (17) Network Parcellation:** Yeo, B. T. Thomas, Fenna M. Krienen, Jorge Sepulcre, Mert R. Sabuncu, Danial Lashkari, Marisa Hollinshead, Joshua L. Roffman, et al. 2011. \u201cThe Organization of the Human Cerebral Cortex Estimated by Intrinsic Functional Connectivity.\u201d Journal of Neurophysiology 106 (3): 1125\u201365. https://doi.org/10.1152/jn.00338.2011.\n\n**The Cole-Anticevic Brain-wide Network Partition:** Ji JL*, Spronk M*, Kulkarni K, Repovs G, Anticevic A**, Cole MW** (2019). \"Mapping the human brain's cortical-subcortical functional network organization\". NeuroImage. 185:35\u201357. doi:10.1016/j.neuroimage.2018.10.006 [* = equal contribution; ** = senior authors] https://doi.org/10.1016/j.neuroimage.2018.10.006 (also available as an open access bioRxiv preprint: http://doi.org/10.1101/206292) and https://github.com/ColeLab/ColeAnticevicNetPartition/\n\n\n* * *\n\n*This package was initiated as a tool within the project [\"Bio-inspired artificial neural networks\"](http://bionn.matinf.uj.edu.pl/) funded by the Foundation for Polish Science (FNP).* \n\n\n\n\n",
    "bugtrack_url": null,
    "license": "",
    "summary": "A set of utilities for working with HCP-style fMRI data with nilearn.",
    "version": "0.1.0",
    "project_urls": {
        "Homepage": "https://github.com/rmldj/hcp-utils"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "9358e43cfa39c50e4c354e42c8ff6ebfe20fc5f6ab27d1c53adcd7d0c2ebe21d",
                "md5": "f17e06dca29b7bf5e28bac061d5f539c",
                "sha256": "6bd6595b646f463337f7dc8bcc6f241662c6d3aa4c5ef8fb9b9db85b76185664"
            },
            "downloads": -1,
            "filename": "hcp_utils-0.1.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "f17e06dca29b7bf5e28bac061d5f539c",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6",
            "size": 8040303,
            "upload_time": "2020-01-14T09:12:32",
            "upload_time_iso_8601": "2020-01-14T09:12:32.256788Z",
            "url": "https://files.pythonhosted.org/packages/93/58/e43cfa39c50e4c354e42c8ff6ebfe20fc5f6ab27d1c53adcd7d0c2ebe21d/hcp_utils-0.1.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "16657f5aca198b104b4833fc4cc67080d709a6ef08305051cdc3ff3a425d7126",
                "md5": "024ea1ded0c5ef8d3757373a6910efcb",
                "sha256": "3b68ed8841aefe9cb0901ca09641d4a1de1870e934c6401e779bf8a8c1408c76"
            },
            "downloads": -1,
            "filename": "hcp_utils-0.1.0.tar.gz",
            "has_sig": false,
            "md5_digest": "024ea1ded0c5ef8d3757373a6910efcb",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6",
            "size": 8035957,
            "upload_time": "2020-01-14T09:12:47",
            "upload_time_iso_8601": "2020-01-14T09:12:47.996404Z",
            "url": "https://files.pythonhosted.org/packages/16/65/7f5aca198b104b4833fc4cc67080d709a6ef08305051cdc3ff3a425d7126/hcp_utils-0.1.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2020-01-14 09:12:47",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "rmldj",
    "github_project": "hcp-utils",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "hcp-utils"
}
        
Elapsed time: 0.24434s