msmbuilder / msmbuilder-legacy

Legacy release of MSMBuilder
http://msmbuilder.org
GNU General Public License v2.0
25 stars 28 forks source link

RMSD sub-cammand is giving error when using tICA_train.py #460

Closed asgharrazavi closed 8 years ago

asgharrazavi commented 8 years ago

Hi,

I am trying to build tICA objects using rmsd sub-command in the tICA_train.py script. However, I receive the following error:

Traceback (most recent call last):
  File "/home/tud21702/anaconda/bin/tICA_train", line 9, in <module>
    load_entry_point('msmbuilder==2.8.2', 'console_scripts', 'tICA_train')()
  File "/home/tud21702/anaconda/lib/python2.7/site-packages/msmbuilder-2.8.2-py2.7.egg/msmbuilder/scripts/tICA_train.py", line 99, in entry_point
    output=args.output, min_length=min_length, stride=args.stride)
  File "/home/tud21702/anaconda/lib/python2.7/site-packages/msmbuilder-2.8.2-py2.7.egg/msmbuilder/scripts/tICA_train.py", line 53, in run
    tica_obj = tICA(lag=lag, calc_cov_mat=True, prep_metric=prep_metric)
  File "/home/tud21702/anaconda/lib/python2.7/site-packages/msmbuilder-2.8.2-py2.7.egg/msmbuilder/reduce/tICA.py", line 122, in __init__
    raise Exception("prep_metric must be an instance of a "
Exception: prep_metric must be an instance of a subclass of msmbuilder.metrics.Vectorized

I was wondering if you have a solution for this. I know that the "atompairs" sun-command works fine, but apparently the "rmsd" is not working.

Thank you, Asghar Razavi

rmcgibbo commented 8 years ago

RMSD and tICA are incompatible with one another. tICA is an algorithm that requires vectors in a euclidean space as input.

asgharrazavi commented 8 years ago

I thought, tICA object can be built using RMSD metric. In fact RMSD is an option when using tICA_train.py

$ tICA_train rmsd -h

usage: tICA_train rmsd [-h] [-a RMSD_ATOM_INDICES]

RMSD: Root mean square deviation over a set of user defined atoms (typically backbone heavy atoms or alpha carbons). To evaluate the distance between two structures, first they are rotated and translated with respect to one another to achieve maximum coincidence. This code is executed in parallel on multiple cores (but not multiple boxes) using OMP.

optional arguments: -h, --help show this help message and exit -a RMSD_ATOM_INDICES Atom indices to use in RMSD calculation. Pass "all" to use all atoms. Default: AtomIndices.dat