msmbuilder / msmbuilder-legacy

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

Update master to 2.8 #292

Closed rmcgibbo closed 10 years ago

rmcgibbo commented 10 years ago

Big merge.

This PR introduces the mdtraj dependency, and removes lots of cruft.

rmcgibbo commented 10 years ago

I'm going to tag a release of the current master as 2.7.0 before this merge happens.

rmcgibbo commented 10 years ago

https://github.com/SimTk/msmbuilder/releases/tag/2.7.0

kyleabeauchamp commented 10 years ago

Good On Jan 21, 2014 9:40 PM, "Robert McGibbon" notifications@github.com wrote:

I'm going to tag a release of the current master as 2.7.0 before this merge happens.

— Reply to this email directly or view it on GitHubhttps://github.com/SimTk/msmbuilder/pull/292#issuecomment-32988586 .

rmcgibbo commented 10 years ago

Let's get some comment on this from a quorum of @tjlane, @schwancr, @mpharrigan, etc before merging this. There's no rush.

tjlane commented 10 years ago

A quick scan looks good to me, but I admit I didn't delve into many details. Anything in particular you want reviewed @rmcgibbo since I'm not really working with MSMb right now?

+1 to getting mdtraj in

kyleabeauchamp commented 10 years ago

Here's my suggestion of what to look for (without having to invest 10 hours):

  1. Just glance at the code so you have an idea of how things will be working after the merge.
  2. Point out (here or as separate issues) any possible complications / subtle bugs that you foresee after glancing at the code.
kyleabeauchamp commented 10 years ago

So Danny and I will be doing some MSM-building, so we'll be working with this pretty extensively once it's merged. I think we should be able to find and patch any bugs that are still hidden.

kyleabeauchamp commented 10 years ago

OK so I've merged all my "minor" fixes and enhancements into the msmb2.8 branch. If people want to see what th changes are, they can look at the various merged Pull Requests.

rmcgibbo commented 10 years ago

It seems like testAssign just hangs sometimes? https://travis-ci.org/SimTk/msmbuilder/builds/17891035#L1451

rmcgibbo commented 10 years ago

There are a couple of sporatic problems with the travis build system, but this PR is in a working state now. We should merge. I will do it tomorrow afternoon.

schwancr commented 10 years ago

mdtraj uses simtk.units, is there some way to install just the units module? Or do I need to install all of openmm?

kyleabeauchamp commented 10 years ago

I think Robert has a way to install just the units part.

git+git://github.com/rmcgibbo/simtk.unit

schwancr commented 10 years ago

cool, thanks

schwancr commented 10 years ago

is it possible to install that with pip? It would be nice to have that dependency installed automatically

schwancr commented 10 years ago

I'm using this branch now, so I can be the guinea pig if there are bugs

rmcgibbo commented 10 years ago

I'm not sure exactly why simtk.units is required by msmbuilder2.8. In general, most of mdtraj should be okay without it.

Or maybe I should just bundle a copy of simtk.units inside mdtraj.

-Robert

On Jan 30, 2014, at 3:43 PM, Christian Schwantes notifications@github.com wrote:

I'm using this branch now, so I can be the guinea pig if there are bugs

— Reply to this email directly or view it on GitHub.

schwancr commented 10 years ago

here's the traceback:

In [2]: md.load('Trajectories/trj0.h5')

############################################################################

The code at unit.py:147 requires the simtk.unit module,
which is a python package for unit conversion.

simtk.unit is installed with OpenMM, which is available at http://openmm.org
It's also installable as a separate standalone package from
https://github.com/rmcgibbo/simtk.unit, and can be installed with the python
"pip" package mangers using:

pip install git+git://github.com/rmcgibbo/simtk.unit

############################################################################
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
/home/schwancr/vspm24_vol/vspm24_HD2/protG/fah_nug2/p7812/<ipython-input-2-f2dfa16a7d2d> in <module>()
----> 1 md.load('Trajectories/trj0.h5')

/home/schwancr/Installed/epd/lib/python2.7/site-packages/mdtraj-0.6.0-py2.7-linux-x86_64.egg/mdtraj/trajectory.pyc in load(filename_or_filenames, discard_overlapping_frames, **kwargs)
    282         kwargs.pop('top', None)
    283 
--> 284     return loader(filename, **kwargs)
    285 
    286 

/home/schwancr/Installed/epd/lib/python2.7/site-packages/mdtraj-0.6.0-py2.7-linux-x86_64.egg/mdtraj/hdf5.pyc in load_hdf5(filename, stride, atom_indices, frame)
    149             data = f.read(n_frames=1, atom_indices=atom_indices)
    150         else:
--> 151             data = f.read(stride=stride, atom_indices=atom_indices)
    152 
    153         topology = f.topology

/home/schwancr/Installed/epd/lib/python2.7/site-packages/mdtraj-0.6.0-py2.7-linux-x86_64.egg/mdtraj/hdf5.pyc in wrapper(*args, **kwargs)
     84             # args[0] is self on the method

     85             if args[0].mode in m:
---> 86                 return f(*args, **kwargs)
     87             raise ValueError('This operation is only available when a file '
     88                              'is open in mode="%s".' % args[0].mode)

/home/schwancr/Installed/epd/lib/python2.7/site-packages/mdtraj-0.6.0-py2.7-linux-x86_64.egg/mdtraj/hdf5.pyc in read(self, n_frames, stride, atom_indices)
    604         frames = Frames(
    605             coordinates = get_field('coordinates', (frame_slice, atom_slice, slice(None)),
--> 606                                     out_units='nanometers', can_be_none=False),
    607             time = get_field('time', frame_slice, out_units='picoseconds'),
    608             cell_lengths = get_field('cell_lengths', (frame_slice, slice(None)), out_units='nanometers'),

/home/schwancr/Installed/epd/lib/python2.7/site-packages/mdtraj-0.6.0-py2.7-linux-x86_64.egg/mdtraj/hdf5.pyc in get_field(name, slice, out_units, can_be_none)
    595                 if not isinstance(in_units, str):
    596                     in_units = in_units.decode()
--> 597                 data =  in_units_of(data, out_units, in_units)
    598                 return data
    599             except self.tables.NoSuchNodeError:

/home/schwancr/Installed/epd/lib/python2.7/site-packages/mdtraj-0.6.0-py2.7-linux-x86_64.egg/mdtraj/utils/unit.pyc in in_units_of(quantity, units_out, units_in)
    145     1000000.0
    146     """
--> 147     units = import_('simtk.unit')
    148 
    149     if quantity is None:

/home/schwancr/Installed/epd/lib/python2.7/site-packages/mdtraj-0.6.0-py2.7-linux-x86_64.egg/mdtraj/utils/delay_import.pyc in import_(module)
    191         print(m, file=sys.stderr)
    192         print(bar, file=sys.stderr)
--> 193         raise e

ImportError: No module named simtk.unit
schwancr commented 10 years ago

I'm not all that familiar with mdtraj to know if it needs to do that conversion step

rmcgibbo commented 10 years ago

You can now install simtk.unit with

pip install simtk.unit

kyleabeauchamp commented 10 years ago

Sweet, let me know if there's anything else we need to do before we merge this.

rmcgibbo commented 10 years ago

Okay. I'm starting the merge now.

kyleabeauchamp commented 10 years ago

Nice