forked from Becksteinlab/MDPOW
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Ensemble Objects (Becksteinlab#179)
* new Ensemble framework for aggregate analysis in mdpow.analysis * part of Becksteinlab#168 (adding analysis to MDPOW) * new submodule mdpow.analysis * new Ensemble, EnsembleAtomGroup, and EnsembleAnalysis classes * add docs (new section on Analysis) * add tests including ensemble test data (water simulations, octanol to be added later) * update CHANGES
- Loading branch information
1 parent
8c891be
commit 92cf7de
Showing
28 changed files
with
18,731 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
================== | ||
Analysis Submodule | ||
================== | ||
|
||
.. versionadded:: 0.8.0 | ||
|
||
MDPOW module for analyzing simulations. The :doc:`analysis/ensemble` objects | ||
and :doc:`analysis/ensemble_analysis` allow for the construction the simplified of analyses. | ||
|
||
The :doc:`analysis/ensemble` and :doc:`analysis/ensemble_analysis` sections | ||
assumes a basic understanding of object oriented programming in python and | ||
are for users who wish to construct their own analyses. | ||
|
||
|
||
.. toctree:: | ||
:maxdepth: 1 | ||
|
||
analysis/ensemble | ||
analysis/ensemble_analysis |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
================ | ||
Ensemble Objects | ||
================ | ||
|
||
.. versionadded:: 0.8.0 | ||
|
||
Ensemble | ||
________ | ||
|
||
The :class:`~mdpow.analysis.ensemble.Ensemble` object is a collection | ||
of :class:`MDAnalysis.Universe <MDAnalysis.core.groups.universe.Universe>` objects. | ||
It is intended to store the set of systems generated by running :program:`mdpow-fep`. | ||
|
||
The :class:`~mdpow.analysis.ensemble.Ensemble` object works by storing the | ||
systems in a dictionary and extending the functionality of an | ||
:class:`MDAnalysis.Universe <MDAnalysis.core.groups.universe.Universe>` to a collection | ||
of universes. It when given a directory finds the simulation files, reads then loads | ||
them into a dictionary. The object can be indexed the same as a dictionary, | ||
and has methods analogous the the :class:`MDAnalysis.Universe <MDAnalysis.core.groups.universe.Universe>` object. The main | ||
one being :meth:`~mdpow.analysis.ensemble.Ensemble.select_atoms` which returns a | ||
:class:`~mdpow.analysis.ensemble.EnsembleAtomGroup` . | ||
An :class:`~mdpow.analysis.ensemble.Ensemble` in its current form | ||
can also be built by manually adding and popping universes into an empty instance. | ||
|
||
.. autoclass:: mdpow.analysis.ensemble.Ensemble | ||
:members: | ||
|
||
.. automethod:: _build_ensemble | ||
|
||
.. automethod:: _load_universe_from_dir | ||
|
||
EnsembleAtomGroup | ||
_________________ | ||
|
||
The :class:`~mdpow.analysis.ensemble.EnsembleAtomGroup` is created by running | ||
the on an :class:`~mdpow.analysis.ensemble.Ensemble` | ||
:meth:`~mdpow.analysis.ensemble.Ensemble.select_atoms`. It stores | ||
:class:`MDAnalysis.AtomGroup <MDAnalysis.core.groups.AtomGroup>` selections of the groups | ||
generated by running select atom on individual universes in a dictionary with | ||
the same key structure as the parent :class:`~mdpow.analysis.ensemble.Ensemble` | ||
class. It returns a copy of the parent :class:`~mdpow.analysis.ensemble.Ensemble` | ||
object when the :meth:`~mdpow.analysis.ensemble.EnsembleAtomGroup.ensemble` is run. | ||
|
||
.. autoclass:: mdpow.analysis.ensemble.EnsembleAtomGroup | ||
:members: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
============================ | ||
Ensemble Analysis Framework | ||
============================ | ||
|
||
.. versionadded:: 0.8.0 | ||
|
||
The Analysis modules help in the implementation analyses of | ||
MDPOW simulations. To simplify the process of analyzing | ||
a collection of systems generated by a free energy simulation | ||
the objects in :doc:`analysis/ensemble` allow for a molecule directory's | ||
systems to be loaded into `MDAnalysis <https://mdanalysis.org>`_ | ||
Universes and be analyzed as a group. | ||
|
||
Ensemble Analysis Framework | ||
=========================== | ||
|
||
EnsembleAnalysis | ||
---------------- | ||
|
||
:class:`~mdpow.analysis.ensemble.EnsembleAnalysis` is a class inspired by the | ||
:class:`AnalysisBase <MDAnalysis.analysis.base.AnalysisBase>` from MDAnalysis which | ||
iterates over the systems in the ensemble and the frames in the systems. It sets up both iterations between | ||
universes and universe frames allowing for analysis to be run on both whole systems and the frames of those | ||
systems. This allows for users to easily run analyses on MDPOW simulations. | ||
|
||
.. autoclass:: mdpow.analysis.ensemble.EnsembleAnalysis | ||
:members: | ||
|
||
.. automethod:: _prepare_ensemble | ||
|
||
.. automethod:: _prepare_universe | ||
|
||
.. automethod:: _single_universe | ||
|
||
.. automethod:: _single_frame | ||
|
||
.. automethod:: _conclude_ensemble | ||
|
||
.. automethod:: _conclude_universe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Analysis Subpackage | ||
# Alia Lescoulie (ALescoulie) 2021 |
Oops, something went wrong.