Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Errors with ANI #23

Open
peastman opened this issue Feb 16, 2022 · 14 comments
Open

Errors with ANI #23

peastman opened this issue Feb 16, 2022 · 14 comments

Comments

@peastman
Copy link
Member

I'm trying to use this on a new computer (an ARM Mac) for the first time, and I ran into an error I've never seen before. When it tries to compile the TorchANI model to TorchScript, I get the exception

RuntimeError: Could not cast attribute '_species_to_tensor' to type __torch__.torchani.utils.ChemicalSymbolsToInts (of Python compilation unit at: 0x600002facc98): Could not cast attribute 'rev_species' to type Dict[Tensor, int]: Unable to cast Python instance to C++ type (compile in debug mode for details)

I have PyTorch 1.10.0 and TorchANI 2.2, both installed from conda-forge. Has anyone seen this before?

@raimis
Copy link

raimis commented Feb 16, 2022

TorchANI 2.2 or 2.2.2?

@peastman
Copy link
Member Author

2.2. That's the most recent version available on conda-forge. They have 2.2.2 for linux-64 and osx-64, but only 2.2 for everything else.

@peastman
Copy link
Member Author

2.2 is also the most recent release at https://github.com/aiqm/torchani.

@raimis
Copy link

raimis commented Feb 16, 2022

The same issue like aiqm/torchani#598. You need TorchANI 2.2.2.

@raimis
Copy link

raimis commented Feb 16, 2022

2.2 is also the most recent release at https://github.com/aiqm/torchani.

They released TorchANI 2.2.2 (conda-forge/torchani-feedstock#3), but not updated https://github.com/aiqm/torchani

@peastman
Copy link
Member Author

Where can I get it from? It's neither on conda-forge nor github.

@peastman
Copy link
Member Author

I installed the latest TorchANI code from the main branch on github. I don't know whether that corresponds to 2.2.2, but it fixed the problem. We should make sure the noarch conda build gets updated before we release OpenMM-ML. Otherwise, we'll be getting a lot of bug reports from Mac and Windows users.

@jchodera
Copy link
Member

jchodera commented Feb 17, 2022 via email

@raimis
Copy link

raimis commented Feb 17, 2022

I installed the latest TorchANI code from the main branch on github. I don't know whether that corresponds to 2.2.2, but it fixed the problem.

Yes, it is on master (https://github.com/aiqm/torchani/releases/tag/2.2.2)

We should make sure the noarch conda build gets updated before we release OpenMM-ML. Otherwise, we'll be getting a lot of bug reports from Mac and Windows users.

Since TorchANI 2.2.1, it is not longer noarch, because of cuAEV (https://github.com/aiqm/torchani/blob/master/torchani/cuaev/README.md). It seems only Linux supported fully (https://anaconda.org/conda-forge/torchani/files). The Mac packages are built without CUDA. The Windows packages don't exist.

@raimis
Copy link

raimis commented Feb 17, 2022

Ping @yueyericardo

@peastman
Copy link
Member Author

No CUDA on Mac is fine, but there's only a package for x86, not ARM.

@yueyericardo
Copy link

Hi, sorry for that! We will release a new version for noarch soon (maybe today or tomorrow).

@peastman
Copy link
Member Author

Thanks!

@yueyericardo
Copy link

Hi, osx_arm64 2.2.2 is added at conda-forge/torchani-feedstock#4, but sorry that we currently don't have time to investigate the ways to build windows version.

For osx_arm64 it could be installed with

conda install -c conda-forge torchani==2.2.2

torchani==2.2.2 is necessary, otherwise it will install noarch which is 2.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants