Contrastive and Transfer Learning for Aligned Multimodal Neuroimaging Classification of Autism Spectrum Disorder.
Paper
Loaded from Europe PMC by your browser, not stored by OSCR: doi.org · Europe PMC
The paper is loaded when this pane is shown.
The authors' code
Python · 59 lines · 2.3 KB · Apache-2.0
- import os
- import torch
- import nibabel as nib
- from torch.utils.data import Dataset
- from torchvision import transforms
- import torch.nn.functional as F
- import scipy
- import numpy as np
- import pandas as pd
- class ABIDE_Data(Dataset):
- def __init__(self, root_dir):
- self.img_root_dir = root_dir+'/MRI'
- self.fc_root_dir = root_dir+'/fMRI'
- self.labels = pd.read_csv(root_dir+'/label.csv')['DX_GROUP']
- self.names = pd.read_csv(root_dir+'/label.csv')['SUB_ID']
- self.sub_names = [int(name) for name in os.listdir(self.fc_root_dir) if os.path.isdir(os.path.join(self.fc_root_dir, name))]
- self.transform = transforms.Compose([transforms.ToTensor()])
- self.img_file_paths = self._get_img_file_paths()
- self.fc_file_paths = self._get_fc_file_paths()
- def __len__(self):
- return len(self.img_file_paths)
- def __getitem__(self, idx):
- img_file_path = self.img_file_paths[idx]
- fc_file_path = self.fc_file_paths[idx]
- # Load NIfTI file using nibabel
- img = nib.load(img_file_path)
- img_data = img.get_fdata()
- img_data = (img_data - 224) / 224
- # Apply transformations (if needed)
- img_data = self.transform(img_data).permute(1,0,2)
- fc_data=scipy.io.loadmat(fc_file_path)['connectivity']
- fc_data=self._fc_feature(fc_data)
- label=torch.tensor([0,1]) if np.array(self.labels.iloc[self.names.tolist().index(self.sub_names[idx])] == 2) else torch.tensor([1,0])
- return img_data,fc_data,label
- def _get_img_file_paths(self):
- img_file_paths = []
- for subdir, dirs, files in os.walk(self.img_root_dir):
- for file in files:
- if file.endswith(".nii"):
- img_file_paths.append(os.path.join(subdir, file))
- return img_file_paths
- def _get_fc_file_paths(self):
- fc_file_paths = []
- for subdir, dirs, files in os.walk(self.fc_root_dir):
- for file in files:
- if file.endswith(".mat"):
- fc_file_paths.append(os.path.join(subdir, file))
- return fc_file_paths
- def _fc_feature(self, fc):
- # 提取上三角部分
- upper_triangular = np.triu(fc, k=1)
- # 转换为张量
- fc_tensor = torch.tensor(upper_triangular[np.nonzero(upper_triangular)])
- return fc_tensor
dataset.py at commit b1791e5, under Apache-2.0 · at the source
Overview
- Department of Information Technology, Benazir Bhutto Shaheed University Lyari, Karachi 75660, Sindh, Pakistan
- Department of Computing, Universiti Teknologi PETRONAS, Seri Iskandar 32610, Malaysia
- School of Computer Science and Informatics, De Montfort University, Leicester LE1 9BH, UK
- Department of Software Engineering, Mehran University of Engineering and Technology, Jamshoro 76062, Sindh, Pakistan
- School of Computing, Atlantic Technological University, F94 DV52 Letterkenny, Ireland
Abstract
Autism Spectrum Disorder (ASD) assessment remains challenging because behavioural instruments are partly observer-dependent and neuroimaging data are heterogeneous. This paper presents FAA (Fuse After Aligned), which is a multimodal classification framework that combines transfer learning for structural MRI (sMRI) representation learning with a contrastive objective for the pre-fusion alignment of sMRI and resting-state functional MRI-derived functional connectivity (FC) features. Evaluation was restricted to the single-site ABIDE-I New York University subset comprising 75 participants with ASD and 98 typically developing controls. Under the reported five-fold internal cross-validation protocol, FAA achieved a mean accuracy of 92.6% compared with 87.4% for naive fusion and 90.9% for the sMRI-only baseline. Ablation analyses indicate that adding the contrastive objective is associated with improved classification performance and that ResNet-18 outperforms the evaluated ViT-16 configurations in this small-sample setting. These findings support the methodological value of pre-fusion feature alignment within the evaluated cohort. The framework offers a robust, computationally efficient, and clinically viable approach for objective ASD diagnosis with strong potential for generalisation to multi-site neuroimaging applications.
Reproduced under the paper's license (CC BY), from the paper cited above.
Repository
Its files are read in the Code ↔ Paper reader above.
rajavavek/FAA-ASD-Neuroimaging
b1791e5ece3dcc044d146d7a7462027c057aa701, 18 June 2026Availability: 1 check, the latest on 27 September 2026: the link answers
- 27 September 2026: the link answers
49 files
- FC_plus_MRI/
data/ , Python, 59 linesdataset.py - FC_plus_MRI/
exp/ , Python, 36 linesexp_basic.py - FC_plus_MRI/
exp/ , Python, 186 linesexp_main.py - FC_plus_MRI/
models/ , Python, 44 linesCAA.py - FC_plus_MRI/
models/ , Python, 1 line__init__.py - FC_plus_MRI/
models/ , Python, 13 lineslayers/ FC_MLP.py - FC_plus_MRI/
models/ , Python, 16 lineslayers/ ResNet18.py - FC_plus_MRI/
models/ , Python, 16 lineslayers/ VIT16.py - FC_plus_MRI/
models/ , Python, 1 linelayers/ __init__.py - FC_plus_MRI/
run.py , Python, 75 lines - FC_plus_MRI/
scripts.sh , Shell, 10 lines - FC_plus_MRI/
utils/ , Python, 33 linestools.py - Only_FC/
data/ , Python, 59 linesdataset.py - Only_FC/
exp/ , Python, 36 linesexp_basic.py - Only_FC/
exp/ , Python, 186 linesexp_main.py - Only_FC/
models/ , Python, 48 linesCAA.py - Only_FC/
models/ , Python, 1 line__init__.py - Only_FC/
models/ , Python, 13 lineslayers/ FC_MLP.py - Only_FC/
models/ , Python, 16 lineslayers/ ResNet18.py - Only_FC/
models/ , Python, 16 lineslayers/ VIT16.py - Only_FC/
models/ , Python, 1 linelayers/ __init__.py - Only_FC/
run.py , Python, 69 lines - Only_FC/
utils/ , Python, 33 linestools.py - Only_MRI/
data/ , Python, 59 linesdataset.py - Only_MRI/
exp/ , Python, 36 linesexp_basic.py - Only_MRI/
exp/ , Python, 186 linesexp_main.py - Only_MRI/
models/ , Python, 48 linesCAA.py - Only_MRI/
models/ , Python, 1 line__init__.py - Only_MRI/
models/ , Python, 13 lineslayers/ FC_MLP.py - Only_MRI/
models/ , Python, 16 lineslayers/ ResNet18.py - Only_MRI/
models/ , Python, 16 lineslayers/ VIT16.py - Only_MRI/
models/ , Python, 1 linelayers/ __init__.py - Only_MRI/
run.py , Python, 76 lines - Only_MRI/
scripts.sh , Shell, 10 lines - Only_MRI/
utils/ , Python, 33 linestools.py - With_Contrastive_Learnin
g/ , Python, 59 linesdata/ dataset.py - With_Contrastive_Learnin
g/ , Python, 36 linesexp/ exp_basic.py - With_Contrastive_Learnin
g/ , Python, 186 linesexp/ exp_main.py - With_Contrastive_Learnin
g/ , Python, 45 linesmodels/ CAA.py - With_Contrastive_Learnin
g/ , Python, 1 linemodels/ __init__.py - With_Contrastive_Learnin
g/ , Python, 13 linesmodels/ layers/ FC_MLP.py - With_Contrastive_Learnin
g/ , Python, 16 linesmodels/ layers/ ResNet18.py - With_Contrastive_Learnin
g/ , Python, 16 linesmodels/ layers/ VIT16.py - With_Contrastive_Learnin
g/ , Python, 1 linemodels/ layers/ __init__.py - With_Contrastive_Learnin
g/ , Python, 77 linesrun.py - With_Contrastive_Learnin
g/ , Shell, 10 linesscripts.sh - With_Contrastive_Learnin
g/ , Python, 33 linesutils/ tools.py - LICENSE, License, 201 lines
- README.md, Text, 5 lines
The paper's code and data availability statement is in the Data section.
Tracing map
Proposed by the machine: these links were found in the paper and verified at the source, without human review. The map will receive a Zenodo DOI once one of the paper's authors has validated it with their ORCID.
What the map holds:
- 1 repository of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
- 47 scripts, each with its path and the digest of its content;
- no match between paragraphs and code yet;
- neither the text of the paper nor the code itself.
Its JSON (tracing-map.json) is deposited on Zenodo with its DOI once the map is validated.
Data
No dataset and no data link were found in the paper.
Data Availability Statement
The source code used in this paper is publicly available at https://
Reproduced under the paper's license (CC BY), from the paper cited above.
Versions
The history of this record: each version stored by the harvester or made by a correction of its authors or of the maintainers of its code, and what changed in its facts. The texts of the paper (its abstract, its availability statements) are not part of it; versions that changed only those are not listed.
Version 1, 27 September 2026: the first record
Recorded: type, language, journal, volume, issue, pages, dates, 5 authors, 5 keywords, 37 references.
Cite
This paper
Vavekanand, R., Kumar, G., Jawaid, M. M., Memon, S. Q., & Kumar, T. (2026). Contrastive and Transfer Learning for Aligned Multimodal Neuroimaging Classification of Autism Spectrum Disorder. Journal of imaging, 12(7), 328. https://
BibTeX
@article{vavekanand2026c
author = {Vavekanand, Raja and Kumar, Ganesh and Jawaid, Muhammad Moazzam and Memon, Shafiya Qadeer and Kumar, Teerath},
title = {{Contrastive and Transfer Learning for Aligned Multimodal Neuroimaging Classification of Autism Spectrum Disorder}},
journal = {Journal of imaging},
year = {2026},
month = jul,
volume = {12},
number = {7},
pages = {328},
publisher = {Multidisciplinary Digital Publishing Institute (MDPI)},
issn = {2313-433X},
doi = {10.3390/
url = {https://
pmid = {42506174},
pmcid = {PMC13412821}
}
RIS
TY - JOUR
AU - Vavekanand, Raja
AU - Kumar, Ganesh
AU - Jawaid, Muhammad Moazzam
AU - Memon, Shafiya Qadeer
AU - Kumar, Teerath
TI - Contrastive and Transfer Learning for Aligned Multimodal Neuroimaging Classification of Autism Spectrum Disorder
T2 - Journal of imaging
J2 - J Imaging
PY - 2026
DA - 2026/
VL - 12
IS - 7
SP - 328
SN - 2313-433X
PB - Multidisciplinary Digital Publishing Institute (MDPI)
DO - 10.3390/
UR - https://
LA - en
ER -
CSL-JSON
{
"id": "10.3390/
"type": "article-journal",
"title": "Contrastive and Transfer Learning for Aligned Multimodal Neuroimaging Classification of Autism Spectrum Disorder",
"container-title": "Journal of imaging",
"author": [
{
"family": "Vavekanand",
"given": "Raja"
},
{
"family": "Kumar",
"given": "Ganesh"
},
{
"family": "Jawaid",
"given": "Muhammad Moazzam"
},
{
"family": "Memon",
"given": "Shafiya Qadeer"
},
{
"family": "Kumar",
"given": "Teerath"
}
],
"container-title-short":
"volume": "12",
"issue": "7",
"page": "328",
"DOI": "10.3390/
"PMID": "42506174",
"PMCID": "PMC13412821",
"ISSN": "2313-433X",
"publisher": "Multidisciplinary Digital Publishing Institute (MDPI)",
"URL": "https://
"language": "en",
"issued": {
"date-parts": [
[
2026,
7,
20
]
]
}
}
The tracing map gets a citation of its own once an author has validated it and it has a DOI.
Similar papers
The papers with a page that share the most with this one: the tools found in their code, their categories, datasets, cited references and authors, the rarest counting most.
- [1] doi:10.1002/hbm.70469 [code]
- VarCoNet: A Variability-Aware Self-Supervised Framework for Functional Connectome Extraction From Resting-State fMRI.Journal: Human brain mappingIn common: NiBabel, PyTorch, scikit-learn, 3 other tools, autism, 3 references
- [2] doi:10.1038/s41598-026-58789-0 [code]
- Metaheuristic hyperparameter optimization of deep neural networks for demographic-aware autism spectrum disorder classification.Journal: Scientific reportsIn common: PyTorch, pandas, SciPy, 1 other tool, autism, 3 references
- [3] doi:10.21203/rs.3.rs-9326213/v1 [code]
- Multi-task fMRI outperforms resting-state fMRI for revealing task-invariant organization of the human brainJournal: Research Square (preprint)In common: NiBabel, PyTorch, scikit-learn, 3 other tools, 1 reference
- [4] doi:10.64898/2026.03.09.710558 [code]
- Multi-task fMRI outperforms resting-state fMRI for revealing task-invariant organization of the human brainJournal: bioRxiv (preprint)In common: NiBabel, PyTorch, scikit-learn, 3 other tools, 1 reference
- [5] doi:10.1016/j.patter.2026.101560 [code]
- Automating region selection with genetic algorithms for energy landscape analyses of brain dynamics.Journal: Patterns (New York, N.Y.)In common: PyTorch, pandas, SciPy, 1 other tool, autism, 2 references
- [6] doi:10.1162/imag.a.1220 [code]
- Brain functional network connectivity interpolation characterizes the neuropsychiatric continuum and heterogeneity.Journal: Imaging neuroscience (Cambridge, Mass.)In common: PyTorch, scikit-learn, pandas, 2 other tools, autism, 1 reference
- [7] doi:10.1038/s42003-026-10011-7 [code]
- Learning brain dynamics across distinct scaling regimes reveals psychiatric signatures.Journal: Communications biologyIn common: NiBabel, PyTorch, scikit-learn, 3 other tools, autism
- [8] doi:10.1038/s41598-026-50461-x [code]
- MACAFNet transformer-based multi-atlas fusion framework for autism spectrum disorder classification using functional connectivity.Journal: Scientific reportsIn common: autism, 3 references
- [9] doi:10.1002/hbm.70483 [code]
- Untamed: Unconstrained Tensor Decomposition and Graph Node Embedding for Cortical Parcellation.Journal: Human brain mappingIn common: NiBabel, PyTorch, scikit-learn, 2 other tools, 1 reference
- [10] doi:10.1155/da/8792696 [code]
- Connectome Gradient-Based Subtyping of Major Depressive Disorder Reveals Distinct Neurobiological and Transcriptomic Signatures.Journal: Depression and anxietyIn common: NiBabel, scikit-learn, pandas, 2 other tools, 1 reference
Contribute
The authors of this paper can claim it, correct its record and validate its tracing map, and the maintainers of its code (its owner, or a public member of its organization) correct what it says of their repository; anyone signed in can ask for its removal. Every request goes to OSCR's own machine, which answers it; your account page follows them.
Sign in with ORCID to claim this paper as one of its authors, correct its record or validate its tracing map: when the paper's metadata lists your ORCID iD, you are recognized at once. Maintainers of its code: sign in with GitHub, then claim the repository on your account page.
Claim this paper
Correct its record
Say what each link of this record is, remove the ones that are not the paper's, add the ones that are missing. The correction becomes a new version of the record, in its Versions section.
Validate its tracing map
You validate the map as this page shows it: 1 repository of the authors' code, each at its verified commit and with its license, 47 scripts, and 0 matches between paragraphs and code (see the Code and Map sections). It then receives a DOI on Zenodo, with you (your ORCID iD) and OSCR as its creators; the code itself is not deposited.
The map's fingerprint: sha256:bbbdff619002c013…
Add the badge to its README
The badge links the code to this page. Copy one of these into the README of the paper's code: only you decide where it goes, and nothing is changed for you.
Markdown
[, paste the snippet at the top, then “Commit changes…” and, to review it first, “Create a new branch and start a pull request”. You open the pull request; OSCR asks for no permission.
Request its removal
To ask OSCR to remove this record, the copies of its authors' scripts or its tracing map, use the removal request page: signed in, you say who you are, what to remove and why, then review and confirm the request. Published rules decide every request (how).
Discussion, reproductions, activity
Discussion: questions and error reports about this paper and its code, from signed-in readers and its authors. It opens with sign-in.
Reproductions: reports from readers who ran the authors' code: what they reproduced, with which environment, commit and data. It opens with sign-in.
Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.
