Poster No:
1906
Submission Type:
Abstract Submission
Authors:
Yasmin Mzayek1, Pierre Bellec2, Ahmad Chamma1, Alexandre Cionca3, Jelle Dalenberg4, Jérôme Dockès1, Mathieu Dugré5, Elizabeth DuPre6, Rémi Gau7, Nicolas Gensollen8, Mathias Goncalves6, Anne-Sophie Kieslinger9, Alisha Kodibagkar10, Steven Meisler11, François Paugam12, Julio Peraza13, Jean-Baptiste Poline7, Patrick Sadil14, Taylor Salo15, Kevin Sitek16, Maximilian Sitter17, Alexis Thual1, Mohammad Torabi7, Konrad Wagstyl18, Hao-Ting Wang2, Michelle Wang7, Bertrand Thirion19
Institutions:
1Inria, Palaiseau, 2CRIUGM, Montreal, Quebec, 3Centre Hospitalier Universitaire Vaudoise, Lausanne, Vaud, 4University Medical Center Groningen, Groningen, 5Concordia University, Montreal, Quebec, 6Stanford University, Stanford, CA, 7McGill University, Montreal, Quebec, 8INRIA Paris center, Paris, 9Max Planck Institute for Human Cognitive and Brain Sciences, Leipzig, Other, 10University of Pennsylvania, Massachusetts Institute of Technology, Philadelphia, PA, 11Harvard / MIT, Cambridge, MA, 12University of Montreal, Montreal, Quebec, 13Florida International University, Miami, FL, 14Johns Hopkins Bloomberg School of Public Health, BALTIMORE, MD, 15University of Pennsylvania, Philadelphia, PA, 16Northwestern University, Evanston, IL, 17University Hospital Cologne, Cologne, 18UCL, London, London, 19inria, Palaiseau
First Author:
Co-Author(s):
Rémi Gau
McGill University
Montreal, Quebec
Alisha Kodibagkar
University of Pennsylvania, Massachusetts Institute of Technology
Philadelphia, PA
Taylor Salo
University of Pennsylvania
Philadelphia, PA
Introduction:
Nilearn is a widely recognized Python package in the neuroimaging community that offers a comprehensive set of statistical and machine learning tools for analysis of brain images. With over 10 years of ongoing development, it has reached 1000 stars, 576 forks, and over 200 contributors on GitHub, with clear impact as measured by its 163 citations in open access publications¹. Its continuous growth is backed by its encouraging community, user-friendly API, and comprehensive documentation, solidifying its role as a crucial part of the neuroimaging open-source software ecosystem. Also, Nilearn effectively makes use of powerful Python machine learning libraries, particularly scikit-learn², which are extensively utilized by scientific and industrial experts.
Recent work in Nilearn has centered on developing a new API to allow users to seamlessly work with surface data in a manner similar to volumetric data, enhancing support for the General Linear Model (GLM), enhancing the BIDS interface, and improving and updating the infrastructure and codebase.
Methods:
Nilearn is designed to be accessible for researchers and developers. The documentation (https://nilearn.github.io) comprises a comprehensive user guide and an illustrative example gallery, along with detailed contribution and maintenance guidelines. Moreover, we actively encourage community engagement by welcoming questions, bug reports, enhancement suggestions, and direct involvement in refining the source code. We use several channels of communication including Neurostars, GitHub, Discord, Twitter, and Mastodon for daily communication with both contributors and users.
Nilearn follows standard software development practices, including version control, unit testing, and rigorous reviews for contributions. Our automated continuous integration infrastructure ensures constant testing and updates for a streamlined development process. On this end, we have been further improving the code quality of and infrastructure around our codebase to meet best practices and ensure quality as the package grows.
Finally, Nilearn is actively showcased in various tutorials and workshops held annually, such as the OHBM Brainhack.
Results:
Nilearn supports brain image manipulation, GLM-based analysis, predictive modelling, classification, decoding, and connectivity analysis. It also has tooling for visualizing volumetric and surface brain imaging data. In the latest release (v0.10.2)³, an experimental surface API has been added to facilitate working with surface data in downstream surface-based analyses.
Key features from the release include the addition of LogisitcRegressionCV and LassoCV estimators to the Decoder module, the ability to compute fixed effects on F contrasts in the GLM module, and the option to enable radiological view for volumetric plotting functions (Fig1). A new surface API has also been released under an experimental module for rapid community feedback. It provides access to a SurfaceImage class that can store mesh and surface data for both hemispheres. This surface object can then be easily passed to other functions for further analysis or visualization (Fig2) mirroring Nilearn's interface for handling volumetric data.
Notable maintenance changes were implemented to improve codebase standardization and consistency, including the use of reformatting tools, such as Black and pre-commit for automatic linting and formatting. Ongoing efforts involve codebase restructuring based on new guidelines and writing reusable Pytest fixtures for efficient unit testing.


Conclusions:
The growing reliance on Nilearn underscores its accessibility and utility within the neuroimaging community. Developing the surface API will allow us to better support cortical surface analyses and meet user needs. Further, as the package grows, improved infrastructure and keeping up with new standards will ensure the robustness of this tool.
Modeling and Analysis Methods:
Methods Development 1
Other Methods 2
Keywords:
Open-Source Code
Open-Source Software
Statistical Methods
1|2Indicates the priority used for review
Provide references using author date format
[1] NiLearn (RRID:SCR_001362)
[2] Pedregosa, F., Varoquaux, G., Gramfort, A., Michel, V., Thirion, B., Grisel, O., Blondel, M., Prettenhofer, P., Weiss, R., Dubourg, V., Vanderplas, J., Passos, A., Cournapeau, D., Brucher, M., Perrot, M., Duchesnay, E. (2011). Scikit-learn: Machine Learning in Python, Journal of Machine Learning Research, 12, 2825-2830.
[3] Nilearn contributors, Chamma, A., Frau-Pascual, A., Rothberg, A., Abadie, A., Abraham, A., Gramfort, A., Savio, A., Cionca, A., Thual, A., Kodibagkar, A., Kanaan, A., Pinho, A. L., Idrobo, A. H., Kieslinger, A.-S., Rokem, A., Mensch, A., Vijayan, A., Duran, A., … Nájera, Ó. (2023). nilearn (0.10.2). Zenodo. https://doi.org/10.5281/zenodo.8397157