Skip to content

Commit

Permalink
Added custom edge specification on vidal_gauge
Browse files Browse the repository at this point in the history
  • Loading branch information
JoeyT1994 committed Oct 23, 2023
1 parent 1cf1daf commit ffa9d5c
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/gauging.jl
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,12 @@ function vidal_gauge(
bond_tensors::DataGraph;
eigen_message_tensor_cutoff=10 * eps(real(scalartype(ψ))),
regularization=10 * eps(real(scalartype(ψ))),
edges = NamedGraphs.edges(ψ),

Check warning on line 20 in src/gauging.jl

View workflow job for this annotation

GitHub Actions / format

[JuliaFormatter] reported by reviewdog 🐶 Raw Output: src/gauging.jl:20:- edges = NamedGraphs.edges(ψ), src/gauging.jl:20:+ edges=NamedGraphs.edges(ψ),
svd_kwargs...,
)
ψ_vidal = copy(ψ)

for e in edges(ψ_vidal)
for e in edges
vsrc, vdst = src(e), dst(e)
ψvsrc, ψvdst = ψ_vidal[vsrc], ψ_vidal[vdst]

Expand Down Expand Up @@ -173,7 +174,7 @@ function symmetric_to_vidal_gauge(
end

"""Function to measure the 'isometries' of a state in the Vidal Gauge"""
function vidal_itn_isometries::ITensorNetwork, bond_tensors::DataGraph; edges = vcat(edges(ψ), reverse.(edges(ψ))))
function vidal_itn_isometries::ITensorNetwork, bond_tensors::DataGraph; edges = vcat(NamedGraphs.edges(ψ), reverse.(NamedGraphs.edges(ψ))))

Check warning on line 177 in src/gauging.jl

View workflow job for this annotation

GitHub Actions / format

[JuliaFormatter] reported by reviewdog 🐶 Raw Output: src/gauging.jl:177:-function vidal_itn_isometries(ψ::ITensorNetwork, bond_tensors::DataGraph; edges = vcat(NamedGraphs.edges(ψ), reverse.(NamedGraphs.edges(ψ)))) src/gauging.jl:177:+function vidal_itn_isometries( src/gauging.jl:178:+ ψ::ITensorNetwork, src/gauging.jl:179:+ bond_tensors::DataGraph; src/gauging.jl:180:+ edges=vcat(NamedGraphs.edges(ψ), reverse.(NamedGraphs.edges(ψ))), src/gauging.jl:181:+)
isometries = DataGraph{vertextype(ψ),ITensor,ITensor}(directed_graph(underlying_graph(ψ)))

for e in edges
Expand Down

0 comments on commit ffa9d5c

Please sign in to comment.