Skip to content
This repository has been archived by the owner on Jul 7, 2024. It is now read-only.

Commit

Permalink
Fix arguments in inds call
Browse files Browse the repository at this point in the history
  • Loading branch information
jofrevalles committed Jun 17, 2024
1 parent e1e8eb6 commit 2721de5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Ansatz/Chain.jl
Original file line number Diff line number Diff line change
Expand Up @@ -542,7 +542,7 @@ function evolve_2site!(qtn::Chain, gate::Dense; threshold, maxdim, iscanonical =
left_inds::Vector{Symbol} = !isnothing(leftindex(qtn, sitel)) ? [leftindex(qtn, sitel)] : Symbol[]
right_inds::Vector{Symbol} = !isnothing(rightindex(qtn, siter)) ? [rightindex(qtn, siter)] : Symbol[]

virtualind::Symbol = inds(qtn, :bond, bond...)
virtualind::Symbol = inds(qtn, bond = bond)

iscanonical ? contract_2sitewf!(qtn, bond) : contract!(TensorNetwork(qtn), virtualind)

Expand Down Expand Up @@ -610,7 +610,7 @@ function contract_2sitewf!(ψ::Chain, bond)
!isnothing(Λᵢ₋₁) && contract!(ψ, :between, Site(id(sitel) - 1), sitel; direction = :right, delete_Λ = false)
!isnothing(Λᵢ₊₁) && contract!(ψ, :between, siter, Site(id(siter) + 1); direction = :left, delete_Λ = false)

contract!(TensorNetwork(ψ), inds(ψ, :bond, bond...))
contract!(TensorNetwork(ψ), inds(ψ, bond = bond))

return ψ
end
Expand Down

0 comments on commit 2721de5

Please sign in to comment.