arXiv:2608.12185cs.CVAug 2026

Manuscript Offprint

arXiv:2608.12185

GenFAR: A generalized representation of brain structure, derived from 49,246 multi-cohort MRIs via deep learning

Vishnu M. Bashyam, Guray Erus, Junhao Wen, Pratik Chaudhari, Randa Melhem, Sindhuja Govindarajan Tirumalai, Gareth Harman, Yong Fan, Colin L. Masters, Paul Maruff, Sterling C. Johnson, Jurgen Fripp, Duygu Tosun, John C. Morris, Daniel S. Marcus, Pamela LaMontagne, Tammie Benzinger, Susan R. Heckbert, Mark Espeland, Marilyn S. Albert, Andrew J. Saykin, Paul M. Thompson, Timothy J. Hohman, Susan M. Resnick, R. Nick Bryan, Murat Bilgel, Yang An, David A. Wolk, Li Shen, Haochang Shou, Ilya M. Nasrallah, Christos Davatzikos

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

Deep learning models for neuroimaging have largely been developed for individual tasks, limiting knowledge transfer across applications. Here we introduce GenFAR, a modular deep learning framework that learns general, clinically informed features from brain MRIs. We trained this modular architecture on 49,246 individuals across 11 cohorts, using 17 diverse classification and regression tasks spanning cognition, clinical, diagnosis, demographics, and biomarkers. This yields aggregated, focused feature sets that capture rich, clinically- and biologically-relevant brain representations. We developed a sequential learning approach where tasks progressively build on previously learned representations. Through an analysis of 5,000 task sequences, we identified an optimal sequence length of six tasks and introduced a Donor Score metric to quantify each task’s contribution to downstream performance. This analysis revealed five consistently strong donor tasks (Age, AD/MCI, MMSE, Hypertension, Hyperlipidemia) that formed the base of our sequential model. We demonstrated the utility of our learned representation, in various tasks beyond those included in the training set, to serve as the foundation for specialized secondary predictors. We further showed that using the learned feature representation can substantially increase the sample efficiency of secondary deep learning training tasks and models, as well as improve their accuracy.

Introduction

Over the past decade, deep learning has transformed medical imaging research, leading to significant advancements across various applications, including segmentation, registration, classification, regression, clustering, synthesis, and more [avbersek2022; yao2020]. With the aid of large datasets and methodological innovations, deep learning has emerged as a critical tool for enabling the clinical translation of computational applications in medical imaging. However, the current landscape of deep learning models in medical imaging is marked by specialization, with most models tailored for individual use cases and tasks [avbersek2022]. This specialization, while yielding impressive single-task performance, limits cross-task knowledge transfer, requires substantial engineering effort for each new endpoint, and constrains generalization to diverse clinical populations and acquisition settings.

In recent years, the deep learning community, particularly in the fields of natural language processing and computer vision, has shifted towards larger, more general, foundational models [bommasani2021; ramesh2021; brown2020; openai2023; rombach2022; scao2022]. These models have demonstrated unprecedented performance and adaptability by leveraging massive datasets, substantial model capacity, and extensive optimization budgets, surpassing the typical diminishing returns associated with increasing scale [bommasani2021]. This shift has given rise to a new paradigm in deep learning, where novel and specialized tasks are built upon the general feature representations learned by foundational models.

Medical imaging stands to benefit substantially from this paradigm [moor2023]. Relative to natural images, factors such as small sample sizes, high dimensionality, data homogeneity, and shared imaging features among different pathologies make cross-task and cross-dataset knowledge transfer particularly impactful. The transition towards foundational models with highly general feature representations directly addresses the current fragmentation of deep learning model development in medical imaging. Specialized secondary models can benefit from indirect access to larger, diverse datasets and cross-task knowledge transfer, via the sample efficiency provided by learned feature representations [bengio2013]. These rich image representations, which stem from sizeable and diverse data sources, are expected to improve the performance and generalizability of the models, ultimately benefiting a wide range of medical imaging applications.

Prior work leveraging cross-task knowledge transfer in medical imaging has often focused on the benefits of integrating object detection and segmentation tasks to improve a single classification task. Multiple publications have demonstrated the benefits of this approach across a variety of imaging modalities and anatomical regions [cao2018; cheng2022; chowdary2022; gao2020; kuang2021; chelaramani2021]. Other works have investigated the complementary benefits of jointly learning multiple closely related tasks, to improve performance on a target task [li2019; tang2020; zhang2022; he2022]. While these works offer a promising view into what is possible with cross-task knowledge transfer, they are limited to a small number of closely related tasks and, critically, do not evaluate the performance of new, unseen tasks based on prior learning.

More recently, foundational-model directions have begun to emerge within neuroimaging, with several recent efforts being highly relevant to our work. Tak et al. introduced a generalized brain MRI foundation model, called BrainIAC, using contrastive self-supervision across 48,519 scans from diverse datasets, reporting strong performance, particularly in low-data regimes, on downstream targets such as age prediction, glioma IDH mutation status, and survival [tak2024brainiac]. Similarly, Kaczmarek et al. developed a SimCLR-based contrastive learning foundation model for 3D brain structural MRI, pre-trained on 18,759 patients (44,958 scans) from 11 publicly available datasets spanning diverse neurological diseases including Alzheimer’s Disease, Parkinson’s Disease, and stroke [kaczmarek2025simclr]. Their model demonstrated superior performance compared to Masked Autoencoders and supervised baselines across multiple downstream tasks, achieving comparable performance to supervised methods when fine-tuning on only 20% of the data. Wood et al. (BrainAge) trained modality-specific age predictors on up to 18,890 clinically acquired MR examinations and showed that these models can serve as foundation models whose features transfer effectively (with fine-tuning) to new sequences, orientations, and even modest sample sizes [wood2024brainage]. Beyond brain-specific models, Wang et al. (Triad) trained a single 3D encoder over 131,170 MRIs spanning multiple organs and modalities and attached task-specific heads to address a broad battery of segmentation, classification, and registration tasks, demonstrating state-of-the-art results within-domain and non-trivial zero-shot transfer [wang2025triad]. Complementing these, Deng et al. (SAM-Brain3D) presented a brain-focused foundation model based on a 3D SAM architecture with an adapter for downstream brain disease analysis, emphasizing segmentation at scale and extension to classification tasks via lightweight adapters [deng2025sambrain3d]. Related segmentation-focused models (BrainFounder [cox2024brainfounder], LaMiM [chen2024lamim]) and robust segmentation frameworks with strong cross-contrast generalization (SynthSeg [billot2023synthseg]) further attest to the feasibility of brain-imaging foundation models.

These developments reveal diverse approaches to learning generalizable neuroimaging representations, each capturing different types of priors. BrainIAC, Triad, and the SimCLR-based model by Kaczmarek et al. learn powerful priors using large-scale self-supervision and adapt with task-specific heads. Segmentation-centric foundation models (BrainFounder, LaMiM, SynthSeg and SAM-Brain3D) also learn priors but through supervised segmentation tasks that capture structural regularities of brain anatomy. These approaches have demonstrated impressive results, however, they are not designed to explicitly encode clinically informed, task-specific supervision from a wide spectrum of neuroimaging phenotypes nor to study how learning across such phenotypes can be structured to maximize transfer within the brain domain. BrainAge [wood2024brainage] provides an encouraging proof-of-concept, showing that a single clinically motivated endpoint (age prediction) can produce broadly useful features with strong transfer capabilities even in limited data settings. This raises the natural question of whether jointly learning from multiple clinical endpoints might capture richer, more generalizable representations than any single task alone. Lastly, the meta-matching framework by He et al. explores multi-phenotype learning from a different angle, training separate predictors and reusing their outputs as features for new targets, yielding notable sample-efficiency on external cohorts [he2022]. While impressive, it operates on final predictions rather than intermediate representations and does not support explicit knowledge sharing during the feature-learning stage.

In this work, we set out to learn clinically informed, general neuroimaging representations from 3D T1-weighted MRIs by supervising on a broad set of phenotypes and by structuring how tasks learn from one another. We refer to our approach as GenFAR (Generalized FeAture Representations). We explored two complementary frameworks for this approach. The first, an independent framework, employs a modular model comprised of multiple task-specific prediction channels trained in parallel without inter-task knowledge sharing. These channels learn focused features that, when aggregated, form a general representation of the brain (Figure 1B-C). These independently learned features can transfer well to new tasks and markedly increase sample-efficiency, often outperforming directly trained models in low-data regimes. However, this independent framework does not allow information to flow between tasks during representation learning, which means weaker tasks with limited data or tasks with inherently low separability on T1-MRI cannot benefit from the structure learned by stronger tasks.

To address this limitation, we also developed a sequential learning framework that enables tasks to learn incrementally from previously learned representations. In this framework, tasks are arranged in an ordered sequence, where each task receives both the 3D brain scan and the feature representations from all preceding tasks, allowing later tasks to bootstrap from stronger, upstream tasks rather than re-learning from scratch. This design preserves the modularity of task-specific channels while introducing a controlled mechanism for knowledge transfer across tasks during training. Our sequential learning approach draws heavily from the Model Zoo framework [ramesh2021model], which demonstrated the effectiveness of growing an ensemble of models trained on different task combinations to mitigate task competition in continual learning. The sequential learning framework requires careful consideration of sequence length to balance transfer against noise accumulation and overfitting, as well as strategic task ordering to maximize downstream benefit. Through extensive empirical analysis of 5,000 random sequences spanning a range of lengths, we identified an optimal sequence length of six and introduced a Donor Score to quantify a task’s marginal benefit to others. This analysis revealed a small set of consistently strong donors, i.e. Age, AD/MCI (Alzheimer’s Disease/Mild Cognitive Impairment), MMSE (Mini-Mental State Examination), Hypertension, Hyperlipidemia, which we use to construct a robust base sequence.

We evaluated GenFAR under both learning frameworks across 17 clinically relevant tasks encompassing cognition, neurologic diagnosis, demographics, various risk factors, and cerebrospinal fluid (CSF) biomarkers. The models were trained on a large, heterogeneous dataset of 49,246 3D T1-weighted brain MRIs drawn from 11 studies and multiple scanner vendors and protocols, with minimal preprocessing to preserve full spatial context. We assessed generalization using a leave-task-out scheme that holds out each task in turn and trains secondary predictors solely on the features learned from the remaining tasks. We further examined sample-efficiency by restricting the downstream training set size and evaluated study-to-study generalization on a separate external cohort. Across these settings, we found that the sequential framework consistently improved upon the independent framework and direct training, with especially pronounced gains in low-data regimes and for classification endpoints. The independent channels remain a strong baseline and a modular component of the overall GenFAR design. Taken together, GenFAR contributes a clinically anchored, brain-specific foundation for predictive modeling that complements recent self-supervised and segmentation-centric brain models by learning generalizable features from many supervised neuroimaging endpoints, providing a principled mechanism for structured knowledge transfer via sequential learning, and yielding practical gains in accuracy and sample-efficiency on unseen tasks, within and across studies.

Figure

Figure 1: Overview of the GenFAR model architecture and training frameworks. (A) GenFAR leverages 3D T1-weighted brain MRI scans paired with diverse clinical labels spanning cognition, genetics, aging, disease, and biomarkers to learn generalizable feature representations. The modular architecture leverages heterogeneous neuroimaging tasks to produce a unified, clinically-informed feature space. (B) Independent learning framework showing 17 parallel task-specific prediction channels operating independently. Each channel consists of a 3D Squeeze-and-Excitation (SE) ResNet followed by fully connected (FC) layers optimized for their respective tasks. Each channel processes the 3D brain scan and learns a 512-dimensional feature representation without inter-task knowledge sharing. Channels are optimized end-to-end using task-appropriate loss functions (binary cross-entropy for classification, mean squared error for regression). (C) Sequential learning framework where tasks are arranged in an optimized sequence. Later tasks receive both the 3D brain scan and concatenated feature representations from all preceding tasks (shown as colored bars), enabling progressive knowledge transfer. The first task operates identically to the independent framework, while subsequent tasks incrementally build upon previously learned representations. (D) Secondary predictor training for novel tasks. After primary training, convolutional weights of all task-specific channels are frozen to create a fixed GenFAR feature extractor. For new prediction tasks, 3D scans pass through the frozen GenFAR model to generate comprehensive feature representations (8,704 features for independent framework; 3,200 features for sequential framework). These features serve as input to a lightweight trainable deep encoder optimized for the novel task. This architecture enables efficient transfer learning, improving sample efficiency and performance on new tasks by leveraging representations learned from large-scale, diverse training.

A key contribution of this work lies in development of highly generalizable neuroimaging feature representations. To maximize their utility for the research community, the final model, along with a self-contained GPU and CPU inference pipelines, are publicly released on GitHub (https://github.com/vishnubashyam/GenFAR_Main) and released under an Open Responsible AI License (OpenRAIL). This accessible pipeline allows researchers to easily extract these optimized, generalized features from their own raw neuroimaging scans, to be used in subsequent data analysis steps. We also provide a web portal via NiChart (https://neuroimagingchart.com/portal) to encourage direct use of GenFAR on the cloud without installation or the need for computing resources. The web portal, hosted in the Amazon Web Services cloud, allows users to submit their raw T1 images by a simple drag and drop interface and to get back the extracted GenFAR feature set.