I am wondering if there are any tricks for speeding up (and possibly reducing the memory usage of) constructing a quantum-number conserving MPO from a Hamiltonian with millions of terms.
I’m trying to run construct the trancorrelated momentum space Fermi-Hubbard Hamiltonian as a MPO as done in Transcorrelated density matrix renormalization group, with the Hamiltonian shown in equation 8. My end goal is to run DMRG with the MPO, and so I when I construct the MPO I set conserve_qns=true
so that the number of electrons and the total spin of my input DMRG state is preserved.
The form of the Hamiltonian isn’t particularly important, but for a 4x4 grid, there are almost 2 million terms in the Hamiltonian and the vast majority are three electron terms (so three creation and three annihilation operators). I have been trying in vain to construct the MPO using OpSum
. The call to MPO(os, sites; maxdim=100)
takes longer than I have been able to run so far. I’ve tried running on my laptop for two days to no avail. I’ve tried running on a cluster with 128 GB of RAM only to run out of memory after eight hours. Note that I’ve requested a maximum bond dimension of 100 so the resulting MPO should be quite small.
I have tried out the DMRG interface that takes a list of MPOs, but on a 3x3 grid this seems to be much slower. Both slower to construct the many MPOs than a single MPO with OpSum
and slower to run DMRG. From some simple extrapolation I estimate that it would take half a day running on the cluster just to produce the list of MPOs for the 4x4 grid.
I am using MKL on the cluster and have tried playing around with ITensors.enable_threaded_blocksparse
. Not that I can tell if either of them is an improvement because there’s no way for me to know how much progress was made before the program exits.
I’m willing to accept that this calculation is just too big (I’d actually like to repeat it many times, so a day of run time on a cluster is pushing it), but thought I’d ask around here before throwing in the towel. Much appreciated!
julia> versioninfo()
Julia Version 1.9.0
Commit 8e630552924 (2023-05-07 11:25 UTC)
Platform Info:
OS: macOS (x86_64-apple-darwin22.4.0)
CPU: 16 × Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
WORD_SIZE: 64
LIBM: libopenlibm
LLVM: libLLVM-14.0.6 (ORCJIT, skylake)
Threads: 1 on 16 virtual cores
julia> using Pkg; Pkg.status("ITensors")
Status `~/.julia/environments/v1.9/Project.toml`
[9136182c] ITensors v0.3.34