diff --git a/.ci_support/environment.yml b/.ci_support/environment.yml index 4ac2a652c..6814d099a 100644 --- a/.ci_support/environment.yml +++ b/.ci_support/environment.yml @@ -9,7 +9,7 @@ dependencies: - matplotlib-base =3.10.1 - nglview =3.1.4 - notebook -- numpy =1.26.4 +- numpy =2.3.1 - phonopy =2.41.1 - plotly =6.2.0 - pymatgen =2025.3.10 @@ -19,3 +19,4 @@ dependencies: - scipy =1.15.2 - spglib =2.6.0 - sqsgenerator =0.3 +- sparse =0.17.0 diff --git a/.ci_support/environment_mini.yml b/.ci_support/environment_mini.yml index 8041372c6..f197802a4 100644 --- a/.ci_support/environment_mini.yml +++ b/.ci_support/environment_mini.yml @@ -3,6 +3,6 @@ channels: dependencies: - ase =3.25.0 - coverage -- numpy =1.26.4 +- numpy =2.3.1 - scipy =1.15.2 - setuptools diff --git a/.github/workflows/pipeline.yml b/.github/workflows/pipeline.yml index c09fdf25c..ff431de6c 100644 --- a/.github/workflows/pipeline.yml +++ b/.github/workflows/pipeline.yml @@ -108,14 +108,10 @@ jobs: python-version: '3.11' label: linux-64-py-3-11 - - operating-system: ubuntu-latest - python-version: '3.10' - label: linux-64-py-3-10 - steps: - uses: actions/checkout@v4 - name: Merge conda environment - if: matrix.operating-system != 'windows-latest' + if: matrix.operating-system == 'ubuntu-latest' run: tail --lines=+4 .ci_support/environment-lammps.yml >> .ci_support/environment.yml - name: Conda config shell: bash -l {0} diff --git a/pyproject.toml b/pyproject.toml index 557d563bc..3aa5eab28 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -25,7 +25,7 @@ classifiers = [ ] dependencies = [ "ase==3.25.0", - "numpy==1.26.4", + "numpy==2.3.1", "scipy==1.15.2", ] dynamic = ["version"] diff --git a/tests/test_symmetry.py b/tests/test_symmetry.py index 1e29f5b71..4d390406c 100644 --- a/tests/test_symmetry.py +++ b/tests/test_symmetry.py @@ -136,10 +136,10 @@ def test_symmetrize_tensor(self): ).repeat(2) structure.symbols[0] = "Ni" symmetry = stk.analyse.get_symmetry(structure=structure) - self.assertLess(symmetry.symmetrize_tensor(np.random.randn(3)).ptp(), 1.0e-8) + self.assertLess(np.ptp(symmetry.symmetrize_tensor(np.random.randn(3))), 1.0e-8) sym_tensor = symmetry.symmetrize_tensor(np.random.randn(3, 3)) - self.assertLess(sym_tensor.diagonal().ptp(), 1.0e-8) - self.assertLess(sym_tensor[np.triu_indices(3, k=1)].ptp(), 1.0e-8) + self.assertLess(np.ptp(sym_tensor.diagonal()), 1.0e-8) + self.assertLess(np.ptp(sym_tensor[np.triu_indices(3, k=1)]), 1.0e-8) i = np.all(structure.positions == [0.5, 0, 0.5], axis=-1) j = np.all(structure.positions == [0, 0.5, 0.5], axis=-1) s_tensor = symmetry.symmetrize_tensor(np.random.randn(len(structure))) diff --git a/tests/test_visualize.py b/tests/test_visualize.py index 5b8f31d7a..3360818b6 100644 --- a/tests/test_visualize.py +++ b/tests/test_visualize.py @@ -31,7 +31,7 @@ def test_get_frame(self): dx, counts = np.unique( np.diff(frame, axis=-2).squeeze().astype(int), axis=0, return_counts=True ) - self.assertEqual(dx.ptp(), 1, msg="Frames not drawn along the nearest edges") + self.assertEqual(np.ptp(dx), 1, msg="Frames not drawn along the nearest edges") msg = ( "There must be four lines along each direction" + " (4 x [1, 0, 0], 4 x [0, 1, 0] and 4 x [0, 0, 1])"