Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Opening km3net_online.root causes huge memory usage spike #268

Open
Moelf opened this issue Aug 2, 2023 · 2 comments
Open

Opening km3net_online.root causes huge memory usage spike #268

Moelf opened this issue Aug 2, 2023 · 2 comments

Comments

@Moelf
Copy link
Member

Moelf commented Aug 2, 2023

julia> using UnROOT

julia> SAMPLES_DIR="./test/samples/"

julia> function f()
           files = filter(x->endswith(x, ".root"), readdir(SAMPLES_DIR))
           _io = IOBuffer()
           for f in files
               @show f
               r = ROOTFile(joinpath(SAMPLES_DIR, f))
               show(_io, r)
               close(r)
               sleep(1)
           end
       end
f (generic function with 1 method)

julia> f()
f = "Jagged_TLorentzVector.root"
f = "NanoAODv5_sample.root"
f = "TH2_5.root"
f = "TLorentzVector.root"
f = "TNtuple.root"
f = "TNtupleD.root"
f = "TVectorT-double_on_top_level.root"
f = "cms_ntuple_wjet.root"
f = "edm4hep_266.root"
f = "histograms.root"
f = "histograms1d2d.root"
f = "issue108_small.root"
f = "issue116.root"
f = "issue11_tdirectory.root"
f = "issue165.root"
f = "issue165_multiple_baskets.root"
f = "issue246.root"
f = "issue61.root"
f = "issue7.root"
f = "issue87_uncompressed_a.root"
f = "issue87_uncompressed_b.root"
f = "km3net_offline.root"
f = "km3net_online.root"

and watch memory usage, there's a 5-7 GB jump in memory usage when opening up km3net_online, and is causing CI crash on nightly, can you look into this? @tamasgal , for now I'm gonna disable testing the "Display" of this file, since we have plenty other files.

@tamasgal
Copy link
Member

tamasgal commented Aug 8, 2023

Oh, this is very weird. km3net_online.root is pretty small, what the heck? I work with such ROOT files on a daily basis.

Looking into this.

@tamasgal
Copy link
Member

tamasgal commented Aug 8, 2023

I tried your code snippet but I only see an increase from about 400MB to 1100MB when opening the KM3NeT files but it drops down to 400MB again after a few iterations. I guess it's some compilation/GC stuff?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants