Skip to content

Commit

Permalink
use vectors for nest storage
Browse files Browse the repository at this point in the history
  • Loading branch information
lxvm committed Oct 31, 2023
1 parent b9fb195 commit f018349
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/apps.jl
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ function make_fourier_nest_(f, fx, w, x1, x...)
f1s = ntuple(n -> deepcopy(f), Val(len))
y1s = typeof(fx)[]
x1s = eltype(x1)[]
return NestedBatchIntegrand(f1s, y1s, x1s, max_batch=10^6)
return NestedBatchIntegrand(collect(f1s), y1s, x1s, max_batch=10^6)
end
else
nests = ntuple(n -> make_fourier_nest_(f, fx, w.cache[n], x1, x[begin:end-1]...), Val(len))
Expand All @@ -104,7 +104,7 @@ function make_fourier_nest_(f, fx, w, x1, x...)
else
ys = typeof(fx*x1*prod(x[begin:end-1]))[]
xs = eltype(x[end])[]
return NestedBatchIntegrand(nests, ys, xs, max_batch=10^6)
return NestedBatchIntegrand(collect(nests), ys, xs, max_batch=10^6)
end
end
end
Expand Down

0 comments on commit f018349

Please sign in to comment.