Skip to content

Commit

Permalink
[RF] Remove logging to RooDataSet in RooMinimizer
Browse files Browse the repository at this point in the history
This was only introduced for internal benchmarks recently and it's not
required in the public interface.
  • Loading branch information
guitargeek committed Sep 18, 2024
1 parent eb8c932 commit 6cf1d59
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 25 deletions.
14 changes: 0 additions & 14 deletions roofit/roofitcore/inc/RooMinimizer.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ class RooArgList;
class RooRealVar;
class RooArgSet;
class RooPlot;
class RooDataSet;
namespace RooFit {
namespace TestStatistics {
class LikelihoodGradientJob;
Expand Down Expand Up @@ -167,17 +166,6 @@ class RooMinimizer : public TObject {
double n4 = 0.0, double n5 = 0.0, double n6 = 0.0, unsigned int npoints = 50);

void setProfile(bool flag = true) { _cfg.profile = flag; }
/// Enable or disable the logging of function evaluations to a RooDataSet.
/// \see RooMinimizer::getLogDataSet().
/// param[in] flag Boolean flag to disable or enable the functionality.
void setLoggingToDataSet(bool flag = true) { _loggingToDataSet = flag; }

/// If logging of function evaluations to a RooDataSet is enabled, returns a
/// pointer to a dataset with one row per evaluation of the RooAbsReal passed
/// to the minimizer. As columns, there are all floating parameters and the
/// values they had for that evaluation.
/// \see RooMinimizer::setLoggingToDataSet(bool).
RooDataSet *getLogDataSet() const { return _logDataSet.get(); }

int getPrintLevel();

Expand Down Expand Up @@ -247,13 +235,11 @@ class RooMinimizer : public TObject {
std::unique_ptr<ROOT::Math::Minimizer> _minimizer; ///<! pointer to used minimizer
int _status = -99;
bool _profileStart = false;
bool _loggingToDataSet = false;
TStopwatch _timer;
TStopwatch _cumulTimer;
std::unique_ptr<TMatrixDSym> _extV;
std::unique_ptr<RooAbsMinimizerFcn> _fcn;
std::vector<std::pair<std::string, int>> _statusHistory;
std::unique_ptr<RooDataSet> _logDataSet;
RooMinimizer::Config _cfg; // local config object

ClassDefOverride(RooMinimizer, 0) // RooFit interface to ROOT::Math::Minimizer
Expand Down
11 changes: 0 additions & 11 deletions roofit/roofitcore/src/RooAbsMinimizerFcn.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -483,17 +483,6 @@ double RooAbsMinimizerFcn::applyEvalErrorHandling(double fvalue) const

void RooAbsMinimizerFcn::finishDoEval() const
{

if (_context->_loggingToDataSet) {

if (!_context->_logDataSet) {
const char *name = "minimizer_log_dataset";
_context->_logDataSet = std::make_unique<RooDataSet>(name, name, *_floatParamList);
}

_context->_logDataSet->add(*_floatParamList);
}

_evalCounter++;
}

Expand Down

0 comments on commit 6cf1d59

Please sign in to comment.