Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Evan Edmond
fslpy
Commits
4ea48533
Commit
4ea48533
authored
Nov 17, 2016
by
Paul McCarthy
Browse files
splitExt wrapper in image module.
parent
1de490d4
Changes
1
Hide whitespace changes
Inline
Side-by-side
fsl/data/image.py
View file @
4ea48533
...
...
@@ -26,6 +26,7 @@ and file names:
looksLikeImage
removeExt
splitExt
addExt
defaultExt
loadIndexedImageFile
...
...
@@ -799,6 +800,15 @@ def removeExt(filename):
return
fslpath
.
removeExt
(
filename
,
ALLOWED_EXTENSIONS
)
def
splitExt
(
filename
):
"""Splits the base name and extension for the given ``filename``.
See :func:`~fsl.utils.path.splitExt`.
"""
return
fslpath
.
splitExt
(
filename
,
ALLOWED_EXTENSIONS
)
def
addExt
(
prefix
,
mustExist
=
True
):
"""Adds a file extension to the given file ``prefix``.
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment