From 3e20063fd917f80368f468de8ddc5d1846c7e8ef Mon Sep 17 00:00:00 2001 From: kylebystrom Date: Thu, 20 Jun 2024 13:17:18 -0400 Subject: [PATCH] update test settings and flake compliance --- .github/workflows/full_env.yml | 1 + .github/workflows/nocomp_env.yml | 1 + .github/workflows/run_mpi_tests.sh | 2 +- ciderpress/pyscf/tests/test_nldf.py | 16 ++++++++-------- 4 files changed, 11 insertions(+), 9 deletions(-) diff --git a/.github/workflows/full_env.yml b/.github/workflows/full_env.yml index 1fe4898..848b048 100644 --- a/.github/workflows/full_env.yml +++ b/.github/workflows/full_env.yml @@ -16,6 +16,7 @@ dependencies: - numpy>=1.20.3,<1.25 - pyscf>=2.1 - pytest + - pytorch - pyyaml - scikit-learn>=1.0.1 - scipy>=1.7.1 diff --git a/.github/workflows/nocomp_env.yml b/.github/workflows/nocomp_env.yml index fb03e7f..a85f072 100644 --- a/.github/workflows/nocomp_env.yml +++ b/.github/workflows/nocomp_env.yml @@ -12,6 +12,7 @@ dependencies: - numpy>=1.20.3,<1.25 - pyscf>=2.1 - pytest + - pytorch - pyyaml - scikit-learn>=1.0.1 - scipy>=1.7.1 diff --git a/.github/workflows/run_mpi_tests.sh b/.github/workflows/run_mpi_tests.sh index 800867b..808f8e8 100644 --- a/.github/workflows/run_mpi_tests.sh +++ b/.github/workflows/run_mpi_tests.sh @@ -4,4 +4,4 @@ export PYTHONPATH=$(pwd):$PYTHONPATH ulimit -s 20000 version=$(python -c 'import sys; print("{0}.{1}".format(*sys.version_info[:2]))') -mpirun -np 2 pytest ciderpress/gpaw -s -c pytest_mpi.ini ciderpress +mpirun -np 2 --oversubscribe pytest ciderpress/gpaw -s -c pytest_mpi.ini ciderpress diff --git a/ciderpress/pyscf/tests/test_nldf.py b/ciderpress/pyscf/tests/test_nldf.py index 1ecc179..f115122 100644 --- a/ciderpress/pyscf/tests/test_nldf.py +++ b/ciderpress/pyscf/tests/test_nldf.py @@ -159,15 +159,15 @@ def _check_nldf_equivalence( else: l1k = _ifeat[:, n0 + 3 * k : n0 + 3 * k + 3] ifeat[:, n0 + i] = np.einsum("sxg,sxg->sg", l1j, l1k) - ijfeat = np.append(jfeat, ifeat, axis=1) + # ijfeat = np.append(jfeat, ifeat, axis=1) - ifeat_pred = get_descriptors( - analyzer, - self.vi_settings, - plan_type=plan_type, - aux_lambd=lambd, - aug_beta=beta, - ) + # ifeat_pred = get_descriptors( + # analyzer, + # self.vi_settings, + # plan_type=plan_type, + # aux_lambd=lambd, + # aug_beta=beta, + # ) # TODO uncomment after fixing vi stability # import traceback as tb # errs = {}