Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
fslpy
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Container Registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor 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
Michiel Cottaar
fslpy
Commits
15f69c0d
Commit
15f69c0d
authored
8 years ago
by
Paul McCarthy
Browse files
Options
Downloads
Patches
Plain Diff
Warnings if voxel EV files do not exist. Voxel confound EVs are named
according to their original file path.
parent
b1ad0825
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
fsl/data/featdesign.py
+18
-9
18 additions, 9 deletions
fsl/data/featdesign.py
with
18 additions
and
9 deletions
fsl/data/featdesign.py
+
18
−
9
View file @
15f69c0d
...
...
@@ -260,8 +260,11 @@ class VoxelwiseEV(NormalEV):
"""
NormalEV
.
__init__
(
self
,
realIdx
,
origIdx
,
title
)
if
op
.
exists
(
filename
):
self
.
filename
=
filename
else
:
self
.
filename
=
None
if
op
.
exists
(
filename
):
self
.
filename
=
filename
else
:
log
.
warning
(
'
Voxelwise EV file does not exist:
'
.
format
(
filename
))
self
.
filename
=
None
class
ConfoundEV
(
EV
):
...
...
@@ -337,8 +340,12 @@ class VoxelwiseConfoundEV(EV):
EV
.
__init__
(
self
,
index
,
title
)
self
.
voxIndex
=
voxIndex
if
op
.
exists
(
filename
):
self
.
filename
=
filename
else
:
self
.
filename
=
None
if
op
.
exists
(
filename
):
self
.
filename
=
filename
else
:
log
.
warning
(
'
Voxelwise confound EV file
'
'
does not exist:
'
.
format
(
filename
))
self
.
filename
=
None
def
getFirstLevelEVs
(
featDir
,
settings
,
designMat
):
...
...
@@ -388,9 +395,8 @@ def getFirstLevelEVs(featDir, settings, designMat):
# original EV index.
else
:
# The addExt function will
# raise an error if the
# file does not exist.
# The addExt function will raise an
# error if the file does not exist.
filename
=
op
.
join
(
featDir
,
'
designVoxelwiseEV{}
'
.
format
(
origIdx
+
1
))
filename
=
fslimage
.
addExt
(
filename
,
True
)
...
...
@@ -475,9 +481,12 @@ def getFirstLevelEVs(featDir, settings, designMat):
raise
FSFError
(
'
Unsupported voxelwise confound ordering
'
'
({} -> {})
'
.
format
(
startIdx
,
voxConfLocs
))
# Create the voxelwise confound EVs
# Create the voxelwise confound EVs.
# We make a name for the EV from the
# file name.
for
i
,
(
f
,
l
)
in
enumerate
(
zip
(
voxConfFiles
,
voxConfLocs
)):
evs
.
append
(
VoxelwiseConfoundEV
(
len
(
evs
),
i
,
'
voxconf
'
,
f
))
title
=
op
.
basename
(
fslimage
.
removeExt
(
f
))
evs
.
append
(
VoxelwiseConfoundEV
(
len
(
evs
),
i
,
title
,
f
))
# Have motion parameters been added
# as regressors to the design matrix?
...
...
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