diff --git a/CHANGELOG.md b/CHANGELOG.md index e70e46ad9..ba3a620fe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,7 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). -## Unreleased +## [0.4] - 2026-08-13 ### Added @@ -43,7 +43,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - #526: Added new method `XZCorrections.to_pauli_flow`, which reconstructs a Pauli flow directly from XZ-corrections by solving the per-node correction sets over GF(2). Added `FlowGenericErrorReason.NoPauliFlow`, raised when the XZ-corrections admit no compatible Pauli flow. -- #545: Added an amplitude damping noise model. Introduces `amplitude_damping_channel` / `two_qubit_amplitude_damping_channel`, the `AmplitudeDampingNoise` / `TwoQubitAmplitudeDampingNoise` noise elements, and `AmplitudeDampingNoiseModel`. +- #497, #540: Added an amplitude damping noise model. Introduces `amplitude_damping_channel` / `two_qubit_amplitude_damping_channel`, the `AmplitudeDampingNoise` / `TwoQubitAmplitudeDampingNoise` noise elements, and `AmplitudeDampingNoiseModel`. - #556, #563: Added a context variable `default_output_format` to unify the default output format for displaying `PauliFlow`, `XZCorrections`, `Pattern`, and `StateVec`. @@ -60,7 +60,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - #454, #481: Ensure `Pattern.minimize_space` only reduces max-space and does not increase it. -- #235, #489: Correct sign for `YZ` measurements in `from_pyzx_graph`. ZX diagrams are now correctly converted into open graphs, even if they are reduced. +- #482, #483: Ensure that `to_space_optimal_pattern` reorders output nodes - #510 - `Pattern.extract_opengraph` returns the same open graph before and after standardization. diff --git a/COMPATIBILITY.md b/COMPATIBILITY.md index 899a7eb3b..6bae9e0ef 100644 --- a/COMPATIBILITY.md +++ b/COMPATIBILITY.md @@ -2,7 +2,15 @@ Graphix does not guarantee backwards compatibility between 0.x version releases. Here we list API changes which may break existing code using Graphix. -## Unreleased +## [0.4] - 2026-08-13 + +- #484: J & CZ transpilation. + - Replaced `Circuit.transpile()` with a new approach based decomposing circuits into J & CZ gates. + - The transpiler now returns `TranspiledPattern` or `TranspiledFlow`, instead of `TranspileResult`. + +- #168, #498: `Pattern.remove_pauli_measurements` replaces `Pattern.perform_pauli_measurements`. + +- #468, #511: The `pyzx` module has been moved to a separate plugin: https://github.com/thierry-martinez/graphix-pyzx/ - #571: Method `Pattern.graph` (formely `Pattern.extract_graph`) is removed. Use instead `Pattern.to_opengraph().graph` which standardizes the pattern and fails gracefully if there are non-commutative Cliffords. @@ -55,4 +63,10 @@ Graphix does not guarantee backwards compatibility between 0.x version releases. | `MatGF2.compute_rank` | `MatGF2.rank` | | `Statevec` | `Statevector` | +- #567: + - Method `Circuit.simulate_statevector` has been renamed `Circuit.simulate`. + - Method `Pattern.simulate_pattern` has been renamed `Pattern.simulate`. + + - Field `SimulateResult.statevec` has been renamed `SimulateResult.state`. + - #568: Method `Pattern.infer_pauli_measurements` and function `transpile_swaps` now operate in place by default, with an optional `copy` parameter. If `copy=True`, a modified copy is returned instead. diff --git a/pyproject.toml b/pyproject.toml index 3825bf6cf..7e503dc45 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -29,7 +29,7 @@ dependencies = [ "matplotlib", "networkx", "numba>=0.65.1", - "numpy>=2", + "numpy>=2,<2.5", "quimb", "scipy", "sympy", diff --git a/uv.lock b/uv.lock index 47323f804..89f1b045b 100644 --- a/uv.lock +++ b/uv.lock @@ -936,7 +936,7 @@ requires-dist = [ { name = "nox", marker = "extra == 'dev'", specifier = "==2026.7.11" }, { name = "numba", specifier = ">=0.65.1" }, { name = "numba", marker = "python_full_version >= '3.11' and extra == 'typing'", specifier = "==0.66.0" }, - { name = "numpy", specifier = ">=2" }, + { name = "numpy", specifier = ">=2,<2.5" }, { name = "numpy", marker = "python_full_version == '3.10.*' and extra == 'typing'", specifier = "<2.4.2" }, { name = "numpy", marker = "python_full_version >= '3.11' and extra == 'typing'", specifier = "==2.4.2" }, { name = "pre-commit", marker = "extra == 'dev'" },