Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions .github/workflows/ase-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,19 @@ jobs:
python -m pip install --upgrade pip
python -m pip install tox coverage


- name: install metatensor from labels-values-array-clean branch
run: |
pip install setuptools cmake packaging wheel
git clone --depth 1 --branch labels-values-array-clean https://github.com/HaoZeke/metatensor.git ${{ runner.temp }}/metatensor-v020
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_core
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_operations
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_learn
pip install torch
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_torch
env:
PIP_EXTRA_INDEX_URL: https://download.pytorch.org/whl/cpu

- name: run tests
run: tox -e ase-tests
env:
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/build-wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ name: Build Python wheels
on:
push:
tags: ["*"]
pull_request:
# Disabled for test/metatensor-v0.2.0: packaging requires released metatensor
# pull_request:
paths:
# build wheels in PR if this file changed
- '.github/workflows/build-wheels.yml'
Expand Down
13 changes: 13 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,19 @@ jobs:
python -m pip install tox
sudo apt install doxygen


- name: install metatensor from labels-values-array-clean branch
run: |
pip install setuptools cmake packaging wheel
git clone --depth 1 --branch labels-values-array-clean https://github.com/HaoZeke/metatensor.git ${{ runner.temp }}/metatensor-v020
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_core
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_operations
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_learn
pip install torch
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_torch
env:
PIP_EXTRA_INDEX_URL: https://download.pytorch.org/whl/cpu

- name: build documentation
env:
# Use the CPU only version of torch when building/running the code
Expand Down
13 changes: 13 additions & 0 deletions .github/workflows/torch-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,19 @@ jobs:
python -m pip install --upgrade pip
python -m pip install tox coverage


- name: install metatensor from labels-values-array-clean branch
run: |
pip install setuptools cmake packaging wheel
git clone --depth 1 --branch labels-values-array-clean https://github.com/HaoZeke/metatensor.git ${{ runner.temp }}/metatensor-v020
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_core
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_operations
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_learn
pip install torch
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_torch
env:
PIP_EXTRA_INDEX_URL: https://download.pytorch.org/whl/cpu

- name: run tests
run: tox -e lint,torch-tests,torch-tests-cxx,torch-install-tests-cxx,docs-tests
env:
Expand Down
13 changes: 13 additions & 0 deletions .github/workflows/torchsim-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,19 @@ jobs:
python -m pip install --upgrade pip
python -m pip install tox coverage


- name: install metatensor from labels-values-array-clean branch
run: |
pip install setuptools cmake packaging wheel
git clone --depth 1 --branch labels-values-array-clean https://github.com/HaoZeke/metatensor.git ${{ runner.temp }}/metatensor-v020
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_core
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_operations
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_learn
pip install torch
METATENSOR_NO_LOCAL_DEPS=1 pip install --no-build-isolation ${{ runner.temp }}/metatensor-v020/python/metatensor_torch
env:
PIP_EXTRA_INDEX_URL: https://download.pytorch.org/whl/cpu

- name: run tests
run: tox -e torchsim-tests
env:
Expand Down
7 changes: 5 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,14 @@ envlist =

[testenv]
passenv = *
sitepackages = true
setenv =
# Do not use the user PYTHONPATH, tox is handling everything
PYTHONPATH=
# store code coverage in a per-env file, so different envs don't override each other
COVERAGE_FILE={env_dir}/.coverage
# Prevent metatensor setup.py from using file:// local deps (conflicts with git URLs)
METATENSOR_NO_LOCAL_DEPS=1

package = skip
lint_folders = "{toxinidir}/python" "{toxinidir}/setup.py"
Expand All @@ -40,8 +43,8 @@ testing_deps =
pytest-cov

metatensor_deps =
metatensor-torch >=0.8.0,<0.9
metatensor-operations >=0.4.0,<0.5
metatensor-torch >=0.8.0
metatensor-operations >=0.4.0


################################################################################
Expand Down
Loading