When attempting to execute viewNMDinVMD() on Windows:
In [3]: viewNMDinVMD('p38_anm.nmd')
'C:\Program' is not recognized as an internal or external command,
operable program or batch file.
The default installation path from VMD is "C:\Program Files (x86)\University of Illinois\VMD", and commands to be executed in windows mus be wrapped with double quotes if the path contains spaces.
dynamics/nmdfile.py:450 should therefore be:
os.system('"{0}" -e "{1}"'.format(vmd, abspath(filename))) which should not break *nix systems.
However, there appears to be an issue with VMD that still prevents loading of the file (unless I've done something boneheaded). See here:http://pastebin.com/XHRYX5yi
This issue exists in at least 3 other places that I could find easily:
Alternatively, pathVMD() could first use utilities.which() to search for 'vmd' in the path (same for dssp, stride), since Windows developers will often place *nix tools in the path to minimize the pain.
Additionally, utilities.IsExecutable() does not use utilities.which() to search for 'vmd.exe' in the path, and therefore returns False, which did not allow me to work around this issue by manually setting: pathVMD("vmd")
When attempting to execute viewNMDinVMD() on Windows:
In [3]: viewNMDinVMD('p38_anm.nmd') 'C:\Program' is not recognized as an internal or external command, operable program or batch file.
The default installation path from VMD is "C:\Program Files (x86)\University of Illinois\VMD", and commands to be executed in windows mus be wrapped with double quotes if the path contains spaces.
dynamics/nmdfile.py:450 should therefore be: os.system('"{0}" -e "{1}"'.format(vmd, abspath(filename))) which should not break *nix systems.
However, there appears to be an issue with VMD that still prevents loading of the file (unless I've done something boneheaded). See here: http://pastebin.com/XHRYX5yi
This issue exists in at least 3 other places that I could find easily:
$ grep -Rn os.system * dynamics/nmdfile.py:450: os.system('{0} -e {1}'.format(vmd, abspath(filename))) proteins/dssp.py:66: status = os.system('{0} {1} > {2} 2> /dev/null'.format( proteins/dssp.py:69: status = os.system('{0} {1} > {2}'.format(dssp, pdb, out)) proteins/stride.py:62: status = os.system('{0} {1} > {2}'.format(stride, pdb, out))
Alternatively, pathVMD() could first use utilities.which() to search for 'vmd' in the path (same for dssp, stride), since Windows developers will often place *nix tools in the path to minimize the pain.
Additionally, utilities.IsExecutable() does not use utilities.which() to search for 'vmd.exe' in the path, and therefore returns False, which did not allow me to work around this issue by manually setting: pathVMD("vmd")