Print

Print


Dear Experts
Thank you for sending me the dual_regression script.
Unfortunately I am having difficulty getting the dual_regression script to run properly (BTW I had to modify the script [via find and replace directory paths] so that it would run out of my home/bin [after copying all of the FSLDIR tools into my home/bin] instead of the FSLDIR/bin due to permission limitations on our servers.)

This is the command I enter attempting to simply complete stages 1-2 and obtain individual maps and group mean before proceeding to contrasts via randomise:
"
wisn0103@joy:~/bin$ dual_regression3 Dual_reg/melodics/melodic_IC 1 -1 0 Dual_reg/outputss/output1 Dual_reg/inputss/*
"
my inputs are the preprocessed filtered_func_data.nii.gz from 52 subjects 
my group ICA was completed as a multisession temporal concatenation of these 52 inputs (total vol each =240, T.R. = 2, highpass filter set to 100) with enforced dimensionality of 20 components.

No errors appear at the command line but the outputs are not complete.

Step drA and drB perform correctly. The error occurs at the drC step: 
dr_stage1_subject00000.txt files are not made although dr_stage2_subject00000.txt files and respective Z files are generated, albeit they are empty.

From the log files, I see I have the following error message in the a drC txt log file:

"
ERROR: GLM design does not match input image in size
Could not open matrix file Dual_reg/outputss/output1/dr_stage1_subject00000.txt
** ERROR (nifti_image_read): failed to find header file for 'Dual_reg/outputss/output1/dr_stage2_subject00000'
** ERROR: nifti_image_open(Dual_reg/outputss/output1/dr_stage2_subject00000): bad header info
Error: failed to open file Dual_reg/outputss/output1/dr_stage2_subject00000
Cannot open volume Dual_reg/outputss/output1/dr_stage2_subject00000 for reading!
"

I understand how the stage2 txt files are made and why empty based on this error.

Trying to detect how this occurred, in the drC echo log I see the following:
"
/home/wisn0103/bin/fsl_glm -i Dual_reg/inputss/IM02_filtered_func_data -d Dual_reg/melodics/melodic_IC -o Dual_reg/outputss/output1/dr_stage1_subject00000.txt --demean -m Dual_reg/outputss/output1/mask ;         /home/wisn0103/bin/fsl_glm -i Dual_reg/inputss/IM02_filtered_func_data -d Dual_reg/outputss/output1/dr_stage1_subject00000.txt -o Dual_reg/outputss/output1/dr_stage2_subject00000 --out_z=Dual_reg/outputss/output1/dr_stage2_subject00000_Z --demean -m Dual_reg/outputss/output1/mask --des_norm ;         /home/wisn0103/bin/fslsplit Dual_reg/outputss/output1/dr_stage2_subject00000 Dual_reg/outputss/output1/dr_stage2_subject00000_ic
"
as echo'd to the log per the script directions:
"
echo "doing the dual regressions"
j=0
for i in $INPUTS ; do
  s=subject`/home/wisn0103/bin/zeropad $j 5`
  echo "/home/wisn0103/bin/fsl_glm -i $i -d $ICA_MAPS -o $OUTPUT/dr_stage1_${s}.txt --demean -m $OUTPUT/mask ; \
"

I was at first confused that the fsl_glm was using the group level melodic_IC.nii.gz file with 20 maps as the design file, but after looking over the dual_reg poster again I understand that the .nii.gz file of group level maps, containing both spatial and temporal information, is indeed necessary to make the stage1 timeseries for each which will then be used to make the stage2 estimates for each person. (BTW I received the same error message when I tried to use a single probmap_#.nii.gz from the group ICA).

My questions are: 
Am I using the wrong file type for the group level spatial maps or the inputs?
How can I change my procedures in order to make the script run each part successfully?

Any advise will be greatly appreciated!
Many thanks in advance.

Krista Wisner
University of Minnesota