Skip to content
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
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name = "ITensorNetworksNext"
uuid = "302f2e75-49f0-4526-aef7-d8ba550cb06c"
version = "0.9.8"
version = "0.9.9"
authors = ["ITensor developers <support@itensor.org> and contributors"]

[workspace]
Expand Down Expand Up @@ -36,7 +36,7 @@ Combinatorics = "1"
DataGraphs = "0.5"
Dictionaries = "0.4.5"
Graphs = "1.13.1"
ITensorBase = "0.10, 0.11, 0.12"
ITensorBase = "0.13"
LinearAlgebra = "1.10"
MacroTools = "0.5.16"
MatrixAlgebraKit = "0.6"
Expand Down
10 changes: 6 additions & 4 deletions src/ITensorNetworkGenerators/ising_network.jl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using ..ITensorNetworksNext
using Graphs: degree, dst, edges, src
using ITensorBase: apply, name, operator, uniquename
using ITensorBase: name, nameddims, uniquename
using LinearAlgebra: Diagonal, eigen
using NamedGraphs.GraphsExtensions: vertextype

Expand Down Expand Up @@ -43,9 +43,11 @@ function ising_network(

deg2 = degree(tn, v2)
m = sqrt_ising_bond(β; J, h, deg1, deg2)
t = operator(m, (name(fp(e)),), (name(f(e)),))
tn[v1] = apply(t, tn[v1])
tn[v2] = apply(t, tn[v2])
# Split the Ising bond as √b on each endpoint, contracting the delta-network bond
# name `fp(e)` and renaming the shared bond to the requested name `f(e)`.
b = nameddims(m, (name(fp(e)), name(f(e))))
tn[v1] = b * tn[v1]
tn[v2] = b * tn[v2]
end
return tn
end
4 changes: 2 additions & 2 deletions src/apply/apply_operators.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ using AlgorithmsInterface: AlgorithmsInterface as AI
using Base: @kwdef
using Graphs: dst, src, vertices
using ITensorBase:
ITensorBase as ITB, AbstractITensor, dimnames, domainnames, operator, replacedimnames
ITensorBase as ITB, AbstractITensor, dimnames, inputnames, operator, replacedimnames
using LinearAlgebra: norm
using MatrixAlgebraKit: qr_compact, svd_trunc
using NamedGraphs.GraphsExtensions: all_edges, boundary_edges
Expand Down Expand Up @@ -209,7 +209,7 @@ function apply_gate_bp!(
dest::AbstractITensorNetwork, op::AbstractITensor,
state::AbstractITensorNetwork, env; kwargs...
)
op_in = domainnames(op)
op_in = inputnames(op)
vs = [v for v in vertices(state) if !isempty(intersect(op_in, sitenames(state, v)))]
isempty(vs) && throw(
ArgumentError("operator shares no indices with the tensor network")
Expand Down
2 changes: 1 addition & 1 deletion test/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ DataGraphs = "0.5"
Dictionaries = "0.4.5"
GradedArrays = "0.13.2"
Graphs = "1.13.1"
ITensorBase = "0.10, 0.11, 0.12"
ITensorBase = "0.13"
ITensorNetworksNext = "0.9"
ITensorPkgSkeleton = "0.3.42"
MatrixAlgebraKit = "0.6"
Expand Down