rebdsimCombine - Nan values appears if at least one input histogram have no data

Issue #366 resolved
Marin DENIAUD created an issue

Dear all,

I’m trying to combine rebdsim files with custom histograms and some of them don’t have any data. I would expect those histogram to just not contribute to the final one (or if they are all empty, to produce an empty histogram) but if only one is empty the combined histogram is just full of nans.

Attached is 2 input files (one empty, the other with one point of data), the rebdsimCombine file from those two and the script that I used to generate the files.

With best regards
Marin DENIAUD

Comments (2)

  1. Laurie Nevay

    Fixed. Normally, this wouldn’t happen as we wouldn’t have 0 entry histograms. The histograms you supplied in one file have 0 entries - i.e. they have never been filled. In the PerEntryHistograms, and MergedHistograms we expect histograms with at least 1 entry as to make them we would normally analysed at least 1 event. The contents could be 0 but the number of entries (used as the number of events) would be greater than 0. For SimpleHistograms, they are just added trivially.

    I have changed the code so that it will warn about 0 entry histograms and also skip them in the accumulation. This has been done in the v1.7.0-rc branch.

  2. Log in to comment