Skip to content

Commit 77dd8fb

Browse files
committed
Try to debug numpy issue
1 parent 8afc9fb commit 77dd8fb

File tree

5 files changed

+27
-12
lines changed

5 files changed

+27
-12
lines changed

noxfile.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
nox.needs_version = ">=2025.10.16"
3333
nox.options.default_venv_backend = "uv"
3434

35-
PYTHON_ALL_VERSIONS = ["3.10", "3.11", "3.12", "3.13", "3.14"]
35+
PYTHON_ALL_VERSIONS = ["3.14"]
3636

3737
if os.environ.get("CI", None):
3838
nox.options.error_on_missing_interpreters = True
@@ -98,6 +98,7 @@ def _run_tests(
9898
)
9999
if extra_command:
100100
session.run(*extra_command, env=env)
101+
session.run("uv", "pip", "install", "threadpoolctl")
101102
if "--cov" in session.posargs:
102103
# try to use the lighter-weight `sys.monitoring` coverage core
103104
env["COVERAGE_CORE"] = "sysmon"

pyproject.toml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,10 @@ dependencies = [
5454
"numpy>=2.1.0, !=2.4.2; python_version >= '3.13'",
5555
"numpy>=2.3.2, !=2.4.2; python_version >= '3.14'",
5656
"networkx>=3.0",
57-
"scipy>=1.10; python_version < '3.12'",
58-
"scipy>=1.12; python_version >= '3.12'",
59-
"scipy>=1.15; python_version >= '3.13'",
60-
"scipy>=1.16.1; python_version >= '3.14'",
57+
# "scipy>=1.10; python_version < '3.12'",
58+
# "scipy>=1.12; python_version >= '3.12'",
59+
# "scipy>=1.15; python_version >= '3.13'",
60+
# "scipy>=1.16.1; python_version >= '3.14'",
6161
"h5py>=3.8; python_version >= '3.11'",
6262
"h5py>=3.12.1; python_version >= '3.12'",
6363
"h5py>=3.15.0; python_version >= '3.14'",
@@ -141,7 +141,7 @@ write_to = "python/mqt/qudits/_version.py"
141141

142142
[tool.pytest]
143143
minversion = "9.0"
144-
testpaths = ["test/python"]
144+
testpaths = ["test/python/test_array.py"]
145145
strict = true
146146
addopts = [
147147
"-ra",

test/python/test_array.npy

244 KB
Binary file not shown.

test/python/test_array.py

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Copyright (c) 2023 - 2026 Chair for Design Automation, TUM
2+
# Copyright (c) 2025 - 2026 Munich Quantum Software Company GmbH
3+
# All rights reserved.
4+
#
5+
# SPDX-License-Identifier: MIT
6+
#
7+
# Licensed under the MIT License
8+
9+
from pathlib import Path
10+
11+
import numpy as np
12+
13+
14+
def test_array() -> None:
15+
test_array_path = Path(__file__).parent / "test_array.npy"
16+
test_array = np.load(test_array_path)
17+
norm = np.linalg.norm(test_array)
18+
np.show_runtime()
19+
print(f"norm = {norm}")
20+
assert np.isclose(norm, 1.0)

uv.lock

Lines changed: 0 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)