Open marcio053 opened 1 month ago
Thanks. Could you please post a minimal example that reproduces the bug? The example above includes some functions like Set_Hamiltonian
and things which I don't have so I'm not able to run it.
Also, it may or may not be unrelated to the bug, but it could help to make your code in a more up-to-date style, following the code example here:
https://itensor.github.io/ITensors.jl/dev/examples/DMRG.html#Compute-excited-states-with-DMRG
Specifically note how it's preferred to no longer use the Sweeps
type and instead just pass parameters like nsweeps
, maxdim
, etc as keyword arguments.
Also, the preferred style is using MPS
instead of productMPS
and random_mps
instead of randomMPS
, though that's unrelated to your issue.
Below I'm leaving a snippet of my code that gives an error when placing the "weight" argument in the DMRG. This code works in previous versions of Itensors, but in recent versions it does not work
Closest candidates are: dmrg(::Any, ::MPS, ::Sweeps; which_decomp, svd_alg, observer, outputlevel, write_when_maxdim_exceeds, write_path, eigsolve_tol, eigsolve_krylovdim, eigsolve_maxiter, eigsolve_verbosity, eigsolve_which_eigenvalue, ishermitian) got unsupported keyword argument "weight" @ ITensors ~/.julia/packages/ITensors/oOwvi/src/lib/ITensorMPS/src/dmrg.jl:158 dmrg(!Matched::MPO, ::MPS, ::Sweeps; kwargs...) @ ITensors ~/.julia/packages/ITensors/oOwvi/src/lib/ITensorMPS/src/dmrg.jl:21 dmrg(!Matched::Vector{MPO}, ::MPS, ::Sweeps; kwargs...) @ ITensors ~/.julia/packages/ITensors/oOwvi/src/lib/ITensorMPS/src/dmrg.jl:31