Skip to content

Commit

Permalink
updated cumulant code
Browse files Browse the repository at this point in the history
  • Loading branch information
joott committed Aug 31, 2022
1 parent 3265f87 commit 6a53771
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions modelB_cumulants.jl
Original file line number Diff line number Diff line change
Expand Up @@ -126,9 +126,11 @@ function gpu_sweep_k(m², ϕ, L, m)
return
end

skip = 100

function thermalize(ϕ, t, threads, blocks, N=10000)
for i in 0:N-1
sweep(((i+10*t) * Δt), ϕ, threads, blocks)
sweep(((i+skip*t) * Δt), ϕ, threads, blocks)
end
end

Expand Down Expand Up @@ -160,19 +162,19 @@ threads = min(N, config.threads)
blocks = cld(N, threads)

maxt = trunc(Int, t_e / Δt)+1
skip = 10
batch = parse(Int, ARGS[4])

for series in 1:16
df = load("/share/tmschaef/jkott/modelB/KZ/IC_sym_L_$L"*"_id_"*ARGS[1]*"_series_$series.jld2")

for run in 1:16
for run in (16batch-63):16batch
ϕ .= CuArray(df["ϕ"])

thermalize_static((0), ϕ, threads, blocks, L^3)
thermalize_static((0), ϕ, threads, blocks, 1.5 * 10^4)

open("/share/tmschaef/jkott/modelB/KZ/cumulants/sum_L_$L"*"_id_"*ARGS[1]*"_series_$series"*"_run_$run.dat","w") do io
for i in 0:div(maxt,skip)+1
Printf.@printf(io, "%i %f %f\n", i*skip, (10*i * Δt), M(ϕ))
open("/share/tmschaef/jkott/modelB/KZ/cumulants/trim/sum_L_$L"*"_id_"*ARGS[1]*"_series_$series"*"_run_$run.dat","w") do io
for i in 0:div(maxt,skip)
Printf.@printf(io, "%i %f %f\n", i*skip, (skip*i * Δt), M(ϕ))
thermalize(ϕ, i, threads, blocks, skip)
end
end
Expand Down

0 comments on commit 6a53771

Please sign in to comment.