From f470e7382a4f4e9e8f7cdca778d18e687e3ed8a1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 22 Nov 2024 22:10:55 +0800 Subject: [PATCH] Build(deps): Bump torch from 1.11.0 to 2.2.0 (#13) * Build(deps): Bump torch from 1.11.0 to 2.2.0 Bumps [torch](https://github.com/pytorch/pytorch) from 1.11.0 to 2.2.0. - [Release notes](https://github.com/pytorch/pytorch/releases) - [Changelog](https://github.com/pytorch/pytorch/blob/main/RELEASE.md) - [Commits](https://github.com/pytorch/pytorch/compare/v1.11.0...v2.2.0) --- updated-dependencies: - dependency-name: torch dependency-type: direct:production ... Signed-off-by: dependabot[bot] * update environment * update installation and dependency * update README * fix pydantic --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Han Yang --- README.md | 1 + environment.yaml | 18 ++++++++---------- pyproject.toml | 10 +++++++--- setup.py | 15 +++++++++++++++ 4 files changed, 31 insertions(+), 13 deletions(-) create mode 100644 setup.py diff --git a/README.md b/README.md index 2f2caa4..9c7d56b 100644 --- a/README.md +++ b/README.md @@ -24,6 +24,7 @@ To install the package, run the following command under the root of the folder: conda env create -f environment.yaml conda activate mattersim pip install -e . +python setup.py build_ext --inplace ``` ## Usage diff --git a/environment.yaml b/environment.yaml index ebb26ab..b50beec 100644 --- a/environment.yaml +++ b/environment.yaml @@ -3,21 +3,19 @@ channels: - pyg - pytorch - conda-forge + - nvidia dependencies: - python=3.9 - - pytorch==1.11.0 - - pytorch-sparse=0.6.15 - - pytorch-scatter=2.0.9 + - pytorch-sparse + - pytorch-scatter + - pytorch==2.2.0 + - torchvision==0.17.0 + - torchaudio==2.2.0 + - pytorch-cuda=11.8 - ca-certificates - openssl - numpy<2 - phonopy==2.14.0 - phono3py==2.3.0 - cython - - loguru - - pip: - - seekpath - - torch==1.11.0+cu113 - - torchvision==0.12.0+cu113 - - torchaudio==0.11.0+cu113 - - --extra-index-url https://download.pytorch.org/whl/cu113 + - loguru \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 01685bb..0ec74fa 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -22,16 +22,20 @@ classifiers = [ dependencies = [ "ase>=3.23.0", "e3nn==0.5.0", + "seekpath", "numpy<2", "pymatgen", "torch_geometric==2.5.3", - "torch==1.11.0", + "torch==2.2.0", "torch_runstats==0.2.0", "torchmetrics>=0.10.0", "torch-ema==0.3", "opt_einsum_fx", "azure-storage-blob", "azure-identity", + "mp-api", + "emmet-core<0.84", + "pydantic==2.9.2" ] [project.optional-dependencies] @@ -43,8 +47,8 @@ dev = [ [project.urls] -"Homepage" = "https://github.com/msr-ai4science/mattersim" -"Bug Tracker" = "https://github.com/msr-ai4science/mattersim/issues" +"Homepage" = "https://github.com/microsoft/mattersim" +"Bug Tracker" = "https://github.com/microsoft/mattersim/issues" [tool.setuptools] package-dir = {"" = "src"} diff --git a/setup.py b/setup.py new file mode 100644 index 0000000..529707d --- /dev/null +++ b/setup.py @@ -0,0 +1,15 @@ +from setuptools import setup, Extension +import numpy as np +from Cython.Build import cythonize + +extensions = [ + Extension( + "mattersim.datasets.utils.threebody_indices", + ["src/mattersim/datasets/utils/threebody_indices.pyx"], + include_dirs=[np.get_include()] + ) +] + +setup( + ext_modules=cythonize(extensions) +) \ No newline at end of file