I was doing SimpleUpdate benchmark tests using the current master branch of PEPSKit using the following script:
using Random
using TensorKit
using PEPSKit
using BenchmarkTools
Nr, Nc = 2, 2
ham = j1_j2_model(
ComplexF64, Trivial, InfiniteSquare(Nr, Nc);
J1 = 1.0, J2 = 0.0, sublattice = false
)
D = 8
Vvir = ℂ^D
state = InfinitePEPS(randn, ComplexF64, ℂ^2, Vvir; unitcell = (2, 2))
wts = SUWeight(state)
alg = SimpleUpdate(; trunc = truncrank(D))
evolver = TimeEvolver(state, ham, 0.1, 10, alg, wts)
circuit = evolver.gate
function test_suiter()
return PEPSKit.su_iter(state, circuit, alg, wts)
end
@btime test_suiter()
Using TensorKit v0.16.4, the output is
13.033 ms (43992 allocations: 50.63 MiB)
If I downgrade to v0.16.3, I get
12.372 ms (25368 allocations: 49.86 MiB)
The number of allocations is almost 50% smaller with v0.16.3, though the speed change is not that dramatic. I haven't been able to produce a more minimal example. Is this something to worry about?
Environment details below:
Details
I'm using Julia 1.12.5, with:
[6e4b80f9] BenchmarkTools v1.8.0
[bb1c41ca] MPSKit v0.13.10
[ca635005] MPSKitModels v0.4.6
[52969e89] PEPSKit v0.7.0 `../PEPSKit.jl`
[07d1fe3e] TensorKit v0.16.4
[41b62e7d] TensorKitTensors v0.2.4
[37e2e46d] LinearAlgebra v1.12.0
[de0858da] Printf v1.11.0
[9a3f8284] Random v1.11.0
[8dfed614] Test v1.11.0
[6e4b80f9] BenchmarkTools v1.8.0
[bb1c41ca] MPSKit v0.13.10
[ca635005] MPSKitModels v0.4.6
[52969e89] PEPSKit v0.7.0 `../PEPSKit.jl`
⌅ [07d1fe3e] TensorKit v0.16.3
[41b62e7d] TensorKitTensors v0.2.4
[37e2e46d] LinearAlgebra v1.12.0
[de0858da] Printf v1.11.0
[9a3f8284] Random v1.11.0
[8dfed614] Test v1.11.0
I was doing SimpleUpdate benchmark tests using the current master branch of PEPSKit using the following script:
Using TensorKit v0.16.4, the output is
If I downgrade to v0.16.3, I get
The number of allocations is almost 50% smaller with v0.16.3, though the speed change is not that dramatic. I haven't been able to produce a more minimal example. Is this something to worry about?
Environment details below:
Details
I'm using Julia 1.12.5, with: