Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
fslpy
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Analyze
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
fslpy
Commits
c0d35dc9
Commit
c0d35dc9
authored
6 years ago
by
Paul McCarthy
Browse files
Options
Downloads
Patches
Plain Diff
RF, STY: Improved mcflirt wrapper.
parent
80a089d1
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
fsl/wrappers/fast.py
+2
-3
2 additions, 3 deletions
fsl/wrappers/fast.py
fsl/wrappers/flirt.py
+17
-3
17 additions, 3 deletions
fsl/wrappers/flirt.py
with
19 additions
and
6 deletions
fsl/wrappers/fast.py
+
2
−
3
View file @
c0d35dc9
...
...
@@ -19,7 +19,7 @@ from . import wrapperutils as wutils
@wutils.fileOrImage
(
'
imgs
'
,
'
A
'
,
'
s
'
,
'
manualseg
'
,
outprefix
=
'
out
'
)
@wutils.fileOrArray
(
'
a
'
)
@wutils.fslwrapper
def
fast
(
imgs
,
out
=
"
fast
"
,
**
kwargs
):
def
fast
(
imgs
,
out
=
'
fast
'
,
**
kwargs
):
"""
Wrapper for the ``fast`` command.
:arg imgs: Input image(s)
...
...
@@ -31,8 +31,7 @@ def fast(imgs, out="fast", **kwargs):
if
isinstance
(
imgs
,
six
.
string_types
):
imgs
=
[
imgs
]
for
i
in
imgs
:
asrt
.
assertIsNifti
(
imgs
)
asrt
.
assertIsNifti
(
*
imgs
)
argmap
=
{
'
n_classes
'
:
'
class
'
,
...
...
This diff is collapsed.
Click to expand it.
fsl/wrappers/flirt.py
+
17
−
3
View file @
c0d35dc9
...
...
@@ -94,15 +94,29 @@ def concatxfm(inmat1, inmat2, outmat):
return
cmd
@wutils.fileOrImage
(
'
infile
'
,
'
out
'
,
'
reffile
'
)
@wutils.fileOrArray
(
'
init
'
)
@wutils.fileOrImage
(
'
infile
'
,
'
out
'
,
'
reffile
'
,
outprefix
=
'
out
'
)
@wutils.fileOrArray
(
'
init
'
,
outprefix
=
'
out
'
)
@wutils.fslwrapper
def
mcflirt
(
infile
,
**
kwargs
):
"""
Wrapper for the ``mcflirt`` command.
"""
asrt
.
assertIsNifti
(
infile
)
argmap
=
{
'
twod
'
:
'
2d
'
,
}
valmap
=
{
'
2d
'
:
wutils
.
SHOW_IF_TRUE
,
'
gdt
'
:
wutils
.
SHOW_IF_TRUE
,
'
meanvol
'
:
wutils
.
SHOW_IF_TRUE
,
'
stats
'
:
wutils
.
SHOW_IF_TRUE
,
'
mats
'
:
wutils
.
SHOW_IF_TRUE
,
'
plots
'
:
wutils
.
SHOW_IF_TRUE
,
'
report
'
:
wutils
.
SHOW_IF_TRUE
,
}
cmd
=
[
'
mcflirt
'
,
'
-in
'
,
infile
]
cmd
+=
wutils
.
applyArgStyle
(
'
-
'
,
**
kwargs
)
cmd
+=
wutils
.
applyArgStyle
(
'
-
'
,
argmap
=
argmap
,
valmap
=
valmap
,
**
kwargs
)
return
cmd
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