Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Solve piracies and ambiguities #28

Merged
merged 9 commits into from
Aug 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions .github/workflows/ci-julia-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
include:
- os: ubuntu-latest
arch: x64
version: nightly
version: alpha
threads: 2
jet: 'false'
- os: ubuntu-latest
Expand All @@ -26,10 +26,9 @@ jobs:
jet: 'true'
steps:
- uses: actions/checkout@v4
- uses: julia-actions/setup-julia@v2
- uses: julia-actions/install-juliaup@v2
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
channel: ${{ matrix.version }}~${{ matrix.arch }}
- uses: julia-actions/cache@v2
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
Expand Down
5 changes: 4 additions & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
name = "QuantumInterface"
uuid = "5717a53b-5d69-4fa3-b976-0bf2f97ca1e5"
authors = ["QuantumInterface.jl contributors"]
version = "0.3.4"
version = "0.3.5"

[deps]
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"

[compat]
LinearAlgebra = "1"
SparseArrays = "1"
Test = "1"
julia = "1.6"

[extras]
Expand Down
2 changes: 2 additions & 0 deletions src/abstract_types.jl
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,5 @@ function summary(stream::IO, x::AbstractOperator)
end

show(stream::IO, x::AbstractOperator) = summary(stream, x)

traceout!(s::StateVector, i) = ptrace(s,i)
3 changes: 2 additions & 1 deletion src/embed_permute.jl
Original file line number Diff line number Diff line change
Expand Up @@ -88,4 +88,5 @@ permutesystems(a::AbstractOperator, perm) = arithmetic_unary_error("Permutations
nsubsystems(s::AbstractKet) = nsubsystems(basis(s))
nsubsystems(s::AbstractOperator) = nsubsystems(basis(s))
nsubsystems(b::CompositeBasis) = length(b.bases)
nsubsystems(b::Basis) = 1
nsubsystems(b::Basis) = 1
nsubsystems(::Nothing) = 1 # TODO Exists because of QuantumSavory; Consider removing this and reworking the functions that depend on it. E.g., a reason to have it when performing a project_traceout measurement on a state that contains only one subsystem
5 changes: 3 additions & 2 deletions test/test_jet.jl
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ end
)
)
@show rep
@test length(JET.get_reports(rep)) <= 8
@test length(JET.get_reports(rep)) <= 11
@test_broken length(JET.get_reports(rep)) == 0

rep = report_package("QuantumInterface";
Expand All @@ -49,5 +49,6 @@ end
)
)
@show rep
@test length(JET.get_reports(rep)) == 0
@test length(JET.get_reports(rep)) <= 2
@test_broken length(JET.get_reports(rep)) == 0
end
Loading