You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried to run the code from https://itensor.github.io/ITensors.jl/dev/tutorials/QN_DMRG.html on a GPU using ITensorGPU.jl and encountered an error where the dimensions of the dims of the tensors in the Hamiltonian did not coincide with the arrays inside the Hamiltonian itself.
(Click me) Minimal runnable code
julia>using ITensors, ITensorGPU
julia>let
N =100
sites =siteinds("S=1",N;conserve_qns=true)
ampo =OpSum()
for j=1:N-1
ampo +="Sz",j,"Sz",j+1
ampo +=1/2,"S+",j,"S-",j+1
ampo +=1/2,"S-",j,"S+",j+1end
H =MPO(ampo,sites)
state = [isodd(n) ?"Up":"Dn"for n=1:N]
psi0 =productMPS(sites,state)
sweeps =Sweeps(5)
setmaxdim!(sweeps, 10,20,100,100,200)
setcutoff!(sweeps, 1E-10)
energy, psi =dmrg(cu(H),cu(psi0), sweeps) # Note the use of cu herereturn energy
end
Expected output or behavior
I expected this to produce the same answer as the CPU version
julia>versioninfo()
Julia Version 1.7.0-rc2
Commit f23fc0d27a (2021-10-2012:45 UTC)
Platform Info:
OS: Linux (x86_64-linux-gnu)
CPU: AMD Ryzen Threadripper 2990WX 32-Core Processor
WORD_SIZE:64
LIBM: libopenlibm
LLVM: libLLVM-12.0.1 (ORCJIT, znver1)
Environment:
JULIA_NUM_THREADS =26
Output from using Pkg; Pkg.status("ITensors"):
(@v1.7) pkg> st ITensors
Status `~/.julia/environments/v1.7/Project.toml`
[9136182c] ITensors v0.3.10`~/.julia/dev/ITensors`
(@v1.7) pkg> st ITensorGPU
Status `~/.julia/environments/v1.7/Project.toml`
[d89171c1] ITensorGPU v0.0.5`~/.julia/dev/ITensors/ITensorGPU`
(@v1.7) pkg> st NDTensors
Status `~/.julia/environments/v1.7/Project.toml`
[23ae76d9] NDTensors v0.1.37`~/.julia/dev/ITensors/NDTensors`
The text was updated successfully, but these errors were encountered:
This should be working now, though we are still testing out the performance. I'll close in favor of more specific issues. Also future issues will go in the issue tracker in the https://github.com/ITensor/ITensors.jl repository, most of the GPU implementation is in package extensions of the NDTensors.jl subdirectory package of that repository, this is now just a shell package for backwards compatibility.
Description of bug
I tried to run the code from https://itensor.github.io/ITensors.jl/dev/tutorials/QN_DMRG.html on a GPU using ITensorGPU.jl and encountered an error where the dimensions of the dims of the tensors in the Hamiltonian did not coincide with the arrays inside the Hamiltonian itself.
(Click me) Minimal runnable code
Expected output or behavior
I expected this to produce the same answer as the CPU version
Actual output or behavior
It errored.
Output of minimal runnable code
Version information
versioninfo()
:using Pkg; Pkg.status("ITensors")
:The text was updated successfully, but these errors were encountered: