choderalab/msm-tis — pull request #33 by jhprinz (2014-10-19 14:19:59+00:00)
Title: Redo orderparameter

There it is. The storage overhaul... I am not sure if anyone is able to get through this crazy update. Sorry for any confusion. This is basically what happened:

#### Added functions
- Trajectory, Configuration and Momentum now support several storages. So they have a `dict(storage : index(int))` that holds this information. All of these can thus be stored in several files at the same time.
- This allowed to remove the global class variables in Trajectory, Snapshot, etc... It is even possible to store different versions of the same trajectory. Like a full one and a compressed one with only water and e.g. every 10th frame. This should also come in handy when we want to post process generate data for further evaluation
- the pdb is now also stored in the netdf file and from it the topology is constructed at startup
- I have moved the storage functionality to a seperate class so that Trajectory, Snapshot, etc only care about their functions and the associated Storage class, e.g. TrajectoryStorage knows how to store these objects in the netCDF storage
- The Storage Class is now a subclass of the netcdf which simplifies the access of variables a lot
- Orderparameters are now a subclass of a StorableFunctionDict. That is effectively a python dict from a Snapshot : Value. It has a function that is associated that can be changed and if an object is not in the dict the function will be called to fill the gap. This works effectively as a cached function. In addition these
StorableFunctionDicts can be saved in the storage and they can easily be attached to any object that is storable. Right now these are Configuration, Momentum and Trajectory. This means that we can use the exact same mechanism to store Variables associated with trajectories.
- Orderparameters now work with Trajectories, Snaphots, Configurations and lists of Configurations likewise
- All Storages are based upon a class ObjectStorage that provides basic functionality like, load, save, get free index, get last, first, etc...
- Updated documentation