Skip to content

Commit ae6927f

Browse files
committed
make reading FSL version 10x faster
1 parent bda923d commit ae6927f

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

nipype/interfaces/fsl/base.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -73,10 +73,7 @@ def version():
7373
basedir = os.environ['FSLDIR']
7474
except KeyError:
7575
return None
76-
clout = CommandLine(command='cat',
77-
args='%s/etc/fslversion' % (basedir),
78-
terminal_output='allatonce').run()
79-
out = clout.runtime.stdout
76+
out = open('%s/etc/fslversion' % (basedir)).read()
8077
return out.strip('\n')
8178

8279
@classmethod
@@ -266,5 +263,4 @@ def no_fsl():
266263

267264
def no_fsl_course_data():
268265
"""check if fsl_course data is present"""
269-
270266
return not (os.path.isdir(os.path.abspath('fsl_course_data')))

0 commit comments

Comments
 (0)