choderalab / espaloma

Extensible Surrogate Potential of Ab initio Learned and Optimized by Message-passing Algorithm 🍹https://arxiv.org/abs/2010.01196
https://docs.espaloma.org/en/latest/
MIT License
202 stars 23 forks source link

Trouble installing "espaloma=0.3.2" from Anaconda #213

Closed madilynpaul closed 2 months ago

madilynpaul commented 3 months ago

Hello, I'm having issues installing "espaloma=0.3.2" using the provided installation instructions on GitHub. When attempting to install espaloma via anaconda I'm being presented with the following error about the dgl dependency:

The following package could not be installed └─ espaloma 0.3.2** is not installable because it requires └─ dgl 1.1.2.* , which does not exist (perhaps a missing channel).

Thank you for the help! -Madilyn

ijpulidos commented 3 months ago

Hi!

Is this on an Apple silicon machine? If it is, then it's probably related to there not being a dgl 1.1.2.* package for that CPU architecture.

A workaround is to create the environment with the x86-64 arch that macOS on Silicon chips can run. This can be done using the CONDA_SUBDIR=osx-64 , more info in https://blog.rtwilson.com/how-to-create-an-x64-intel-conda-environment-on-your-apple-silicon-mac-arm-conda-install/ I hope this works!

Now, we probably would need to update the support to newer version of dgl, which already have packages for the osx-arm64 architecture, but I guess that requires a non-trivial refactor. We would need to check. Thanks for bringing this up!

beavenah commented 3 months ago

Hi @ijpulidos! I was having the same problem installing espaloma on an Apple M3 Pro machine. I tried the suggested workaround, but ran into another problem. Here's what I did:

CONDA_SUBDIR=osx-64 conda create -n espaloma
conda activate espaloma
conda env config vars set CONDA_SUBDIR=osx-64
conda deactivate
conda activate espaloma
conda install -c conda-forge "espaloma=0.3.2"

Output:

Channels:
 - conda-forge
 - defaults
Platform: osx-64
Collecting package metadata (repodata.json): done
Solving environment: / warning  libmamba Added empty dependency for problem type SOLVER_RULE_UPDATE
failed

LibMambaUnsatisfiableError: Encountered problems while solving:
  - package espaloma-0.3.2-pyhd8ed1ab_0 requires dgl 1.1.2.*, but none of the providers can be installed

Could not solve for environment specs
The following packages are incompatible
├─ espaloma 0.3.2**  is installable and it requires
│  └─ dgl 1.1.2.*  with the potential options
│     ├─ dgl 1.1.2 would require
│     │  └─ python >=3.10,<3.11.0a0 , which can be installed;
│     ├─ dgl 1.1.2 would require
│     │  └─ python >=3.11,<3.12.0a0 , which can be installed;
│     └─ dgl 1.1.2 would require
│        └─ python >=3.9,<3.10.0a0 , which can be installed;
└─ pin-1 is not installable because it requires
   └─ python 3.12.* , which conflicts with any installable versions previously reported.

Pins seem to be involved in the conflict. Currently pinned specs:
 - python 3.12.* (labeled as 'pin-1')

Can you please help me get this problem resolved? Thanks!

madilynpaul commented 3 months ago

I ran into this problem as well, and I believe I solved it by installing an older version of python! I believe I installed python 3.10.14 and it worked, let me know if this solves the problem.

Best, Madilyn Paul

On Wed, Apr 3, 2024 at 10:07 AM beavenah @.***> wrote:

Hi @ijpulidos https://github.com/ijpulidos! I was having the same problem installing espaloma on an Apple M3 Pro machine. I tried the suggested workaround, but ran into another problem. Here's what I did:

CONDA_SUBDIR=osx-64 conda create -n espaloma conda activate espaloma conda env config vars set CONDA_SUBDIR=osx-64 conda deactivate conda activate espaloma conda install -c conda-forge "espaloma=0.3.2"

Output:

Channels:

  • conda-forge
  • defaults Platform: osx-64 Collecting package metadata (repodata.json): done Solving environment: / warning libmamba Added empty dependency for problem type SOLVER_RULE_UPDATE failed

LibMambaUnsatisfiableError: Encountered problems while solving:

  • package espaloma-0.3.2-pyhd8ed1ab_0 requires dgl 1.1.2.*, but none of the providers can be installed

Could not solve for environment specs The following packages are incompatible ├─ espaloma 0.3.2* is installable and it requires │ └─ dgl 1.1.2. with the potential options │ ├─ dgl 1.1.2 would require │ │ └─ python >=3.10,<3.11.0a0 , which can be installed; │ ├─ dgl 1.1.2 would require │ │ └─ python >=3.11,<3.12.0a0 , which can be installed; │ └─ dgl 1.1.2 would require │ └─ python >=3.9,<3.10.0a0 , which can be installed; └─ pin-1 is not installable because it requires └─ python 3.12.* , which conflicts with any installable versions previously reported.

Pins seem to be involved in the conflict. Currently pinned specs:

  • python 3.12.* (labeled as 'pin-1')

Can you please help me get this problem resolved? Thanks!

— Reply to this email directly, view it on GitHub https://github.com/choderalab/espaloma/issues/213#issuecomment-2035017178, or unsubscribe https://github.com/notifications/unsubscribe-auth/A26BZUBDRMHRGNM5OXPCGSTY3QSM7AVCNFSM6AAAAABFJS3IQKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMZVGAYTOMJXHA . You are receiving this because you authored the thread.Message ID: @.***>

-- Madilyn Paul Materials Science and Engineering Boise State University

beavenah commented 3 months ago

Thanks @madilynpaul! Using python 3.10.14 appeared to work for me as well.

I wasn't able to fully run through the workflow though because I ran into an SSL error at the espaloma_model = esp.get_model("latest") step. I'll open a new issue for that though.

madilynpaul commented 3 months ago

Hi @ijpulidos!

Thank you for the help on this, I was able to get the environment built and it seems to be working great!

-Madilyn

ijpulidos commented 2 months ago

@madilynpaul That's great to hear. I'm closing this issue, feel free to reopen or keep commenting on it if needed.

@beavenah Sorry that getting the model is not working for you. Please raise a ticket with this issue and we can work on a solution.