Skip to content

Commit

Permalink
fix properly
Browse files Browse the repository at this point in the history
  • Loading branch information
Jutho committed Dec 13, 2024
1 parent f6f5ee8 commit 6a0a3bc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/tensors/truncation.jl
Original file line number Diff line number Diff line change
Expand Up @@ -128,12 +128,12 @@ function _findnexttruncvalue(Σdata, truncdim::SectorDict{I,Int}, p::Real) where

# find some suitable starting candidate
cmin = findfirst(>(0), truncdim)
σmin = dim(cmin)^inv(p) * Σdata[cmin][truncdim[cmin]]
σmin = Σdata[cmin][truncdim[cmin]]

# find the actual minimum singular value
for (c, σs) in Σdata
if truncdim[c] > 0
σ = dim(c)^inv(p) * σs[truncdim[c]]
σ = σs[truncdim[c]]
if σ < σmin
cmin, σmin = c, σ
end
Expand Down

0 comments on commit 6a0a3bc

Please sign in to comment.