Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: use matlab_cmd provided as input closes #2442 #2452

Merged
merged 8 commits into from
Feb 23, 2018
4 changes: 4 additions & 0 deletions nipype/interfaces/spm/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,10 @@ def getinfo(klass, matlab_cmd=None, paths=None, use_mcr=None):
If none of the above was successful, the fallback value of
'matlab -nodesktop -nosplash' will be used.
paths : str
Add paths to matlab session
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shouldn't we suggest that here should be also path to spm (that can be completely different than matlab) if we want to run spm interfaces ?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO, that's clear from the function description: "Returns the path to the SPM directory in the Matlab path".

use_mcr : bool
Whether to use the MATLAB Common Runtime. In this case, the
matlab_cmd is expected to be a valid MCR call.

Returns
-------
Expand All @@ -192,6 +195,7 @@ def getinfo(klass, matlab_cmd=None, paths=None, use_mcr=None):
'path': klass._path,
'release': klass._version
}
logger.debug('matlab command or path has changed. recomputing version.')
mlab = MatlabCommand(matlab_cmd=matlab_cmd, resource_monitor=False)
mlab.inputs.mfile = False
if paths:
Expand Down