I do not understand why the following MWE consumes more an more memory until crash:
using GLMakie,AbstractPlotting,ImageCore
function leak(img,i)
fn=string(i)*".png"
scene = AbstractPlotting.image(rotr90(img), show_axis = false);
AbstractPlotting.save(fn, scene; resolution = (1920,1088), px_per_unit = 72)
nothing
end
function nleak(nf)
nx,ny=1920,1088
for i=1:nf
img = rand(RGB{N0f8}, nx, ny)
leak(img,i)
@info "Size of AbstractPlotting: $(Base.format_bytes(Base.summarysize(AbstractPlotting)))"
GC.gc(true)
end
end
nleak(200)
I don’t know. The calling nleak function does not create any Makie related object. Hence I would assume that every Makie objects should be destroyed (or ready for GC) at the leak function exit…
Could you please file an issue at Makie.jl with this MWE then? So far these things have been caused by lingering observable connections, and they tend to be hard to catch
OK thank you for your answer… and good luck with the investigation !
I was not sure since the memory leak issues I have found on github were closed.
Should I post a new issue ?