Dear all,
I have been struggling to make the following example work in ROOT 6.26/10:
t = RooRealVar("t", "t", -10., 30.)
tau = RooRealVar("tau", "tau", 1.54, 0.1, 5.)
dataSetFile = TFile.Open(dataset)
tree = dataSetFile.Get('DecayTree')
histo = TH1D("histo", "histo", 1000, -10., 30.)
for i in range(0, tree.GetEntries()):
tree.GetEntry(i)
histo.Fill(tree.timeres)
datahist = RooDataHist("data", "data", RooArgList(t), RooFit.Import(histo))
acceptance = RooFormulaVar("spline", "spline", "0.3+0.02*t", RooArgList(t))
resol = RooHistPdf("res", "res", t, datahist)
true = RooTruthModel("true", "true", t)
model = RooDecay("model", "model", t, tau, true, RooDecay.SingleSided)
modelconv = RooFFTConvPdf("modelConv", "modelConv", t, model, resol)
modelEff = RooEffProd("modelEff", "modelEff", modelconv, acceptance)
data = modelEff.generate(RooArgSet(t), 10000)
modelEff.fitTo(data)
In ROOT 6.26/10 I get:
[#0] ERROR:Eval -- RooAbsReal::logEvalError(res_fft) evaluation error,
origin : RooHistPdf::res_fft[ pdfObs=(t_shifted_FFTBuffer2) ]
message : p.d.f normalization integral is zero or negative: 0.000000
server values: pdfObs=(t_shifted_FFTBuffer2 = -9.05376)
The last ROOT version in which this example works is 6.24/06. I attach both logs in both ROOT versions, the test example and the test input for you.
Thank you in advance!
log_62406.txt (4.9 KB)
log for 6.26/10
The inputs and full example:
test.root (643.3 KB)
test_numtr2.py (1.6 KB)