Skip to content

Instantly share code, notes, and snippets.

@ababino
Last active August 29, 2015 14:03
Show Gist options
  • Save ababino/25827a03c0a8bb65f24f to your computer and use it in GitHub Desktop.
Save ababino/25827a03c0a8bb65f24f to your computer and use it in GitHub Desktop.
Files for CPAC
# Select False if you intend to run CPAC on a single machine.
# If set to True, CPAC will attempt to submit jobs through the job scheduler / resource manager selected below.
runOnGrid : False
# Full path to the FSL version to be used by CPAC.
# If you have specified an FSL path in your .bashrc file, this path will be set automatically.
FSLDIR : /usr/share/fsl/5.0
# Sun Grid Engine (SGE) or Portable Batch System (PBS).
# Only applies if you are running on a grid or compute cluster.
resourceManager : SGE
# SGE Parallel Environment to use when running CPAC.
# Only applies when you are running on a grid or compute cluster using SGE.
parallelEnvironment : cpac
# SGE Queue to use when running CPAC.
# Only applies when you are running on a grid or compute cluster using SGE.
queue : all.q
# Number of cores (on a single machine) or slots on a node (cluster/grid) per subject. Slots are cores on a cluster/grid node.
# IMPORTANT: Number of Cores Per Subject multiplied by Number of Subjects to Run Simultaneously must not be greater than the total number of cores.
numCoresPerSubject : 1
# This number depends on computing resources.
numSubjectsAtOnce : 1
# Name for this pipeline configuration - useful for identification.
pipelineName : test_ants_th_0.5
# Directory where CPAC should store temporary and intermediate files.
workingDirectory : /home/some_user/02-networks/01-brain/working
# Directory where CPAC should write crash logs.
crashLogDirectory : /home/some_user/02-networks/01-brain/crash
# Directory where CPAC should place processed data.
outputDirectory : /home/some_user/02-networks/01-brain/output
# Create a user-friendly, well organized version of the output directory.
# We recommend all users enable this option.
runSymbolicLinks : [1]
# Generate quality control pages containing preprocessing and derivative outputs.
generateQualityControlImages : [1]
# Deletes the contents of the Working Directory after running.
# This saves disk space, but any additional preprocessing or analysis will have to be completely re-run.
removeWorkingDir : False
# Uses the contents of the Working Directory to regenerate all outputs and their symbolic links.
# Requires an intact Working Directory from a previous CPAC run.
reGenerateOutputs : False
# Loads anatomical images for processing by CPAC.
# Must be enabled to run preprocessing and analyses.
runAnatomicalDataGathering : [1]
# Loads functional images for processing by CPAC.
# Must be enabled to run preprocessing and analyses.
runFunctionalDataGathering : [1]
# Runs the anatomical preprocessing workflow.
# Must be enabled to run any subsequent processing or analysis workflows.
runAnatomicalPreprocessing : [1]
# Runs the functional preprocessing workflow.
# Must be enabled to run any subsequent processing or analysis workflows.
runFunctionalPreprocessing : [1]
# Decides format of outputs. Off will produce non-z-scored outputs, On will produce z-scores of outputs, and On/Off will produce both.
runZScoring : [1]
# Register anatomical images to a template.
runRegistrationPreprocessing : [1]
# The resolution to which anatomical images should be transformed during registration.
# This is the resolution at which processed anatomical files will be output.
standardResolutionAnat : 1mm
# Template to be used during registration.
# It is not necessary to change this path unless you intend to use a non-standard template.
standardResolutionBrainAnat : /usr/share/fsl/5.0/data/standard/MNI152_T1_${standardResolutionAnat}_brain.nii.gz
# Template to be used during registration.
# It is not necessary to change this path unless you intend to use a non-standard template.
standardAnat : /usr/share/fsl/5.0/data/standard/MNI152_T1_${standardResolutionAnat}.nii.gz
# Use either ANTS or FSL (FLIRT and FNIRT) as your anatomical registration method.
regOption : ['ANTS']
# Configuration file to be used by FSL to set FNIRT parameters.
# It is not necessary to change this path unless you intend to use custom FNIRT parameters or a non-standard template.
fnirtConfig : T1_2_MNI152_2mm
# Automatically segment anatomical images into white matter, gray matter, and CSF based on prior probability maps.
runSegmentationPreprocessing : [1]
# Only voxels with a White Matter probability greater than this value will be classified as White Matter.
# Can be a single value or a list of values separated by commas.
whiteMatterThreshold : [0.5]
# Only voxels with a Gray Matter probability greater than this value will be classified as Gray Matter.
# Can be a single value or a list of values separated by commas.
grayMatterThreshold : [0.5]
# Only voxels with a CSF probability greater than this value will be classified as CSF.
# Can be a single value or a list of values separated by commas.
cerebralSpinalFluidThreshold : [0.5]
# Full path to a directory containing binarized prior probability maps.
# These maps are included as part of the 'Image Resource Files' package available on the Install page of the User Guide.
# It is not necessary to change this path unless you intend to use non-standard priors.
prior_path : /usr/share/fsl/5.0/data/standard/tissuepriors/$standardResolution
# Full path to a binarized White Matter prior probability map.
# It is not necessary to change this path unless you intend to use non-standard priors.
PRIOR_WHITE : $prior_path/avg152T1_white_bin.nii.gz
# Full path to a binarized Gray Matter prior probability map.
# It is not necessary to change this path unless you intend to use non-standard priors.
PRIOR_GRAY : $prior_path/avg152T1_gray_bin.nii.gz
# Full path to a binarized CSF prior probability map.
# It is not necessary to change this path unless you intend to use non-standard priors.
PRIOR_CSF : $prior_path/avg152T1_csf_bin.nii.gz
# First timepoint to include in analysis.
# Default is 0 (beginning of timeseries).
startIdx : 0
# Last timepoint to include in analysis.
# Default is None or End (end of timeseries).
stopIdx : None
# Specify the TR at which images were acquired.
# Default is None (TR information is read from image file header)
TR : None
# Run Functional to Anatomical Registration
runRegisterFuncToAnat : [1]
# Run Functional to Anatomical Registration with BB Register
runBBReg : [1]
# The resolution (in mm) to which functional images are transformed during registration
standardResolution : 2mm
# Standard FSL Skull Stripped Template. Used as a reference image for functional registration
standardResolutionBrain : /usr/share/fsl/5.0/data/standard/MNI152_T1_${standardResolution}_brain.nii.gz
# Standard FSL Anatomical Brain Image with Skull
standard : /usr/share/fsl/5.0/data/standard/MNI152_T1_$standardResolution.nii.gz
# Register functional images to a standard MNI152 template.
# This option must be enabled if you wish to calculate any derivatives.
runRegisterFuncToMNI : [1]
# Matrix containing all 1's. Used as an identity matrix during registration.
# It is not necessary to change this path unless you intend to use non-standard MNI registration.
identityMatrix : /usr/share/fsl/5.0/etc/flirtsch/ident.mat
# Standard FSL 5.0 Scheduler used for Boundary Based Registration.
# It is not necessary to change this path unless you intend to use non-standard MNI registration.
boundaryBasedRegistrationSchedule : /usr/share/fsl/5.0/etc/flirtsch/bbr.sch
# Run Nuisance Signal Correction
runNuisance : [1]
# Standard FSL Anatomical Brain Image
harvardOxfordMask : /usr/share/fsl/5.0/data/atlases/HarvardOxford/HarvardOxford-sub-maxprob-thr25-2mm.nii.gz
# Select which nuisance signal corrections to apply:
# compcor = CompCor
# wm = White Matter
# csf = CSF
# gm = Gray Matter
# global = Global Mean Signal
# pc1 = First Principle Component
# motion = Motion
# linear = Linear Trend
# quadratic = Quadratic Trend
Corrections :
- compcor : 0
wm : 1
csf : 1
global : 1
pc1 : 0
motion : 0
linear : 1
quadratic : 1
gm : 0
# Number of Principle Components to calculate when running CompCor. We recommend 5 or 6.
nComponents : [5]
# Correct for the global signal using Median Angle Correction.
runMedianAngleCorrection : [0]
# Target angle used during Median Angle Correction.
targetAngleDeg : [90]
# Apply a temporal band-pass filter to functional data.
runFrequencyFiltering : [1]
# Define one or more band-pass filters by clicking the + button.
nuisanceBandpassFreq : [[0.01, 0.1]]
# Use the Friston 24-Parameter Model during volume realignment.
# If this option is turned off, only 6 parameters will be used.
# These parameters will also be output as a spreadsheet.
runFristonModel : [1]
# Calculate motion statistics including Framewise Displacement (FD) and DVARS.
# Required to run Scrubbing.
# These parameters will also be output as a spreadsheet.
runGenerateMotionStatistics : [1]
# Remove volumes exhibiting excessive motion.
runScrubbing : [0]
# Specify the maximum acceptable Framewise Displacement (FD) in millimeters.
# Any volume exhibiting FD greater than this value will be removed.
scrubbingThreshold : [0.2]
# Number of volumes to remove preceeding a volume with excessive FD.
numRemovePrecedingFrames : 1
# Number of volumes to remove subsequent to a volume with excessive FD.
numRemoveSubsequentFrames : 2
# If you wish to specify new seeds (for use in Time Series Extraction and/or Seed-based Correlation Analysis), this field should contain the full path to a text file containing seed definitions.
# If you do not wish to specify new seeds, this field should be set to None.
# Seeds are defined by providing a seed label number, x/y/z coordinates in MNI space, seed radius (in mm), and resolution.
# Example:
# 1 -28 -40 -12 2 3mm
# 2 -4 48 24 3 2mm
# If multiple seeds are specified with the same resolution, they will be grouped into a single file containing multiple seeds, with the values within each seed ROI set to the seed label number.
# Note that CPAC does not check for overlapping seeds. In the event that a voxel is present in multiple seeds defined here, the value of that voxel will be set to the sum of the two seed label numbers (effectively resulting in a new seed). Users should confirm the seeds they define do not overlap before running CPAC.
seedSpecificationFile : None
# Directory where CPAC should write NIfTI files containing new seeds.
seedOutputLocation : /home/some_user/02-networks/data/1000_Functional_Connectomes
# It is possible to use the newly generated seeds when running a number of the analyses included in CPAC. Note that these analyses will be run using all new seeds.
# If you wish to use these new seeds to run Seed-based Correlation Analysis, select ROI Average Timeseries Extraction.
# If you do not wish to use new seeds in these analyses, select none.
useSeedInAnalysis : []
# Extract the average time series of one or more ROIs/seeds. Must be enabled if you wish to run Seed-based Correlation Analysis.
runROITimeseries : [0]
# Full path to a text file containing a list ROI files.
# Each line in this file should be the path to a NIfTI file containing one or more ROIs.
# If you only wish to extract time series for newly defined spherical seed ROIs, set this field to None.
roiSpecificationFile : None
# Full path to a text file containing a list ROI files.
# Each line in this file should be the path to a NIfTI file containing one or more ROIs.
# If you only wish to extract time series for newly defined spherical seed ROIs, set this field to None.
roiSpecificationFileForSCA : None
# By default, extracted time series are written as both a text file and a 1D file. Additional output formats are as a .csv spreadsheet or a Numpy array.
roiTSOutputs : [False, False]
# Extract the time series of all voxels within one or more ROIs/seeds.
runVoxelTimeseries : [0]
# Full path to a text file containing a list ROI files.
# Each line in this file should be the path to a NIfTI file containing a single ROI.
# If you only wish to extract time series for newly defined spherical seed ROIs, set this field to None.
maskSpecificationFile : None
# Full path to a text file containing a list ROI files.
# Each line in this file should be the path to a NIfTI file containing a single ROI.
# If you only wish to extract time series for newly defined spherical seed ROIs, set this field to None.
maskSpecificationFileForSCA : None
# By default, extracted time series are written as both a text file and a 1D file. Additional output formats are as a .csv spreadsheet or a Numpy array.
voxelTSOutputs : [False, False]
# Register timeseries data to a surface model built by FreeSurfer.
# Required to run vertex timeseries extraction. CPAC currently doesn't
# fully support surface extraction. Not Recommended.
runSurfaceRegistraion : [0]
# Directory where FreeSurfer outputs surface data.
# This should be the same as SUBJECTS_DIR in .bashrc
reconSubjectsDirectory : /home/some_user/02-networks/data/1000_Functional_Connectomes
# Extract timeseries data for surface vertices.CPAC currently doesn't
# fully support surface extraction. Not Recommended.
runVerticesTimeSeries : [0]
# Export vertices timeseries data
# First value = Output .csv
# Second value = Output numPy array
verticesTSOutputs : [False, False]
# Extract the time series from one or more existing spatial maps (such as an ICA map).
# Required if you wish to run Dual Regression.
runSpatialRegression : [0]
# Full path to a text file containing a list spatial maps.
# Each line in this file should be the path to a 4D NIfTI file containing one spatial map per volume.
spatialPatternMaps :
# Demean spatial maps before running spatial regression.
spatialDemean : True
# For each extracted ROI Average and/or ROI Voxelwise time series, CPAC will generate a whole-brain correlation map.
# It should be noted that for a given seed/ROI, SCA maps for ROI Average and ROI Voxelwise time series will be the same.
runSCA : [0]
# CPAC will enter all extracted time series from ROI Average TSE, ROI Voxelwise TSE, and Spatial Regression into a single multiple regression model and output a single correlation map.
runMultRegSCA : [0]
# Demean each time series before running Multiple Regression SCA.
mrsDemean : True
# Normalize each time series before running Multiple Regression SCA.
mrsNorm : True
# Run Dual Regression.
# Requires that Spatial Regression be enabled under Time Series Extraction.
runDualReg : [0]
# Normalize time series before running Dual Regression.
drNorm : True
# Calculate Voxel-mirrored Homotopic Connectivity (VMHC) for all voxels.
runVMHC : [1]
# Included as part of the 'Image Resource Files' package available on the Install page of the User Guide.
# It is not necessary to change this path unless you intend to use a non-standard symmetric template.
brainSymmetric : $FSLDIR/data/standard/MNI152_T1_${standardResolution}_brain_symmetric.nii.gz
# Included as part of the 'Image Resource Files' package available on the Install page of the User Guide.
# It is not necessary to change this path unless you intend to use a non-standard symmetric template.
symmStandard : $FSLDIR/data/standard/MNI152_T1_${standardResolution}_symmetric.nii.gz
# Included as part of the 'Image Resource Files' package available on the Install page of the User Guide.
# It is not necessary to change this path unless you intend to use a non-standard symmetric template.
twommBrainMaskDiluted : $FSLDIR/data/standard/MNI152_T1_${standardResolution}_brain_mask_symmetric_dil.nii.gz
# Included as part of the 'Image Resource Files' package available on the Install page of the User Guide.
# It is not necessary to change this path unless you intend to use a non-standard symmetric template.
configFileTwomm : $FSLDIR/etc/flirtsch/T1_2_MNI152_${standardResolution}.cnf
# Calculate Amplitude of Low Frequency Fluctuations (ALFF) and and fractional ALFF (f/ALFF) for all voxels.
runALFF : [1]
# Frequency cutoff (in Hz) for the high-pass filter used when calculating f/ALFF.
highPassFreqALFF : [0.01]
# Frequency cutoff (in Hz) for the low-pass filter used when calculating f/ALFF
lowPassFreqALFF : [0.1]
# Calculate Regional Homogeneity (ReHo) for all voxels.
runReHo : [1]
# Number of neighboring voxels used when calculating ReHo
# 7 (Faces)
# 19 (Faces + Edges)
# 27 (Faces + Edges + Corners)
clusterSize : 0
# Calculate Degree, Eigenvector Centrality, or Functional Connectivity Density.
runNetworkCentrality : [0]
# Full path to a text file containing a mask or list of ROIs.
# Each line of this file should contain the path to an ROI or mask.
# If a mask is specified, centrality will be calculated for all voxels within the mask.
# If a list of ROIs is specified, each ROI will be treated as a node, and centrality will be calculated for each node.
templateSpecificationFile :
# Enable/Disable degree centrality by selecting the connectivity weights
degWeightOptions : [False, False]
# Select the type of threshold used when creating the degree centrality adjacency matrix.
degCorrelationThresholdOption : 0
# Based on the Threshold Type selected above, enter a Threshold Value.
# P-value for Significance Threshold
# Sparsity value for Sparsity Threshold
# Pearson's r value for Correlation Threshold
degCorrelationThreshold : 0.001
# Enable/Disable eigenvector centrality by selecting the connectivity weights
eigWeightOptions : [False, False]
# Select the type of threshold used when creating the eigenvector centrality adjacency matrix.
eigCorrelationThresholdOption : 0
# Based on the Threshold Type selected above, enter a Threshold Value.
# P-value for Significance Threshold
# Sparsity value for Sparsity Threshold
# Pearson's r value for Correlation Threshold
eigCorrelationThreshold : 0.001
# Enable/Disable lFCD by selecting the connectivity weights
lfcdWeightOptions : [False, False]
# Select the type of threshold used when creating the lFCD adjacency matrix.
lfcdCorrelationThresholdOption : 0
# Based on the Threshold Type selected above, enter a Threshold Value.
# P-value for Significance Threshold
# Sparsity value for Sparsity Threshold
# Pearson's r value for Correlation Threshold
lfcdCorrelationThreshold : 0.001
# Maximum amount of RAM (in GB) to be used when calculating Degree Centrality.
# Calculating Eigenvector Centrality will require additional memory based on the size of the mask or number of ROI nodes.
memoryAllocatedForDegreeCentrality : 2.0
# Full Width at Half Maximum of the Gaussian kernel used during spatial smoothing.
# Can be a single value or multiple values separated by commas.
# Note that spatial smoothing is run as the last step in the individual-level analysis pipeline, such that all derivatives are output both smoothed and unsmoothed.
fwhm : [4]
# Run Bootstrap Analysis of Stable Clusters
runBASC : [0]
# Full path to a mask file to be used when running BASC. Voxels outside this mask will be excluded from analysis.
# If you do not wish to use a mask, set this field to None.
# Note: BASC is very computationally intensive, we strongly recommend you limit your analysis to specific brain areas of interest.
bascROIFile : None
# Number of bootstraps to apply to individual time series.
bascTimeseriesBootstraps : 100
# Number of bootstraps to apply to the original dataset.
bascDatasetBootstraps : 100
# Path to a text file containing correlation threshold for each subject. These thresholds will be applied to the correlation matrix before clustering.
# This file should contain one value per line, with each line corresponding to the subject on the same line in the group analysis subject list file.
# In most cases, the same threshold can be used for all subjects. Different thresholds are useful when subjects have time series of different lengths.
bascAffinityThresholdFile :
# Number of clusters to create during clustering at both the individual and group levels.
bascClusters : 6
# Run CWAS
runCWAS : [0]
# Path to a mask file. Voxels outside this mask will be excluded from CWAS.
cwasROIFile : None
# Path to a text file containing phenotypic regressor.
cwasRegressorFile : None
# Number of permutation tests to run on the Psuedo-F statistic.
cwasFSamples : 5000
# Number of NiPype nodes to be created while computing CWAS.
# This number depends on computing resources.
cwasParallelNodes : 10
# Column Number with Regressor of Interest.
# Remember this is 0 indexed so the 1st column is 0.
# For instance, assuming the 1st column is the intercept, column number with regressor of interest = 1
cwasRegressorCols : 0
# A list with length equal to the total number of rows in your regressor file.
# Each element of the list, indicates that elements group. Leave it as None.
# if you have a between-subject design and give it a value if not.
# For instance, if you have multiple scans per subject, then you would want to
# do a permutation within-subject between scans. For this to occur, the list
# below could be something like ['s1', 's1', 's2', 's2', 's3', 's3', ...],
# indicating what subject each element/scan is associated with and permutationswould only be done between scans within each subject.
cwasRegressorStrata : None
# Run group analysis using FSL/FEAT.
runGroupAnalysis : [0]
# This number depends on computing resources.
numGPAModelsAtOnce : 1
# Select which derivatives you would like to include when running group analysis.
# When including Dual Regression, make sure to correct your P-value for the number of maps you are comparing.
# When including Multiple Regression SCA, you must have more degrees of freedom (subjects) than there were time series.
derivativeList : []
# Use the + to add FSL model configuration to be run.
modelConfigs : []
# Set this option to True if any of the models specified above contain F-tests.
fTest : False
# Only voxels with a Z-score higher than this value will be considered significant.
zThreshold : 2.3
# Significance threshold (P-value) to use when doing cluster correction for multiple comparisons.
pThreshold : 0.05
# Run repeated measures to compare different scans (must use the group analysis subject list and phenotypic file formatted for repeated measures.
repeatedMeasures : False
-
subject_id: 'sub17017'
unique_id: ''
anat: '/path/to/data/1000_Functional_Connectomes/Baltimore/sub17017/anat/mprage_anonymized.nii.gz'
rest:
func_rest: '/path/to/data/1000_Functional_Connectomes/Baltimore/sub17017/func/rest.nii.gz'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment