Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
pyfeeds-tests
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
FSL
pyfeeds-tests
Commits
3fa7cdca
Commit
3fa7cdca
authored
3 years ago
by
Jesper Andersson
Committed by
Jesper Andersson
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fixed script to run also OpenMP test
parent
6c2590f6
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
EddyS2VTest/feedsRun
+21
-21
21 additions, 21 deletions
EddyS2VTest/feedsRun
with
21 additions
and
21 deletions
EddyS2VTest/feedsRun
+
21
−
21
View file @
3fa7cdca
...
...
@@ -6,10 +6,8 @@
# Graham, UCL, which allows us to have a ground
# truth. The data is a subset of that used
# for the s2v paper.
# At the time of writing this (May, 2017) the openmp version
# is not able to do slice-to-vol realignment. Hence only
# the cuda version is tested. The script should be updated
# if/when there is an openmp implementation of slice-to-vol.
# The script was updated in May 2021 to test also the openmp
# version.
#
odir
=
$1
...
...
@@ -35,10 +33,10 @@ do
exit
1
fi
done
#
if [ ! -x "${exedir}/eddy_openmp" ]; then
#
echo "Executable ${exedir}/eddy_openmp does not exist"
#
exit 1
#
fi
if
[
!
-x
"
${
exedir
}
/eddy_openmp"
]
;
then
echo
"Executable
${
exedir
}
/eddy_openmp does not exist"
exit
1
fi
if
[
!
-d
"
$odir
"
]
;
then
echo
"Output directory
${
odir
}
does not exist"
...
...
@@ -59,9 +57,9 @@ do
cuda_jid
=
"
$cuda_jid
`
fsl_sub
-l
${
odir
}
-q
cuda.q
${
cuda_exe
}
--imain
=
${
indir
}
/EddyS2VTestData/eddyData/testData
--mask
=
${
indir
}
/EddyS2VTestData/eddyData/testMask
--bvals
=
${
indir
}
/EddyS2VTestData/eddyData/testBvals
--bvecs
=
${
indir
}
/EddyS2VTestData/eddyData/testBvecs
--index
=
${
indir
}
/EddyS2VTestData/eddyData/testIndex
--acqp
=
${
indir
}
/EddyS2VTestData/eddyData/testAcqparams
--repol
--ol_type
=
slice
--ol_nstd
=
6
--ol_nvox
=
500
--niter
=
8
--fwhm
=
10,6,4,2,0,0,0,0
--out
=
${
odir
}
/eddyCudaOutput
${
version
}
--nvoxhp
=
5000
--mporder
=
16
--s2v_niter
=
10
--s2v_interp
=
trilinear
--s2v_lambda
=
1
--slspec
=
${
indir
}
/EddyS2VTestData/eddyData/testSlspec
--very_verbose
`
"
done
#
omp_jid=`fsl_sub -q long.q -s openmp,6 ${exedir}/eddy_openmp --imain=${indir}/EddyS2VTestData/eddyData/testData --mask=${indir}/EddyS2VTestData/eddyData/testMask --bvals=${indir}/EddyS2VTestData/eddyData/testBvals --bvecs=${indir}/EddyS2VTestData/eddyData/testBvecs --index=${indir}/EddyS2VTestData/eddyData/testIndex --acqp=${indir}/EddyS2VTestData/eddyData/testAcqparams --repol --ol_type=slice --ol_nstd=6 --niter=8 --fwhm=10,6,4,2,0,0,0,0 --out=${odir}/eddyOmpOutput --nvoxhp=5000 --mporder=16 --s2v_niter=10 --s2v_interp=trilinear --s2v_lambda=1 --slspec=${indir}/EddyS2VTestData/eddyData/testSlspec --very_verbose`
omp_jid
=
`
fsl_sub
-l
${
odir
}
-q
long.q
-s
openmp,6
${
exedir
}
/eddy_openmp
--imain
=
${
indir
}
/EddyS2VTestData/eddyData/testData
--mask
=
${
indir
}
/EddyS2VTestData/eddyData/testMask
--bvals
=
${
indir
}
/EddyS2VTestData/eddyData/testBvals
--bvecs
=
${
indir
}
/EddyS2VTestData/eddyData/testBvecs
--index
=
${
indir
}
/EddyS2VTestData/eddyData/testIndex
--acqp
=
${
indir
}
/EddyS2VTestData/eddyData/testAcqparams
--repol
--ol_type
=
slice
--ol_nstd
=
6
--niter
=
8
--fwhm
=
10,6,4,2,0,0,0,0
--out
=
${
odir
}
/eddyOmpOutput
--nvoxhp
=
5000
--mporder
=
16
--s2v_niter
=
10
--s2v_interp
=
trilinear
--s2v_lambda
=
1
--slspec
=
${
indir
}
/EddyS2VTestData/eddyData/testSlspec
--very_verbose
`
# Ensure that slots are being reserved on the queue
#
qalter ${omp_jid} -R y
qalter
${
omp_jid
}
-R
y
# Wait until they have both finished
...
...
@@ -75,15 +73,12 @@ while [ : ]; do
fi
done
if
[
$tmp
-eq
0
]
;
then
break
tmp
=
`
qstat
-j
${
omp_jid
}
|
wc
`
tmp
=
`
echo
$tmp
|
awk
'{print $1}'
`
if
[
$tmp
-eq
0
]
;
then
break
fi
fi
# if [ $tmp -eq 0 ]; then
# tmp=`qstat -j ${omp_jid} | wc`
# tmp=`echo $tmp | awk '{print $1}'`
# if [ $tmp -eq 0 ]; then
# break
# fi
# fi
sleep
5m
done
...
...
@@ -94,12 +89,14 @@ do
tmp
=
`
basename
$cuda_exe
`
version
=
`
echo
$tmp
|
sed
's/eddy_cuda//'
`
if
[
!
-f
${
odir
}
/eddyCudaOutput
${
version
}
.nii
*
]
;
then
echo
"Cuda output eddyCudaOutput
${
version
}
missing"
exit
1
fi
done
#if [ ! -f ${odir}/eddyOmpOutput.nii* ]; then
# exit 1
#fi
if
[
!
-f
${
odir
}
/eddyOmpOutput.nii
*
]
;
then
echo
"Omp output eddyOmpOutput missing"
exit
1
fi
# Define some constants
# These are for the comparison of output images divided on b=0, b=700 and b=2000
...
...
@@ -127,6 +124,9 @@ utput${version}.eddy_outlier_map ${indir}/EddyS2VTestData/eddyData/OutlierTruth/
done
omp_exit_status
=
0
./S2VFeeds.py
${
odir
}
Omp
`
imglob
-extension
${
indir
}
/EddyS2VTestData/eddyData/testMask
`
${
indir
}
/EddyS2VTestData/eddyData/testBvals
`
imglob
-extension
${
odir
}
/eddyOmpOutput
`
`
imglob
-extension
${
indir
}
/EddyS2VTestData/eddyData/GroundTruth/ground_truth
`
${
odir
}
/eddyOmpOutput.eddy_movement_over_time
${
indir
}
/EddyS2VTestData/eddyData/MovementTruth/ground_truth.eddy_movement_over_time
${
odir
}
/eddyOmpOutput.eddy_outlier_map
${
indir
}
/EddyS2VTestData/eddyData/OutlierTruth/dropoutLog_1.txt
${
max_ima_diff
}
${
max_false_pos
}
${
max_false_neg
}
${
max_trans_diff
}
${
max_rot_diff
}
omp_exit_status
=
$?
if
[
$cuda_exit_status
-gt
0
]
||
[
$omp_exit_status
-gt
0
]
;
then
echo
"Test failed"
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment