Remove explicit call to InfiniteMPS in VUMPS#396
Remove explicit call to InfiniteMPS in VUMPS#396AFeuerpfeil wants to merge 11 commits intoQuantumKitHub:mainfrom
InfiniteMPS in VUMPS#396Conversation
lkdvos
left a comment
There was a problem hiding this comment.
While I left a small comment on the implementation here, I think I would be happier with a more fundamental change where instead of the uniform gauge happening in the InfiniteMPS constructor, we actually use the dedicated function:
Something along the lines of:
gaugefix!(similar(it.state.mps), copy(it.state.AR), ...; kwargs...)
src/algorithms/groundstate/idmrg.jl
Outdated
|
|
||
| alg_gauge = updatetol(alg.alg_gauge, it.state.iter, it.state.ϵ) | ||
| ψ′ = InfiniteMPS(it.state.mps.AR[1:end]; alg_gauge.tol, alg_gauge.maxiter) | ||
| ψ′ = typeof(mps)(it.state.mps.AR; alg_gauge.tol, alg_gauge.maxiter) |
There was a problem hiding this comment.
| ψ′ = typeof(mps)(it.state.mps.AR; alg_gauge.tol, alg_gauge.maxiter) | |
| ψ′ = typeof(mps)(copy(it.state.mps.AR); alg_gauge.tol, alg_gauge.maxiter) |
Otherwise this will share the array with the input, which is probably not what we want here.
This being said, I think if you overload similar for your array type it keeps its type.
|
Thanks for the recommendation! |
|
Your PR no longer requires formatting changes. Thank you for your contribution! |
|
Looks like the |
Head branch was pushed to by a user without write access
|
Just looked at this a bit more - the IDMRG2 failures are most likely because the spaces of the MPS are changing, so my proposed solution in terms of an in-place function doesn't work that straightforwardly, since |
InfiniteMPS in VUMPS and IDMRGInfiniteMPS in VUMPS
|
@lkdvos: I don't see a good solution right now for IDMRG. For the sake of pushing this through to do some tests with |
|
(OK for me, though it seems like you haven't pushed that 😉 ) |
|
I did push the IDMRG change, just messed up the commit message text with another commit. Therefore, it is called "format". |
I remove the explicit call to
InfiniteMPSinVUMPSand instead usegaugefix!in thegauge_stetp!.