[Rivet] aidamerge

Hendrik Hoeth hendrik.hoeth at cern.ch
Mon Aug 22 16:15:48 BST 2011


Hi Hannes,

Thus spake Hannes Jung (hannes.jung at cern.ch):

> I divide 2 histograms in the code, and there could be of course a zero
> in the denominator.
> 
> But the histo package should take care of this... or do you really
> mean I should check every bin to make sure that there is an entry
> before calling the histo divide option via:
> histogramFactory().divide(histoPath("jetptl_ratio"),
> *_hist_jetptl_central_ratio, *_hist_jetptl_central_only_ratio);

I'd be surprised if this causes the nans, since we already catch
division by zero in that function. So I agree, you shouldn't get an inf
or nan, but without knowledge about your code nobody can solve the
problem for you.

Some suggestions for you debugging session:

- Check that _hist_jetptl_central_ratio and
  _hist_jetptl_central_only_ratio have sensible content.
  Maybe the nans are already in there?

- The divide() function you're calling is in
  include/LWH/HistogramFactory.h, so that's a place to
  start looking.

If you find anything that looks wrong, please let us know.

Cheers,

    Hendrik

-- 
A man without a dream in his heart already has one foot in the grave.


More information about the Rivet mailing list