Skip to content
Snippets Groups Projects
Commit 95d41c20 authored by David Flitney's avatar David Flitney
Browse files

*** empty log message ***

parent 6af7ebbb
No related branches found
No related tags found
No related merge requests found
......@@ -2,6 +2,6 @@ include ${FSLCONFDIR}/default.mk
PROJNAME = misc_scripts
SCRIPTS = regscript remove_vols replacevols replace_and_average_fmrib linkbedpost ocmr_preproc correct_and_average
SCRIPTS = regscript remove_vols replacevols replace_and_average_fmrib linkbedpost ocmr_preproc correct_and_average eddy_correct
all:
#!/bin/sh
# Copyright (C) 2004 University of Oxford
#
# SHCOPYRIGHT
Usage() {
echo ""
echo "Usage: eddy_correct <4dinput> <4doutput> <reference_no>"
echo ""
exit
}
[ "$3" = "" ] && Usage
input=`${FSLDIR}/bin/remove_ext ${1}`
output=`${FSLDIR}/bin/remove_ext ${2}`
ref=${3}
if [ `${FSLDIR}/bin/imtest $input` -eq 0 ];then
echo "Input does not exist or is not in a supported format"
exit
fi
avwroi $input $output $ref 1
avwsplit $input
full_list=`${FSLDIR}/bin/imglob -oneperimage vol*`
for i in $full_list ; do
echo processing $i
echo processing $i >> ${output}.ecclog
${FSLDIR}/bin/flirt -in $i -ref $output -nosearch -o $i -paddingsize 1 >> ${output}.ecclog
done
avwmerge -t $output $full_list
/bin/rm vol*
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment