openmm / openmm-plumed

OpenMM plugin to interface with PLUMED
55 stars 23 forks source link

conda OSX-arm64? #75

Closed gitkol closed 5 months ago

gitkol commented 7 months ago

Hi, just wondering if there is a plan to provide conda installation on OSX-arm64?

Thanks,

Istvan

peastman commented 7 months ago

I didn't realize there weren't any. We certainly ought to have packages for it. PLUMED is available, so there shouldn't be any problem with adding it.

gitkol commented 7 months ago

Hi Peter, that would be great. I am testing OpenMM on a M2 machine with 60 GPU cores. OpenMM w/ OpenCL is only 4.5 times slower than w/ CUDA on RTX 2080 Ti, and I am pretty sure the gap would be narrower with OpenMM-PLUMED because of the unified memory on the M2.

Thanks,

Istvan

gitkol commented 7 months ago

Peter, I have a related question. Is PLUMED that you include in this package a vanilla version, or would you consider activating some of the more popular modules? For example, I configure PLUMED with ./configure CXXFLAGS=-O3 --enable-boost_serialization --enable-mpi --enable-openmp --enable-modules=drr but of course there are many other options. There is even a --enable-modules=all option, just wondering. Once you suggested a way to disable the built-in PLUMED and link a custom version, so that would work also.

Thanks,

Istvan

peastman commented 7 months ago

We don't include a copy of PLUMED. It comes from conda. Here is the feedstock where it gets built. That's the place to ask about how it is compiled.

gitkol commented 7 months ago

I see. My bad, sorry.

RaulPPelaez commented 5 months ago

The build is being attempted here https://github.com/conda-forge/openmm-plumed-feedstock/pull/25 Any help is welcome, I am not well versed in OSX.

gitkol commented 5 months ago

I see that the OSX-64 version of openmm-plumed 2.0 is out but that won't run on Apple Silicon.

(openmm8) istvankolossvary@IstvansacStudio Downloads % conda install conda-forge::openmm-plumed
Retrieving notices: ...working... done
Collecting package metadata (current_repodata.json): done
Solving environment: unsuccessful initial attempt using frozen solve. Retrying with flexible solve.
Collecting package metadata (repodata.json): done
Solving environment: unsuccessful initial attempt using frozen solve. Retrying with flexible solve.

PackagesNotFoundError: The following packages are not available from current channels:

  - conda-forge::openmm-plumed

Current channels:

  - https://repo.anaconda.com/pkgs/main/osx-arm64
  - https://repo.anaconda.com/pkgs/main/noarch
  - https://repo.anaconda.com/pkgs/r/osx-arm64
  - https://repo.anaconda.com/pkgs/r/noarch

Is there a plan to do an arm64 build? I believe the included plumed package has been built on arm64.

Thanks!

Istvan

peastman commented 5 months ago

We're working on it! https://github.com/conda-forge/openmm-plumed-feedstock/pull/32.

gitkol commented 5 months ago

Thanks! Greatly appreciated.

RaulPPelaez commented 5 months ago

https://github.com/conda-forge/openmm-plumed-feedstock/pull/32 has been merged. The build should be available in a few hours.

RaulPPelaez commented 5 months ago

I do not have a Mac to check but the packages should be there now. @peastman if you can check please confirm and close this one.

gitkol commented 5 months ago

Hi Raul,

I am trying it now and I am getting the following error. Does this give you a clue? The problem might be on my end, I don't know.

Thanks,

Istvan

Traceback (most recent call last):
  File "/Users/istvankolossvary/SandBox/OpenMM/Plumed-test/tl1a-meta-eABF-3D-FES_Fcv2.py", line 12, in <module>
    from openmmplumed import PlumedForce
  File "/Users/istvankolossvary/anaconda3/envs/openmm8/lib/python3.11/site-packages/openmmplumed.py", line 12, in <module>
    import _openmmplumed
ImportError: dlopen(/Users/istvankolossvary/anaconda3/envs/openmm8/lib/python3.11/site-packages/_openmmplumed.cpython-311-darwin.so, 0x0002): Library not loaded: @rpath/libgsl.25.dylib
  Referenced from: <94F2B1C5-F4C8-30AD-B8A3-E51098080DC3> /Users/istvankolossvary/anaconda3/envs/openmm8/lib/libplumedKernel.dylib
  Reason: tried: '/Users/istvankolossvary/anaconda3/envs/openmm8/lib/libgsl.25.dylib' (no such file), '/Users/istvankolossvary/anaconda3/envs/openmm8/lib/libgsl.25.dylib' (no such file), '/Users/istvankolossvary/anaconda3/envs/openmm8/lib/libgsl.25.dylib' (no such file), '/Users/istvankolossvary/anaconda3/envs/openmm8/lib/python3.11/site-packages/../../libgsl.25.dylib' (no such file), '/Users/istvankolossvary/anaconda3/envs/openmm8/lib/python3.11/site-packages/../../libgsl.25.dylib' (no such file), '/Users/istvankolossvary/anaconda3/envs/openmm8/bin/../lib/libgsl.25.dylib' (no such file), '/Users/istvankolossvary/anaconda3/envs/openmm8/bin/../lib/libgsl.25.dylib' (no such file), '/usr/local/lib/libgsl.25.dylib' (no such file), '/usr/lib/libgsl.25.dylib' (no such file, not in dyld cache)
RaulPPelaez commented 5 months ago

I have no idea and I do not have a Mac around to test it I am afraid... The feedstock does check that importing openmmplumed works. I might had missed some nuisance specific to OSX, like search paths for dynamic libraries...

Judging by the message your env seems to be missing the gsl library. But it is weird to me that the error did not appear in the feedstock to if that is the case.

gitkol commented 5 months ago

Good news, it was pilot error. I didn't realize that I installed openmm-plumed within an environment that had a n older version, 8.0 of OpenMM. Maybe the problem originated there. In any case with a fresh installation, everything works. Thanks!

Istvan

On Thu, Feb 1, 2024 at 11:04 AM Raul @.***> wrote:

I have no idea and I do not have a Mac around to test it I am afraid... The feedstock does check that importing openmmplumed works. I might had missed some nuisance specific to OSX, like search paths for dynamic libraries...

Judging by the message your env seems to be missing the gsl library. But it is weird to me that the error did not appear in the feedstock to if that is the case.

— Reply to this email directly, view it on GitHub https://github.com/openmm/openmm-plumed/issues/75#issuecomment-1921664715, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKDNJ2X3NIWFXZTSTWWERK3YRO4KNAVCNFSM6AAAAAA7LUY3ASVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMRRGY3DINZRGU . You are receiving this because you authored the thread.Message ID: @.***>

RaulPPelaez commented 5 months ago

phew! thats a relieve. Lets close this one then. Thanks all!