From 81e8da36ba63426a8d0d142181263c0a20cb0558 Mon Sep 17 00:00:00 2001 From: mvanhooft Date: Mon, 18 Nov 2024 17:31:50 +0100 Subject: [PATCH] * Relax numpy requirement * Replace np.complex with complex --- setup.cfg | 2 +- squidasm/sim/network/network.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/setup.cfg b/setup.cfg index 239712f..9b01618 100644 --- a/setup.cfg +++ b/setup.cfg @@ -16,7 +16,7 @@ include_package_data = True install_requires = netsquid-netbuilder >=0.1.0, <0.2.0 click >=8.0, <9.0 - numpy >=1.22, <1.23 + numpy >=1.22, <2.0 scipy >=1.8, <2 pydantic >=1.8.2, < 3.0 pydynaa >=0.3, <2.0 diff --git a/squidasm/sim/network/network.py b/squidasm/sim/network/network.py index 3d401a2..364a0c2 100644 --- a/squidasm/sim/network/network.py +++ b/squidasm/sim/network/network.py @@ -53,7 +53,7 @@ from squidasm.sim.glob import QubitInfo, get_running_backend from squidasm.sim.network.nv_config import NVConfig, build_nv_qdevice -T_SingleQubitState = Tuple[Tuple[np.complex, np.complex]] +T_SingleQubitState = Tuple[Tuple[complex, complex]] EprDeliveredEvent: EventType = EventType( "EPR_DELIVERED", @@ -626,11 +626,11 @@ def _delivery_func(model_params: LinearDepolariseModelParameters, **kwargs): """ epr_state = np.array( [[0.5, 0, 0, 0.5], [0, 0, 0, 0], [0, 0, 0, 0], [0.5, 0, 0, 0.5]], - dtype=np.complex, + dtype=complex, ) maximally_mixed = np.array( [[0.25, 0, 0, 0], [0, 0.25, 0, 0], [0, 0, 0.25, 0], [0, 0, 0, 0.25]], - dtype=np.complex, + dtype=complex, ) return ( StateSampler(