Skip to content

Error with installing openmmtorch and torch_scatter/torch_geometric #162

@AdeeshKolluru

Description

@AdeeshKolluru

I want to install openmm-torch and pyg. I'm wondering if there are any known versions of these packages that work together.

Simple test

conda create -n test python=3.12
conda activate test
conda install openmm-torch -c conda-forge

this installs torch2.5.1.post303 with cuda version 11.8 on my system.

now when I try to install other packages through pip (conda isn't able to find a matching version)

pip install pyg_lib torch_scatter torch_sparse torch_cluster torch_spline_conv -f https://data.pyg.org/whl/torch-2.5.1+cu118.html

its unable to install these packages correctly

>>> import torch_scatter
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "*/lib/python3.12/site-packages/torch_scatter/__init__.py", line 16, in <module>
    torch.ops.load_library(spec.origin)
  File "*/lib/python3.12/site-packages/torch/_ops.py", line 1350, in load_library
    ctypes.CDLL(path)
  File "*/lib/python3.12/ctypes/__init__.py", line 379, in __init__
    self._handle = _dlopen(self._name, mode)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^
OSError: */lib/python3.12/site-packages/torch_scatter/_version_cuda.so: undefined symbol: _ZN5torch3jit17parseSchemaOrNameERKSsb

It does seem like TorchMDNet uses all these packages but by default their environment.yml doesn't install openmm-torch. It would be great to know if there's any way around this.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions