80   , fGDPathStep ( 0.01 )
 
   81   , fGDNPathSteps ( 1000 )
 
 
  106   if (fNTCoeff)     { 
delete [] fNTCoeff; fNTCoeff = 
nullptr; }
 
  107   if (fNTLinCoeff)  { 
delete [] fNTLinCoeff; fNTLinCoeff = 
nullptr; }
 
 
  116   if (fRuleFit==0) 
return;
 
  117   if (fRuleFit->GetMethodRuleFit()==0) {
 
  118      Log() << kFATAL << 
"RuleFitParams::Init() - MethodRuleFit ptr is null" << 
Endl;
 
  120   UInt_t neve = fRuleFit->GetTrainingEvents().size();
 
  122   fRuleEnsemble   = fRuleFit->GetRuleEnsemblePtr();
 
  123   fNRules         = fRuleEnsemble->GetNRules();
 
  124   fNLinear        = fRuleEnsemble->GetNLinear();
 
  133      fPerfIdx2 = 
static_cast<UInt_t>((
neve-1)*fRuleFit->GetMethodRuleFit()->GetGDValidEveFrac());
 
  148      fPathIdx2 = 
static_cast<UInt_t>((
neve-1)*fRuleFit->GetMethodRuleFit()->GetGDPathEveFrac());
 
  158      fNEveEffPath += fRuleFit->GetTrainingEventWeight(
ie);
 
  163      fNEveEffPerf += fRuleFit->GetTrainingEventWeight(
ie);
 
  166   Log() << kVERBOSE << 
"Path constr. - event index range = [ " << fPathIdx1 << 
", " << fPathIdx2 << 
" ]" 
  167         << 
", effective N(events) = " << fNEveEffPath << 
Endl;
 
  168   Log() << kVERBOSE << 
"Error estim. - event index range = [ " << fPerfIdx1 << 
", " << fPerfIdx2 << 
" ]" 
  169         << 
", effective N(events) = " << fNEveEffPerf << 
Endl;
 
  171   if (fRuleEnsemble->DoRules())
 
  172      Log() << kDEBUG << 
"Number of rules in ensemble: " << fNRules << 
Endl;
 
  174      Log() << kDEBUG << 
"Rules are disabled " << 
Endl;
 
  176   if (fRuleEnsemble->DoLinear())
 
  177      Log() << kDEBUG << 
"Number of linear terms: " << fNLinear << 
Endl;
 
  179      Log() << kDEBUG << 
"Linear terms are disabled " << 
Endl;
 
 
  187   fGDNtuple= 
new TTree(
"MonitorNtuple_RuleFitParams",
"RuleFit path search");
 
  188   fGDNtuple->Branch(
"risk",    &fNTRisk,     
"risk/D");
 
  189   fGDNtuple->Branch(
"error",   &fNTErrorRate,
"error/D");
 
  190   fGDNtuple->Branch(
"nuval",   &fNTNuval,    
"nuval/D");
 
  191   fGDNtuple->Branch(
"coefrad", &fNTCoefRad,  
"coefrad/D");
 
  192   fGDNtuple->Branch(
"offset",  &fNTOffset,   
"offset/D");
 
  194   fNTCoeff    = (fNRules >0 ? 
new Double_t[fNRules]  : 0);
 
  195   fNTLinCoeff = (fNLinear>0 ? 
new Double_t[fNLinear] : 0);
 
  197   for (
UInt_t i=0; i<fNRules; i++) {
 
  200   for (
UInt_t i=0; i<fNLinear; i++) {
 
 
  209                                           std::vector<Double_t> &
avsel,
 
  210                                           std::vector<Double_t> &
avrul )
 
  214      Log() << kFATAL << 
"<EvaluateAverage> - no events selected for path search -> BUG!" << 
Endl;
 
  220   if (fNLinear>0) 
avsel.resize(fNLinear,0);
 
  221   if (fNRules>0)  
avrul.resize(fNRules,0);
 
  228   if (fRuleEnsemble->IsRuleMapOK()) { 
 
  230         ew = fRuleFit->GetTrainingEventWeight(i);
 
  237         if (fRuleEnsemble->DoRules()) {
 
  239            nrules = (*eventRuleMap).size();
 
  247      const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents());
 
  249         ew = fRuleFit->GetTrainingEventWeight(i);
 
  252          fRuleEnsemble->EvalLinEvent(*((*events)[i]));
 
  253          fRuleEnsemble->EvalEvent(*((*events)[i]));
 
  260            avrul[
r] += 
ew*fRuleEnsemble->GetEventRuleVal(
r);
 
 
  281   Double_t diff = (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal(&
e)?1:-1) - 
h;
 
 
  293   Double_t diff = (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal(fRuleEnsemble->GetRuleMapEvent( 
evtidx ))?1:-1) - 
h;
 
 
  306   Double_t diff = (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal(fRuleEnsemble->GetRuleMapEvent( 
evtidx ))?1:-1) - 
h;
 
 
  318      Log() << kFATAL << 
"<Risk> Invalid start/end indices! BUG!!!" << 
Endl;
 
 
  338      Log() << kFATAL << 
"<Risk> Invalid start/end indices! BUG!!!" << 
Endl;
 
 
  358   Log() << kWARNING << 
"<Penalty> Using unverified code! Check!" << 
Endl;
 
  360   const std::vector<Double_t> *
lincoeff = & (fRuleEnsemble->GetLinCoefficients());
 
  361   for (
UInt_t i=0; i<fNRules; i++) {
 
  364   for (
UInt_t i=0; i<fNLinear; i++) {
 
 
  391   fGDTauVec.resize( fGDNTau );
 
  393      fGDTauVec[0] = fGDTau;
 
  400         if (fGDTauVec[
itau]>1.0) fGDTauVec[
itau]=1.0;
 
  408   fGradVecLinTst.clear();
 
  413   fGDCoefLinTst.clear();
 
  417   fGDCoefTst.resize(fGDNTau);
 
  418   fGradVec.resize(fNRules,0);
 
  419   fGradVecTst.resize(fGDNTau);
 
  420   for (
UInt_t i=0; i<fGDNTau; i++) {
 
  421      fGradVecTst[i].resize(fNRules,0);
 
  422      fGDCoefTst[i].resize(fNRules,0);
 
  427   fGDCoefLinTst.resize(fGDNTau);
 
  428   fGradVecLin.resize(fNLinear,0);
 
  429   fGradVecLinTst.resize(fGDNTau);
 
  430   for (
UInt_t i=0; i<fGDNTau; i++) {
 
  431      fGradVecLinTst[i].resize(fNLinear,0);
 
  432      fGDCoefLinTst[i].resize(fNLinear,0);
 
  437   fGDErrTst.resize(fGDNTau,0);
 
  438   fGDErrTstOK.resize(fGDNTau,
kTRUE);
 
  439   fGDOfsTst.resize(fGDNTau,0);
 
  440   fGDNTauTstOK = fGDNTau;
 
 
  451   if (fGDNTau<2) 
return 0;
 
  452   if (fGDTauScan==0) 
return 0;
 
  454   if (fGDOfsTst.size()<1)
 
  455      Log() << kFATAL << 
"BUG! FindGDTau() has been called BEFORE InitGD()." << 
Endl;
 
  457   Log() << kINFO << 
"Estimating the cutoff parameter tau. The estimated time is a pessimistic maximum." << 
Endl;
 
  480      MakeTstGradientVector();
 
  482      UpdateTstCoefficients();
 
  489         Log() << kVERBOSE << 
Form(
"%4d",
ip+1) << 
". tau = " << 
Form(
"%4.4f",fGDTauVec[
itauMin])
 
  490               << 
" => error rate = " << fGDErrTst[
itauMin] << 
Endl;
 
  495      if (Log().GetMinType()>kVERBOSE)
 
  503      Log() << kERROR << 
"<FindGDTau> number of scanned loops is zero! Should NOT see this message." << 
Endl;
 
  506   fRuleEnsemble->SetCoefficients( fGDCoefTst[
itauMin] );
 
  507   fRuleEnsemble->SetLinCoefficients( fGDCoefLinTst[
itauMin] );
 
  508   fRuleEnsemble->SetOffset( fGDOfsTst[
itauMin] );
 
  509   Log() << kINFO << 
"Best path found with tau = " << 
Form(
"%4.4f",fGDTau)
 
  510         << 
" after " << 
timer.GetElapsedTime() << 
"      " << 
Endl;
 
 
  540   Log() << kINFO << 
"GD path scan - the scan stops when the max num. of steps is reached or a min is found" 
  542   Log() << kVERBOSE << 
"Number of events used per path step = " << fPathIdx2-fPathIdx1+1 << 
Endl;
 
  543   Log() << kVERBOSE << 
"Number of events used for error estimation = " << fPerfIdx2-fPerfIdx1+1 << 
Endl;
 
  546   const Bool_t isVerbose = (Log().GetMinType()<=kVERBOSE);
 
  553   EvaluateAveragePath();
 
  554   EvaluateAveragePerf();
 
  557   Log() << kVERBOSE << 
"Creating GD path"  << 
Endl;
 
  558   Log() << kVERBOSE << 
"  N(steps)     = "   << fGDNPathSteps << 
Endl;
 
  559   Log() << kVERBOSE << 
"  step         = "   << fGDPathStep   << 
Endl;
 
  560   Log() << kVERBOSE << 
"  N(tau)       = "   << fGDNTau       << 
Endl;
 
  561   Log() << kVERBOSE << 
"  N(tau steps) = "   << fGDTauScan    << 
Endl;
 
  562   Log() << kVERBOSE << 
"  tau range    = [ " << fGDTauVec[0]  << 
" , " << fGDTauVec[fGDNTau-1] << 
" ]" << 
Endl;
 
  593   std::vector<Double_t> 
valx;
 
  594   std::vector<Double_t> 
valy;
 
  595   std::vector<Double_t> 
valxy;
 
  605   int imod = fGDNPathSteps/100;
 
  606   if (
imod<100) 
imod = std::min(100,fGDNPathSteps);
 
  610   fAverageTruth = -CalcAverageTruth();
 
  613   fRuleEnsemble->ClearCoefficients(0);
 
  614   fRuleEnsemble->ClearLinCoefficients(0);
 
  615   for (
UInt_t i=0; i<fGDOfsTst.size(); i++) {
 
  618   Log() << kVERBOSE << 
"Obtained initial offset = " << 
offsetMin << 
Endl;
 
  638   Log() << kINFO << 
"Fitting model..." << 
Endl;
 
  645      MakeGradientVector();
 
  653      UpdateCoefficients();
 
  671         if (
isDebug) FillCoefficients();
 
  672         fNTCoefRad = fRuleEnsemble->CoefficientRadius();
 
  676         fNTRisk = RiskPath();
 
  684         if (fNTRisk>=
rprev) {
 
  687               Log() << 
"Risk(i+1)>=Risk(i) in path" << 
Endl;
 
  690                  Log() << kWARNING << 
"Chaotic behaviour of risk evolution" << 
Endl;
 
  691                  Log() << 
"--- STOPPING MINIMISATION ---" << 
Endl;
 
  692                  Log() << 
"This may be OK if minimum is already found" << 
Endl;
 
  722         if (fNTErrorRate<=
errmin) {
 
  726            fRuleEnsemble->GetCoefficients(
coefsMin);
 
  730         if ( fNTErrorRate > fGDErrScale*
errmin) found = 
kTRUE;
 
  739         valx.push_back(fNTNuval);
 
  740         valy.push_back(fNTErrorRate);
 
  741         valxy.push_back(fNTErrorRate*fNTNuval);
 
  746         if (
isDebug) fGDNtuple->Fill();
 
  748            Log() << kVERBOSE << 
"ParamsIRE : " 
  751                  << 
Form(
"%4.4f",fNTRisk) << 
" " 
  778            Log() << kWARNING << 
"BUG TRAP: should not be here - still, this bug is harmless;)" << 
Endl;
 
  782            fRuleEnsemble->GetCoefficients(
coefsMin);
 
  791   Log() << kINFO << 
"Minimisation elapsed time : " << 
timer.GetElapsedTime() << 
"                      " << 
Endl;
 
  792   Log() << kINFO << 
"----------------------------------------------------------------"  << 
Endl;
 
  793   Log() << kINFO << 
"Found minimum at step " << 
indMin+1 << 
" with error = " << 
errmin << 
Endl;
 
  794   Log() << kINFO << 
"Reason for ending loop: ";
 
  797      Log() << kINFO << 
"clear minima found";
 
  800      Log() << kINFO << 
"chaotic behaviour of risk";
 
  803      Log() << kINFO << 
"end of loop reached";
 
  806      Log() << kINFO << 
"unknown!";
 
  810   Log() << kINFO << 
"----------------------------------------------------------------"  << 
Endl;
 
  814      Log() << kWARNING << 
"Reached minimum early in the search" << 
Endl;
 
  815      Log() << 
"Check results and maybe decrease GDStep size" << 
Endl;
 
  825      Log() << kINFO << 
"The error rate was still decreasing at the end of the path" << 
Endl;
 
  826      Log() << kINFO << 
"Increase number of steps (GDNSteps)." << 
Endl;
 
  832      fRuleEnsemble->SetCoefficients( 
coefsMin );
 
  837      Log() << kFATAL << 
"BUG TRAP: minimum not found in MakeGDPath()" << 
Endl;
 
  845      Log() << kVERBOSE << 
"Timing per loop (ms):" << 
Endl;
 
 
  870   fNTOffset = fRuleEnsemble->GetOffset();
 
  872   for (
UInt_t i=0; i<fNRules; i++) {
 
  873      fNTCoeff[i] = fRuleEnsemble->GetRules(i)->GetCoefficient();
 
  875   for (
UInt_t i=0; i<fNLinear; i++) {
 
  876      fNTLinCoeff[i] = fRuleEnsemble->GetLinCoefficients(i);
 
 
  887   Log() << kWARNING << 
"<CalcFStar> Using unverified code! Check!" << 
Endl;
 
  890      Log() << kFATAL << 
"<CalcFStar> Invalid start/end indices!" << 
Endl;
 
  894   const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents());
 
  900   for (
UInt_t i=fPerfIdx1; i<fPerfIdx2+1; i++) {
 
  901      const Event& 
e = *(*events)[i];
 
 
  927   Log() << kWARNING << 
"<Optimism> Using unverified code! Check!" << 
Endl;
 
  930      Log() << kFATAL << 
"<Optimism> Invalid start/end indices!" << 
Endl;
 
  933   const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents());
 
  943   for (
UInt_t i=fPerfIdx1; i<fPerfIdx2+1; i++) {
 
  944      const Event& 
e = *(*events)[i];
 
  945      yhat = fRuleEnsemble->EvalEvent(i);         
 
  946      y    = (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal(&
e) ? 1.0:-1.0);           
 
  947      w    = fRuleFit->GetTrainingEventWeight(i)/fNEveEffPerf; 
 
 
  966   Log() << kWARNING << 
"<ErrorRateReg> Using unverified code! Check!" << 
Endl;
 
  969      Log() << kFATAL << 
"<ErrorRateReg> Invalid start/end indices!" << 
Endl;
 
  971   if (fFstar.size()!=
neve) {
 
  972      Log() << kFATAL << 
"--- RuleFitParams::ErrorRateReg() - F* not initialized! BUG!!!" 
  973            << 
" Fstar.size() = " << fFstar.size() << 
" , N(events) = " << 
neve << 
Endl;
 
  978   const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents());
 
  987   for (
UInt_t i=fPerfIdx1; i<fPerfIdx2+1; i++) {
 
  988      const Event& 
e = *(*events)[i];
 
  989      sF = fRuleEnsemble->EvalEvent( 
e );
 
 
 1010   Log() << kWARNING << 
"<ErrorRateBin> Using unverified code! Check!" << 
Endl;
 
 1013      Log() << kFATAL << 
"<ErrorRateBin> Invalid start/end indices!" << 
Endl;
 
 1016   const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents());
 
 1023   for (
UInt_t i=fPerfIdx1; i<fPerfIdx2+1; i++) {
 
 1024      const Event& 
e = *(*events)[i];
 
 1025      sF     = fRuleEnsemble->EvalEvent( 
e );
 
 1029      signy = (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal(&
e) ? +1:-1);
 
 
 1043                                               std::vector<Double_t> & 
sFbkg )
 
 1062   std::vector<Double_t>::const_iterator 
indit;
 
 1079                           std::bind(std::greater_equal<Double_t>(), std::placeholders::_1, 
fcut));
 
 1083                              std::bind(std::greater_equal<Double_t>(), std::placeholders::_1, 
fcut));
 
 
 1109   Log() << kWARNING << 
"<ErrorRateRoc> Should not be used in the current version! Check!" << 
Endl;
 
 1112      Log() << kFATAL << 
"<ErrorRateRoc> Invalid start/end indices!" << 
Endl;
 
 1115   const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents());
 
 1119   std::vector<Double_t> 
sFsig;
 
 1120   std::vector<Double_t> 
sFbkg;
 
 1126   for (
UInt_t i=fPerfIdx1; i<fPerfIdx2+1; i++) {
 
 1127      const Event& 
e = *(*events)[i];
 
 1128      sF = fRuleEnsemble->EvalEvent(i);
 
 1129      if (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal(&
e)) {
 
 
 1157   Log() << kWARNING << 
"<ErrorRateRocTst> Should not be used in the current version! Check!" << 
Endl;
 
 1160      Log() << kFATAL << 
"<ErrorRateRocTst> Invalid start/end indices!" << 
Endl;
 
 1164   const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents());
 
 1168   std::vector< std::vector<Double_t> > 
sFsig;
 
 1169   std::vector< std::vector<Double_t> > 
sFbkg;
 
 1171   sFsig.resize( fGDNTau );
 
 1172   sFbkg.resize( fGDNTau );
 
 1175   for (
UInt_t i=fPerfIdx1; i<fPerfIdx2+1; i++) {
 
 1179         sF = fRuleEnsemble->EvalEvent( i, fGDOfsTst[
itau], fGDCoefTst[
itau], fGDCoefLinTst[
itau] );
 
 1180         if (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal((*events)[i])) {
 
 1192      fGDErrTst[
itau] = err;
 
 
 1205      Log() << kFATAL << 
"<ErrorRateRocTst> Invalid start/end indices!" << 
Endl;
 
 1216      if (fGDErrTstOK[
itau]) {
 
 1234         if (fGDErrTstOK[
itau]) {
 
 1245   Log() << kVERBOSE << 
"TAU: " 
 
 1263      Log() << kFATAL << 
"<MakeTstGradientVector> Invalid start/end indices!" << 
Endl;
 
 1269   const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents());
 
 1273      if (fGDErrTstOK[
itau]) {
 
 1278            fGradVecLinTst[
itau][
il]=0;
 
 1292   for (
UInt_t i=fPathIdx1; i<fPathIdx2+1; i++) {
 
 1293      const Event *
e = (*events)[i];
 
 1295      if (fRuleEnsemble->DoRules()) {
 
 1297         nrules = (*eventRuleMap).size();
 
 1302         if (fGDErrTstOK[
itau]) {
 
 1303            sF = fRuleEnsemble->EvalEvent( i, fGDOfsTst[
itau], fGDCoefTst[
itau], fGDCoefLinTst[
itau] );
 
 1306               y = (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal(
e)?1.0:-1.0);
 
 1307               r = 
norm*(
y - 
sF) * fRuleFit->GetTrainingEventWeight(i);
 
 1310                  rind = (*eventRuleMap)[
ir];
 
 1315                  fGradVecLinTst[
itau][
il] += 
r*fRuleEnsemble->EvalLinEventRaw( 
il,i, 
kTRUE );
 
 
 1332      if (fGDErrTstOK[
itau]) {
 
 1334         maxr = ( (fNRules>0 ?
 
 1336         maxl = ( (fNLinear>0 ?
 
 1351            for (
UInt_t i=0; i<fNRules; i++) {
 
 1352               val = fGradVecTst[
itau][i];
 
 1359            for (
UInt_t i=0; i<fNLinear; i++) {
 
 1360               val = fGradVecLinTst[
itau][i];
 
 1362                  fGDCoefLinTst[
itau][i] += fGDPathStep*val*
stepScale/fRuleEnsemble->GetLinNorm(i);
 
 1369   CalcTstAverageResponse();
 
 
 1383      Log() << kFATAL << 
"<MakeGradientVector> Invalid start/end indices!" << 
Endl;
 
 1389   const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents());
 
 1408   for (
UInt_t i=fPathIdx1; i<fPathIdx2+1; i++) {
 
 1409      const Event *
e = (*events)[i];
 
 1412      sF = fRuleEnsemble->EvalEvent( i ); 
 
 1416         if (fRuleEnsemble->DoRules()) {
 
 1418            nrules = (*eventRuleMap).size();
 
 1420         y = (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal(
e)?1.0:-1.0);
 
 1421         r = 
norm*(
y - 
sF) * fRuleFit->GetTrainingEventWeight(i);
 
 1424            rind = (*eventRuleMap)[
ir];
 
 1425            fGradVec[
rind] += 
r;
 
 1431            fGradVecLin[
il] += 
r*fRuleEnsemble->EvalLinEventRaw( 
il, i, 
kTRUE );
 
 
 1446                      TMath::Abs(*(std::max_element( fGradVecLin.begin(), fGradVecLin.end(), 
AbsValue()))):0) );
 
 1465      for (
UInt_t i=0; i<fGradVec.size(); i++) {
 
 1468            coef = fRuleEnsemble->GetRulesConst(i)->GetCoefficient() + fGDPathStep*
gval;
 
 1469            fRuleEnsemble->GetRules(i)->SetCoefficient(coef);
 
 1474      for (
UInt_t i=0; i<fGradVecLin.size(); i++) {
 
 1475         lval = fGradVecLin[i];
 
 1477            lcoef = fRuleEnsemble->GetLinCoefficients(i) + (fGDPathStep*
lval/fRuleEnsemble->GetLinNorm(i));
 
 1478            fRuleEnsemble->SetLinCoefficient(i,
lcoef);
 
 1483      fRuleEnsemble->SetOffset( 
offset );
 
 
 1494      if (fGDErrTstOK[
itau]) {
 
 1495         fGDOfsTst[
itau] = 0;
 
 1496         for (
UInt_t s=0; s<fNLinear; s++) {
 
 1497            fGDOfsTst[
itau] -= fGDCoefLinTst[
itau][s] * fAverageSelectorPath[s];
 
 1500            fGDOfsTst[
itau] -= fGDCoefTst[
itau][
r] * fAverageRulePath[
r];
 
 
 1515   for (
UInt_t s=0; s<fNLinear; s++) {
 
 1516      ofs -= fRuleEnsemble->GetLinCoefficients(s) * fAverageSelectorPath[s];
 
 1519      ofs -= fRuleEnsemble->GetRules(
r)->GetCoefficient() * fAverageRulePath[
r];
 
 
 1529   if (fPathIdx2<=fPathIdx1) {
 
 1530      Log() << kFATAL << 
"<CalcAverageTruth> Invalid start/end indices!" << 
Endl;
 
 1536   const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents());
 
 1537   for (
UInt_t i=fPathIdx1; i<fPathIdx2+1; i++) {
 
 1538      Double_t ew = fRuleFit->GetTrainingEventWeight(i);
 
 1539      if (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal((*events)[i])) 
ensig += 
ew;
 
 1541      sum += 
ew*(fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal((*events)[i])?1.0:-1.0);
 
 1543   Log() << kVERBOSE << 
"Effective number of signal / background = " << 
ensig << 
" / " << 
enbkg << 
Endl;
 
 1545   return sum/fNEveEffPath;
 
 
 1551   return (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal(
e) ? 1:-1);
 
 
 1557   fLogger->SetMinType(t);
 
 
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t sel
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h offset
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t np
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t r
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t gval
 
char * Form(const char *fmt,...)
Formats a string in a circular formatting buffer.
 
const_iterator begin() const
 
const_iterator end() const
 
ostringstream derivative to redirect and format output
 
void CalcTstAverageResponse()
calc average response for all test paths - TODO: see comment under CalcAverageResponse() note that 0 ...
 
void MakeGDPath()
The following finds the gradient directed path in parameter space.
 
void EvaluateAverage(UInt_t ind1, UInt_t ind2, std::vector< Double_t > &avsel, std::vector< Double_t > &avrul)
evaluate the average of each variable and f(x) in the given range
 
UInt_t RiskPerfTst()
Estimates the error rate with the current set of parameters.
 
Double_t Risk(UInt_t ind1, UInt_t ind2, Double_t neff) const
risk assessment
 
Double_t Optimism()
implementation of eq.
 
Int_t FindGDTau()
This finds the cutoff parameter tau by scanning several different paths.
 
virtual ~RuleFitParams()
destructor
 
RuleFitParams()
constructor
 
void Init()
Initializes all parameters using the RuleEnsemble and the training tree.
 
Double_t CalcAverageResponse()
calculate the average response - TODO : rewrite bad dependancy on EvaluateAverage() !
 
void SetMsgType(EMsgType t)
 
Double_t Penalty() const
This is the "lasso" penalty To be used for regression.
 
void FillCoefficients()
helper function to store the rule coefficients in local arrays
 
Double_t LossFunction(const Event &e) const
Implementation of squared-error ramp loss function (eq 39,40 in ref 1) This is used for binary Classi...
 
void InitGD()
Initialize GD path search.
 
Int_t Type(const Event *e) const
 
void ErrorRateRocTst()
Estimates the error rate with the current set of parameters.
 
void CalcFStar()
Estimates F* (optimum scoring function) for all events for the given sets.
 
void MakeTstGradientVector()
make test gradient vector for all tau same algorithm as MakeGradientVector()
 
Double_t CalcAverageTruth()
calculate the average truth
 
void UpdateTstCoefficients()
Establish maximum gradient for rules, linear terms and the offset for all taus TODO: do not need inde...
 
void MakeGradientVector()
make gradient vector
 
void UpdateCoefficients()
Establish maximum gradient for rules, linear terms and the offset.
 
void InitNtuple()
initializes the ntuple
 
Double_t ErrorRateBin()
Estimates the error rate with the current set of parameters It uses a binary estimate of (y-F*(x)) (y...
 
Double_t ErrorRateReg()
Estimates the error rate with the current set of parameters This code is pretty messy at the moment.
 
Double_t ErrorRateRoc()
Estimates the error rate with the current set of parameters.
 
Double_t ErrorRateRocRaw(std::vector< Double_t > &sFsig, std::vector< Double_t > &sFbkg)
Estimates the error rate with the current set of parameters.
 
Timing information for training and evaluation of MVA methods.
 
virtual Int_t Write(const char *name=nullptr, Int_t option=0, Int_t bufsize=0)
Write this object to the current directory.
 
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
 
A TTree represents a columnar dataset.
 
MsgLogger & Endl(MsgLogger &ml)
 
Short_t Max(Short_t a, Short_t b)
Returns the largest of a and b.
 
Double_t Sqrt(Double_t x)
Returns the square root of x.
 
Short_t Min(Short_t a, Short_t b)
Returns the smallest of a and b.
 
Short_t Abs(Short_t d)
Returns the absolute value of parameter Short_t d.
 
static uint64_t sum(uint64_t i)