Skip to content

Commit

Permalink
Do not export apply_single_*
Browse files Browse the repository at this point in the history
  • Loading branch information
Krastanov committed Mar 21, 2022
1 parent 2b5c495 commit a8c856b
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 9 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# News

## v0.4.1-dev
## v0.4.1

- `apply_single_*` are not exported anymore, as `sX`/`sY`/`sZ` are cleaner choices.
- Faster single-qubit projections with `projectX!`, `projectY!`, `projectZ!`.
- Move circuit plotting with `Quantikz.jl` to `QuantumCliffordPlots.jl`
- Random states with zeroed phases with `phases=false`.
Expand Down
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "QuantumClifford"
uuid = "0525e862-1e90-11e9-3e4d-1b39d7109de1"
authors = ["Stefan Krastanov <stefan@krastanov.org>"]
version = "0.4.1-dev"
version = "0.4.1"

[deps]
Combinatorics = "861a8166-3701-5b0c-9a16-15d98fcdc6aa"
Expand Down
1 change: 0 additions & 1 deletion src/QuantumClifford.jl
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ export @P_str, PauliOperator, ⊗, I, X, Y, Z, permute,
tensor, tensor_pow,
stab_to_gf2, gf2_gausselim!, gf2_isinvertible, gf2_invert, gf2_H_to_G,
single_z, single_x, single_y,
apply_single_z!, apply_single_x!, apply_single_y!,
random_invertible_gf2,
random_pauli, random_stabilizer, random_destabilizer, random_clifford,
bell, ghz,
Expand Down
2 changes: 1 addition & 1 deletion src/experimental/NoisyCircuits.jl
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ module NoisyCircuits
#TODO permit the use of alternative RNGs

using QuantumClifford
using QuantumClifford: AbstractStabilizer, AbstractCliffordOperator
using QuantumClifford: AbstractStabilizer, AbstractCliffordOperator, apply_single_x!, apply_single_y!, apply_single_z!

using StatsBase: countmap
using Combinatorics: combinations
Expand Down
6 changes: 3 additions & 3 deletions src/symbolic_cliffords.jl
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ end
# TODO is there a reason to keep these given that sZ/sX/sY exist?
# TODO currently these are faster than sZ/sX/sY

"""Apply a Pauli Z to the `i`-th qubit of state `s`. You might prefer to use `sZ` instead of this."""
"""Apply a Pauli Z to the `i`-th qubit of state `s`. You should use `apply!(stab,sZ(i))` instead of this."""
function apply_single_z!(stab::AbstractStabilizer, i)
s = tab(stab)
Tme = eltype(s.xzs)
Expand All @@ -438,7 +438,7 @@ function apply_single_z!(stab::AbstractStabilizer, i)
stab
end

"""Apply a Pauli X to the `i`-th qubit of state `s`. You might prefer to use `sX` instead of this."""
"""Apply a Pauli X to the `i`-th qubit of state `s`. You should use `apply!(stab,sX(i))` instead of this."""
function apply_single_x!(stab::AbstractStabilizer, i)
s = tab(stab)
Tme = eltype(s.xzs)
Expand All @@ -453,7 +453,7 @@ function apply_single_x!(stab::AbstractStabilizer, i)
stab
end

"""Apply a Pauli Y to the `i`-th qubit of state `s`. You might prefer to use `sY` instead of this."""
"""Apply a Pauli Y to the `i`-th qubit of state `s`. You should use `apply!(stab,sY(i))` instead of this."""
function apply_single_y!(stab::AbstractStabilizer, i)
s = tab(stab)
Tme = eltype(s.xzs)
Expand Down
3 changes: 2 additions & 1 deletion test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using Test, Random
using QuantumClifford
using QuantumClifford: stab_looks_good, mixed_stab_looks_good, destab_looks_good, mixed_destab_looks_good
using QuantumClifford: apply_single_x!, apply_single_y!, apply_single_z!
using QuantumClifford: mul_left!
using QuantumClifford: perm_inverse
using LinearAlgebra: inv
Expand Down Expand Up @@ -40,4 +41,4 @@ doset("graphs") && include("./test_graphs.jl")
doset("doctests") && include("./doctests.jl")

using Aqua
doset("aqua") && Aqua.test_all(QuantumClifford, ambiguities=false,project_toml_formatting=false)
doset("aqua") && Aqua.test_all(QuantumClifford, ambiguities=false,project_toml_formatting=false)
1 change: 0 additions & 1 deletion test/test_noisycircuits.jl
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
using QuantumClifford.Experimental.NoisyCircuits
using Quantikz: circuit2string, QuantikzOp
import AbstractAlgebra

function test_noisycircuits()
Expand Down

2 comments on commit a8c856b

@Krastanov
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator register

Release Notes:

  • apply_single_* are not exported anymore, as sX/sY/sZ are cleaner choices.
  • Faster single-qubit projections with projectX!, projectY!, projectZ!.
  • Move circuit plotting with Quantikz.jl to QuantumCliffordPlots.jl
  • Random states with zeroed phases with phases=false.
  • Pre-compilation and inference cleanup (useful for Julia 1.8+).
  • Switch from LoopVectorization.jl to SIMD.jl for fine-tuning of performance (and coincidentally, better TTFX).

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request updated: JuliaRegistries/General/56986

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.4.1 -m "<description of version>" a8c856b438d62d06252f4b495b361b921bff6781
git push origin v0.4.1

Please sign in to comment.