Skip to content

Commit 86bb0bd

Browse files
authored
Update complex to support numpy 2.0 (#243)
* Update complex to support numpy 2.0 - np.complex_ is no longer in mumpy 2.0 - Should use complex128 instead. * Another ref
1 parent af3d58d commit 86bb0bd

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

unitary/alpha/qudit_state_transform.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ def qudit_to_qubit_state(
3939
qudit_dimension: int,
4040
num_qudits: int,
4141
qudit_state_vector: np.ndarray,
42-
_pad_value: np.complex_ = 0,
42+
_pad_value: np.complex128 = 0,
4343
) -> np.ndarray:
4444
"""Converts a qudit-space quantum state vector to m-qubit-per-qudit column vector.
4545

unitary/alpha/qudit_state_transform_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ def test_qudit_state_and_unitary_transform_equivalence(qudit_dim, num_qudits):
8585
(
8686
3,
8787
2,
88-
np.array([1, 0, 0, 0, 0, 0, 0, 0, 1], dtype=np.complex_),
88+
np.array([1, 0, 0, 0, 0, 0, 0, 0, 1], dtype=np.complex128),
8989
np.array(
9090
[
9191
1,

0 commit comments

Comments
 (0)