Generally it's ok to do that as only the shell sees it, FSL has nothing to with it.
But if you are having trouble, I would suggest putting those arguments into separate variables and printing them, just as you did for 'subj' and 'cond'. Something like (I assume your shell is tcsh):
set phasemap_dir=/mnt/e/${subj}/${subj}.${cond}
set eroded_dir=/mnt/e/${subj}/${subj}.${cond}/field_map_average
#print them both here. you could even check whether the directories exists.
echo "phasemap_dir= ..."
fsl_prepare_fieldmap SIEMENS ${phasemap_dir}/phase_map*.nii ${eroded_dir}/*eroded.nii prepared_fmap_rads.nii 2.46 --nocheck
Best,
Tim
> On October 24, 2018 at 6:30 PM Daniel Callow <[log in to unmask]> wrote:
>
>
> I am having trouble running the following fsl_prepare_fieldmap
>
> foreach subj (`ls -d /mnt/e/AES101 | sed 's/\// /g' | awk '{print $3}'`)
>
> foreach cond (Ex)
>
> echo "subj = " ${subj} ", cond = " ${cond}
>
> cd /mnt/e/${subj}/${subj}.${cond}/
>
> # Prepares a fieldmap suitable for FEAT from SIEMENS data - saves output in rad/s format
> # Example: fsl_prepare_fieldmap <scanner> <phase_image> <magnitude_image> <out_image> <deltaTE (in ms)> [--nocheck]
>
> fsl_prepare_fieldmap SIEMENS /mnt/e/${subj}/${subj}.${cond}/phase_map*.nii /mnt/e/${subj}/${subj}.${cond}/field_map_average/*eroded.nii prepared_fmap_rads.nii 2.46 --nocheck
>
> I get the output
>
> DESKTOP-U4H41O9:/mnt/e/scripts/2/field_map> ./fsl_prepare_fieldmap.sh
> subj = AES101 , cond = Ex
> fsl_prepare_fieldmap: No match.
>
>
> Is it okay to index to the files the way I have for my fsl_prepare_fieldmap? It seems like there is an issue with the imputs.
>
> Thanks for any advice you can provide!
>
> Daniel Callow
>
> ########################################################################
>
> To unsubscribe from the FSL list, click the following link:
> https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=FSL&A=1
>
--
Dr. Tim Schäfer
Postdoc Computational Neuroimaging
Department of Child and Adolescent Psychiatry, Psychosomatics and Psychotherapy
University Hospital Frankfurt, Goethe University Frankfurt am Main, Germany
########################################################################
To unsubscribe from the FSL list, click the following link:
https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=FSL&A=1
|