loos icon indicating copy to clipboard operation
loos copied to clipboard

integration with PLUMED

Open lgsmith opened this issue 2 years ago • 6 comments

Is your feature request related to a problem? Please describe. Not so much a problem as an expansion. Right now PLUMED often is used to perform analysis, and often it does this by calling tools or functions from within other analysis packages like MDAnalysis and MDTraj. It would be nice for loos to be an option for these users, as it would increase our user base and it would potentially be more performant than the alternatives. It's especially worthwhile if we can be included in some of PLUMED's extensive documentation, as many simulators come up referring to those docs.

Describe the solution you'd like Since I'm not a plumed user myself, I'm kind of the wrong guy to write this. Hoping other users who are more involved with PLUMED can add some detail here, but basically plumed script uses prefixes to indicate which surrogate library it ought to use, and what functionality should be called within that. It looks like a python wrapper.

Describe alternatives you've considered I just want LOOS everywhere I go. Is that too much to ask?

Additional context I got this suggestion from a fellow postdoc from the Bowman group, @sbhakat. I'll encourage him to comment on this to see if he has something more specific to request.

lgsmith avatar Feb 04 '22 03:02 lgsmith

Hi Team Loos, Currently Plumed supports calling analysis packages such as MDAnalysis or MDtraj to design collective variables. One can call MDAnalysis as follows:

MOLINFO STRUCTURE=helix.pdb PYTHON_BIN=python
g1: GROUP ATOMS=@mda:backbone

replace @mda with @mdt for MDTraj

Two advantages of having a python wrapper for Plumed are: 1) on-the fly tracking of CVs during MD or enhanced sampling 2) ability to design complex collective variables which then can be used for different enhanced sampling algorithms.

Keeping in mind bigger community base of Plumed, popularity within enhanced sampling community and availability of several reweighting, analysis & enhanced sampling protocols, I believe a Loos integration with Plumed will be give both users a lot of flexibility.

In my experience loos does a lot of great job specially in terms of standard post-dynamics analysis but specially in case of membrane proteins. I think at this stage a Loos wrapper for Plumed is a natural choice which will bring a lot of synergy. Will be happy to discuss with Team Loos :)

sbhakat avatar Feb 05 '22 15:02 sbhakat

I apologize for responding so slowly – it’s a crazy busy time for me.

I like the idea, but I won’t be able to touch it for a month or two at least.


Dr. Alan Grossfield Dept of Biochemistry and Biophysics University of Rochester Medical Center Phone: 585 276 4193 http://membrane.urmc.rochester.edu https://orcid.org/0000-0002-5877-2789 Pronouns: He/his

From: sbhakat @.> Reply-To: GrossfieldLab/loos @.> Date: Saturday, February 5, 2022 at 10:08 AM To: GrossfieldLab/loos @.> Cc: Subscribed @.> Subject: [EXT] Re: [GrossfieldLab/loos] integration with PLUMED (Issue #73)

Hi Team Loos, Currently Plumed supports calling analysis packages such as MDAnalysis or MDtraj to design collective variables. One can call MDAnalysis as follows:

MOLINFO STRUCTURE=helix.pdb PYTHON_BIN=python

g1: GROUP @.***:backbone

replace @mdahttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_mda&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=pMEtMfd0RIDSvGMf921R7haKhuI500p2KxtKwRcvMd4&e= with @mdthttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_mdt&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=Jvt0jc5HRHeQ0F2PKFJLYb605TFk3sfCvAuvuEhJ68E&e= for MDTraj

Two advantages of having a python wrapper for Plumed are: 1) on-the fly tracking of CVs during MD or enhanced sampling 2) ability to design complex collective variables which then can be used for different enhanced sampling algorithms.

Keeping in mind bigger community base of Plumed, popularity within enhanced sampling community and availability of several reweighting, analysis & enhanced sampling protocols, I believe a Loos integration with Plumed will be give both users a lot of flexibility.

In my experience loos does a lot of great job specially in terms of standard post-dynamics analysis but specially in case of membrane proteins. I think at this age a Loos integration with Plumed is a natural choice which will bring a lot of synergy. Will be happy to discuss with Team Loos :)

— Reply to this email directly, view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_GrossfieldLab_loos_issues_73-23issuecomment-2D1030641364&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=XpNzaeehyOz_wuGEMOedZn1O-nl4mEKgpFBkfCWZLEw&e=, or unsubscribehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_ADH754QBQMNN5IGJOFAWLBTUZU4NVANCNFSM5NQUQ64Q&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=kCCLQ6MeOI0SBMMD6eLJAGd40YUdasCsma0MIociPHI&e=. Triage notifications on the go with GitHub Mobile for iOShttps://urldefense.proofpoint.com/v2/url?u=https-3A__apps.apple.com_app_apple-2Dstore_id1477376905-3Fct-3Dnotification-2Demail-26mt-3D8-26pt-3D524675&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=cCtU1CaVpctP8lkWa-AuV3WN7zfyNKSvDznNsfKfo1s&e= or Androidhttps://urldefense.proofpoint.com/v2/url?u=https-3A__play.google.com_store_apps_details-3Fid-3Dcom.github.android-26referrer-3Dutm-5Fcampaign-253Dnotification-2Demail-2526utm-5Fmedium-253Demail-2526utm-5Fsource-253Dgithub&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=y7Sec5Zwnalx7dteeDZA3Ayd89_xNpXAweZv51mnL_w&e=. You are receiving this because you are subscribed to this thread.Message ID: @.***>

agrossfield avatar Feb 15 '22 01:02 agrossfield

Sorry -- not sure why I'm on this email. Perhaps you've got the wrong Marc Tanner?

On Mon, Feb 14, 2022 at 8:18 PM Grossfield Lab @.***> wrote:

I apologize for responding so slowly – it’s a crazy busy time for me.

I like the idea, but I won’t be able to touch it for a month or two at least.


Dr. Alan Grossfield Dept of Biochemistry and Biophysics University of Rochester Medical Center Phone: 585 276 4193 http://membrane.urmc.rochester.edu https://orcid.org/0000-0002-5877-2789 Pronouns: He/his

From: sbhakat @.> Reply-To: GrossfieldLab/loos @.> Date: Saturday, February 5, 2022 at 10:08 AM To: GrossfieldLab/loos @.> Cc: Subscribed @.> Subject: [EXT] Re: [GrossfieldLab/loos] integration with PLUMED (Issue #73)

Hi Team Loos, Currently Plumed supports calling analysis packages such as MDAnalysis or MDtraj to design collective variables. One can call MDAnalysis as follows:

MOLINFO STRUCTURE=helix.pdb PYTHON_BIN=python

g1: GROUP @.***:backbone

replace @mda< https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_mda&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=pMEtMfd0RIDSvGMf921R7haKhuI500p2KxtKwRcvMd4&e=> with @mdt< https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_mdt&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=Jvt0jc5HRHeQ0F2PKFJLYb605TFk3sfCvAuvuEhJ68E&e=> for MDTraj

Two advantages of having a python wrapper for Plumed are: 1) on-the fly tracking of CVs during MD or enhanced sampling 2) ability to design complex collective variables which then can be used for different enhanced sampling algorithms.

Keeping in mind bigger community base of Plumed, popularity within enhanced sampling community and availability of several reweighting, analysis & enhanced sampling protocols, I believe a Loos integration with Plumed will be give both users a lot of flexibility.

In my experience loos does a lot of great job specially in terms of standard post-dynamics analysis but specially in case of membrane proteins. I think at this age a Loos integration with Plumed is a natural choice which will bring a lot of synergy. Will be happy to discuss with Team Loos :)

— Reply to this email directly, view it on GitHub< https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_GrossfieldLab_loos_issues_73-23issuecomment-2D1030641364&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=XpNzaeehyOz_wuGEMOedZn1O-nl4mEKgpFBkfCWZLEw&e=>, or unsubscribe< https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_ADH754QBQMNN5IGJOFAWLBTUZU4NVANCNFSM5NQUQ64Q&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=kCCLQ6MeOI0SBMMD6eLJAGd40YUdasCsma0MIociPHI&e=>.

Triage notifications on the go with GitHub Mobile for iOS< https://urldefense.proofpoint.com/v2/url?u=https-3A__apps.apple.com_app_apple-2Dstore_id1477376905-3Fct-3Dnotification-2Demail-26mt-3D8-26pt-3D524675&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=cCtU1CaVpctP8lkWa-AuV3WN7zfyNKSvDznNsfKfo1s&e=> or Android< https://urldefense.proofpoint.com/v2/url?u=https-3A__play.google.com_store_apps_details-3Fid-3Dcom.github.android-26referrer-3Dutm-5Fcampaign-253Dnotification-2Demail-2526utm-5Fmedium-253Demail-2526utm-5Fsource-253Dgithub&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=SoriBZrAHCg5JZNTl3ZjQrA8q73fRtPNT3aVibzyzuU&s=y7Sec5Zwnalx7dteeDZA3Ayd89_xNpXAweZv51mnL_w&e=>.

You are receiving this because you are subscribed to this thread.Message ID: @.***>

— Reply to this email directly, view it on GitHub https://github.com/GrossfieldLab/loos/issues/73#issuecomment-1039748139, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABP2XJHSWVUOLSILF4UMHLU3GSWLANCNFSM5NQUQ64Q . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>

mdt avatar Feb 15 '22 01:02 mdt

Hello! Why don't we have a call and discuss possible PLUMED/LOOS integrations? @GiovanniBussi

maxbonomi avatar Feb 25 '22 09:02 maxbonomi

Hi all! I am not sure what's the purpose of the integration. PLUMED is primarily used for enhanced sampling, so we might be interested in collective variables computed in LOOS mostly if their derivatives are computed as well. On the other hand, if you want to compute PLUMED collective variables from LOOS, you can use its stable API (C++, or Python if you prefer). Here there's a lot of space for imagination, so perhaps a call could be useful.

You mentioned mdtraj and MDAnalysis: we currently only use those tools for atom selection that are done statically at the beginning of the simulation. If you think LOOS atom selection has some advantage it would be easy to add it (performance is not so critical, since it is done once).

The part of PLUMED managing the calls to mdtraj/MDAnalsys is not particularly modular or extensible, but the code is trivial so I guess you could just add a few lines to this file. This is a script that basically:

  • launches a python interpreter with which it communicates through stdin/stout
  • the interpreter then calls the required library with a python import (MDAnalysis/mdtraj) or launching a new process (vmd) and returns the resulting atom indexes to PLUMED as a string

Enabling @loos:backbone-like selections should be straightforward, and I would be happy to review a PR in this sense.

GiovanniBussi avatar Feb 25 '22 09:02 GiovanniBussi

I’ll take a look at that. The generality of loos’ selection language is one of its strengths, so it could be a worthy integration.

The other general strength is that it’s easy to quickly write custom analysis code, so it definitely could be useful for supplying collective variables and derivatives. I’ll try to look at what exists for mdanalysis next week so I know what I’d need to supply.

Dr. Alan Grossfield Department of Biochemistry and Biophysics University of Rochester Medical Center

On Feb 25, 2022, at 4:32 AM, Giovanni @.***> wrote:



Hi all! I am not sure what's the purpose of the integration. PLUMED is primarily used for enhanced sampling, so we might be interested in collective variables computed in LOOS mostly if their derivatives are computed as well. On the other hand, if you want to compute PLUMED collective variables from LOOS, you can use its stable API (C++, or Python if you prefer). Here there's a lot of space for imagination, so perhaps a call could be useful.

You mentioned mdtraj and MDAnalysis: we currently only use those tools for atom selection that are done statically at the beginning of the simulation. If you think LOOS atom selection has some advantage it would be easy to add it (performance is not so critical, since it is done once).

The part of PLUMED managing the calls to mdtraj/MDAnalsys is not particularly modular or extensible, but the code is trivial so I guess you could just add a few lines to this filehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_plumed_plumed2_blob_master_scripts_selector.sh&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=H4ce9NKH1xoDiqjP8Qa3SeU8FuUj_L1d_itHt1GaZXc&s=vKRxQJPzsU7nHd4DLQR06sSMk0k8keYWUTomMOYZuUs&e=. This is a script that basically:

Enabling @loos:backbone-like selections should be straightforward, and I would be happy to review a PR in this sense.

— Reply to this email directly, view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_GrossfieldLab_loos_issues_73-23issuecomment-2D1050687879&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=H4ce9NKH1xoDiqjP8Qa3SeU8FuUj_L1d_itHt1GaZXc&s=Tde-S3nDPTY2JEDYhem8LiE_UkY__RBglgPBXX_uf1g&e=, or unsubscribehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_ADH754WHM6ZKK6VNW5UTDPTU45EDBANCNFSM5NQUQ64Q&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=H4ce9NKH1xoDiqjP8Qa3SeU8FuUj_L1d_itHt1GaZXc&s=Hj_o7piuCwP1VIxsupmEqYGXvo-MJtNi8tIjj3L0J60&e=. Triage notifications on the go with GitHub Mobile for iOShttps://urldefense.proofpoint.com/v2/url?u=https-3A__apps.apple.com_app_apple-2Dstore_id1477376905-3Fct-3Dnotification-2Demail-26mt-3D8-26pt-3D524675&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=H4ce9NKH1xoDiqjP8Qa3SeU8FuUj_L1d_itHt1GaZXc&s=85GnpRU1s8-SsHeRyUfrjIZ7U72RFS1cKCP-YZgeeTc&e= or Androidhttps://urldefense.proofpoint.com/v2/url?u=https-3A__play.google.com_store_apps_details-3Fid-3Dcom.github.android-26referrer-3Dutm-5Fcampaign-253Dnotification-2Demail-2526utm-5Fmedium-253Demail-2526utm-5Fsource-253Dgithub&d=DwMCaQ&c=4sF48jRmVAe_CH-k9mXYXEGfSnM3bY53YSKuLUQRxhA&r=49qnaP-kgQR_zujl5kbj_PmvQeXyz1NAoiLoIzsc27zuRX32UDM2oX8NQCaAsZzH&m=H4ce9NKH1xoDiqjP8Qa3SeU8FuUj_L1d_itHt1GaZXc&s=TeT8ZzSGHu8XSZefyXI-S8z_BnoOVOAOlJAQoU_Inlk&e=. You are receiving this because you commented.Message ID: @.***>

agrossfield avatar Feb 25 '22 13:02 agrossfield