Skip to content

Commit

Permalink
Fix small typos
Browse files Browse the repository at this point in the history
  • Loading branch information
jofrevalles committed Nov 18, 2024
1 parent e365623 commit a510320
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
5 changes: 3 additions & 2 deletions ext/TenetITensorMPSExt.jl
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
module TenetITensorMPSExt

using Tenet
using ITensors: ITensor, Index, dim
using ITensors
using ITensorMPS
using ITensors: ITensor, Index, dim
using Tenet: MPS, tensors, form, inds

# Convert an AbstractMPS to an ITensor MPS
Expand Down Expand Up @@ -89,7 +90,7 @@ function Base.convert(::Type{MPS}, itensors_mps::ITensorMPS.MPS)

# Map llim and rlim to your MPS's orthogonality center(s)
mps_form = if llim + 1 == rlim - 1
Tenet.MixedCanonical(Tenet.Site(; n=llim + 1))
Tenet.MixedCanonical(Tenet.Site(llim + 1))
elseif llim + 1 < rlim - 1
Tenet.MixedCanonical([Tenet.Site(j) for j in (llim + 1):(rlim - 1)])

Check warning on line 95 in ext/TenetITensorMPSExt.jl

View check run for this annotation

Codecov / codecov/patch

ext/TenetITensorMPSExt.jl#L92-L95

Added lines #L92 - L95 were not covered by tests
else
Expand Down
3 changes: 2 additions & 1 deletion test/integration/ITensorMPS_test.jl
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
@testset "ITensorMPS" begin
using ITensorMPS
using ITensors
using ITensors: ITensor, Index, dim, dims
using Tenet: MPS, tensors, form
using Tenet: MPS, tensors, form, inds

# Tenet to ITensorMPS conversion
tenet_mps = rand(MPS; n=5, maxdim=30)
Expand Down

0 comments on commit a510320

Please sign in to comment.