Figure 2.

Processing workflow from raw 4D fMRI data to Transformer input tokens: (1) Raw 4D fMRI data; (2) Structural image preprocessing and normalization; (3) Head motion correction and smoothing of functional images; (4) Removal of physiological noise and signal drift through nuisance regression and temporal filtering; (5) Feature engineering to construct three types of features, voxel patches, ROI time series, and functional connectivity matrices, and conversion into token sequences.