Skip to content

Fix memory leak in CalibrationDataEigenVariations::removeVariations

Karol Krizka requested to merge kkrizka/athena:btagsfmemleak into 21.2

CalibrationDataEigenVariations::removeVariations removes entries in the m_eigen member variable. However when it removes an entry, it does not delete the corresponding histogram from memory. This leads to a relatively large increase in memory that doubles everytime the BTaggingSelectionTool tool is initialized (ie: when switching to a new sample in EventLoop). This MR makes sure that everything is cleaned up properly.

To see the effect of this, look at the following chart where I track the memory usage of my ntupler: https://imgur.com/I1cjPj6

I am not sure who to tag from FTAG to approve this. I'm told @dguest and @jshlomi might be the right people.

Merge request reports

Loading