Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
RooRealMPFE.cxx
Go to the documentation of this file.
1/// \cond ROOFIT_INTERNAL
2
3/*****************************************************************************
4 * Project: RooFit *
5 * Package: RooFitCore *
6 * @(#)root/roofitcore:$Id$
7 * Authors: *
8 * WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu *
9 * DK, David Kirkby, UC Irvine, dkirkby@uci.edu *
10 * *
11 * Copyright (c) 2000-2005, Regents of the University of California *
12 * and Stanford University. All rights reserved. *
13 * *
14 * Redistribution and use in source and binary forms, *
15 * with or without modification, are permitted according to the terms *
16 * listed in LICENSE (http://roofit.sourceforge.net/license.txt) *
17 *****************************************************************************/
18
19/**
20\file RooRealMPFE.cxx
21\class RooRealMPFE
22\ingroup Roofitcore
23
24Multi-processor front-end for parallel calculation
25of RooAbsReal objects. Each RooRealMPFE forks a process that calculates
26the value of the proxies RooAbsReal object. The (re)calculation of
27the proxied object is started asynchronously with the calculate() option.
28A subsequent call to getVal() will return the calculated value when available
29If the calculation is still in progress when getVal() is called it blocks
30the calling process until the calculation is done. The forked calculation process
31is terminated when the front-end object is deleted
32Simple use demonstration
33
34~~~{.cpp}
35RooAbsReal* slowFunc ;
36
37double val = slowFunc->getVal() // Evaluate slowFunc in current process
38
39RooRealMPFE mpfe("mpfe","frontend to slowFunc",*slowFunc) ;
40mpfe.calculate() ; // Start calculation of slow-func in remote process
41 // .. do other stuff here ..
42double val = mpfe.getVal() // Wait for remote calculation to finish and retrieve value
43~~~
44
45For general multiprocessing in ROOT, please refer to the TProcessExecutor class.
46
47**/
48
49#ifndef _WIN32
50#include "BidirMMapPipe.h"
51#endif
52
53#include <cstdlib>
54#include <memory>
55#include <sstream>
56#include "RooRealMPFE.h"
57#include "RooArgSet.h"
58#include "RooAbsCategory.h"
59#include "RooRealVar.h"
60#include "RooCategory.h"
61#include "RooMsgService.h"
62#include "RooNLLVar.h"
63
64#include "TSystem.h"
65
66#include <ostream>
67
68class RooRealMPFE ;
69
70// RooMPSentinel is a singleton class that keeps track of all
71// parallel execution processes for goodness-of-fit calculations.
72// The primary task of RooMPSentinel is to terminate all server processes
73// when the main ROOT process is exiting.
74struct RooMPSentinel {
75
76 static RooMPSentinel& instance();
77
79
80 void add(RooRealMPFE& mpfe) ;
81 void remove(RooRealMPFE& mpfe) ;
82
84};
85
86RooMPSentinel& RooMPSentinel::instance() {
87 static RooMPSentinel inst;
88 return inst;
89}
90
91
92using std::string, std::ostringstream, std::list;
93using namespace RooFit;
94
95
96////////////////////////////////////////////////////////////////////////////////
97/// Construct front-end object for object 'arg' whose evaluation will be calculated
98/// asynchronously in a separate process. If calcInline is true the value of 'arg'
99/// is calculate synchronously in the current process.
100
101RooRealMPFE::RooRealMPFE(const char *name, const char *title, RooAbsReal& arg, bool calcInline) :
102 RooAbsReal(name,title),
103 _state(Initialize),
104 _arg("arg","arg",this,arg),
105 _vars("vars","vars",this),
111 _pipe(nullptr),
112 _updateMaster(nullptr),
114{
115#ifdef _WIN32
116 _inlineMode = true;
117#endif
118 initVars() ;
119 RooMPSentinel::instance().add(*this) ;
120
121}
122
123
124
125////////////////////////////////////////////////////////////////////////////////
126/// Copy constructor. Initializes in clean state so that upon eval
127/// this instance will create its own server processes
128
129RooRealMPFE::RooRealMPFE(const RooRealMPFE& other, const char* name) :
131 _state(Initialize),
132 _arg("arg",this,other._arg),
133 _vars("vars",this,other._vars),
140 _pipe(nullptr),
141 _updateMaster(nullptr),
143{
144 initVars() ;
145 RooMPSentinel::instance().add(*this) ;
146}
147
148
149
150////////////////////////////////////////////////////////////////////////////////
151/// Destructor
152
153RooRealMPFE::~RooRealMPFE()
154{
155 if (_state==Client) standby();
156 RooMPSentinel::instance().remove(*this);
157}
158
159
160
161////////////////////////////////////////////////////////////////////////////////
162/// Initialize list of variables of front-end argument 'arg'
163
164void RooRealMPFE::initVars()
165{
166 // Empty current lists
167 _vars.removeAll() ;
168 _saveVars.removeAll() ;
169
170 // Retrieve non-constant parameters
171 std::unique_ptr<RooArgSet> vars{_arg->getParameters(RooArgSet())};
172 // RooArgSet *ncVars = vars->selectByAttrib("Constant", false);
173 RooArgList varList(*vars) ;
174
175 // Save in lists
176 _vars.add(varList) ;
177 _saveVars.addClone(varList) ;
178 _valueChanged.resize(_vars.size()) ;
179 _constChanged.resize(_vars.size()) ;
180
181 // Force next calculation
182 _forceCalc = true ;
183}
184
185double RooRealMPFE::getCarry() const
186{
187 if (_inlineMode) {
188 RooAbsTestStatistic* tmp = dynamic_cast<RooAbsTestStatistic*>(_arg.absArg());
189 if (tmp) return tmp->getCarry();
190 else return 0.;
191 } else {
192 return _evalCarry;
193 }
194}
195
196////////////////////////////////////////////////////////////////////////////////
197/// Initialize the remote process and message passing
198/// pipes between current process and remote process
199
200void RooRealMPFE::initialize()
201{
202 // Trivial case: Inline mode
203 if (_inlineMode) {
204 _state = Inline ;
205 return ;
206 }
207
208#ifndef _WIN32
209 // Clear eval error log prior to forking
210 // to avoid confusions...
211 clearEvalErrorLog() ;
212 // Fork server process and setup IPC
213 _pipe = new BidirMMapPipe();
214
215 if (_pipe->isChild()) {
216 // Start server loop
217 _state = Server ;
218 serverLoop();
219
220 // Kill server at end of service
221 if (_verboseServer) ccoutD(Minimization) << "RooRealMPFE::initialize(" <<
222 GetName() << ") server process terminating" << std::endl ;
223
224 delete _arg.absArg();
225 delete _pipe;
226 _exit(0) ;
227 } else {
228 // Client process - fork successful
229 if (_verboseClient) {
230 ccoutD(Minimization) << "RooRealMPFE::initialize(" << GetName() << ") successfully forked server process "
231 << _pipe->pidOtherEnd() << std::endl;
232 }
233 _state = Client ;
235 }
236#endif // _WIN32
237}
238
239
240
241////////////////////////////////////////////////////////////////////////////////
242/// Server loop of remote processes. This function will return
243/// only when an incoming TERMINATE message is received.
244
245void RooRealMPFE::serverLoop()
246{
247#ifndef _WIN32
248 int msg ;
249
250 Int_t idx;
251 Int_t index;
253 double value ;
254 bool isConst ;
255
256 clearEvalErrorLog() ;
257
258 while(*_pipe && !_pipe->eof()) {
259 *_pipe >> msg;
260 if (Terminate == msg) {
261 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
262 << ") IPC fromClient> Terminate" << std::endl;
263 // send terminate acknowledged to client
264 *_pipe << msg << BidirMMapPipe::flush;
265 break;
266 }
267
268 switch (msg) {
269 case SendReal:
270 {
271 *_pipe >> idx >> value >> isConst;
272 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
273 << ") IPC fromClient> SendReal [" << idx << "]=" << value << std::endl ;
274 RooRealVar* rvar = static_cast<RooRealVar*>(_vars.at(idx)) ;
275 rvar->setVal(value) ;
276 if (rvar->isConstant() != isConst) {
277 rvar->setConstant(isConst) ;
278 }
279 }
280 break ;
281
282 case SendCat:
283 {
284 *_pipe >> idx >> index;
285 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
286 << ") IPC fromClient> SendCat [" << idx << "]=" << index << std::endl ;
287 (static_cast<RooCategory*>(_vars.at(idx)))->setIndex(index) ;
288 }
289 break ;
290
291 case Calculate:
292 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
293 << ") IPC fromClient> Calculate" << std::endl ;
294 _value = _arg ;
295 break ;
296
298 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
299 << ") IPC fromClient> Calculate" << std::endl ;
300
302 _value = _arg ;
304 break ;
305
306 case Retrieve:
307 {
308 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
309 << ") IPC fromClient> Retrieve" << std::endl ;
311 numErrors = numEvalErrors();
312 *_pipe << msg << _value << getCarry() << numErrors;
313
314 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
315 << ") IPC toClient> ReturnValue " << _value << " NumError " << numErrors << std::endl ;
316
317 if (numErrors) {
318 // Loop over errors
319 std::string objidstr;
320 {
321 ostringstream oss2;
322 // Format string with object identity as this cannot be evaluated on the other side
323 oss2 << "PID" << gSystem->GetPid() << "/";
324 printStream(oss2,kName|kClassName|kArgs,kInline);
325 objidstr = oss2.str();
326 }
327 std::map<const RooAbsArg*,std::pair<string,list<EvalError> > >::const_iterator iter = evalErrorIter();
328 const RooAbsArg* ptr = nullptr;
329 for (int i = 0; i < numEvalErrorItems(); ++i) {
330 list<EvalError>::const_iterator iter2 = iter->second.second.begin();
331 for (; iter->second.second.end() != iter2; ++iter2) {
332 ptr = iter->first;
333 *_pipe << ptr << iter2->_msg << iter2->_srvval << objidstr;
334 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
335 << ") IPC toClient> sending error log Arg " << iter->first << " Msg " << iter2->_msg << std::endl ;
336 }
337 }
338 // let other end know that we're done with the list of errors
339 ptr = nullptr;
340 *_pipe << ptr;
341 // Clear error list on local side
342 clearEvalErrorLog();
343 }
344 *_pipe << BidirMMapPipe::flush;
345 }
346 break;
347
348 case Verbose:
349 {
350 bool flag ;
351 *_pipe >> flag;
352 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
353 << ") IPC fromClient> Verbose " << (flag?1:0) << std::endl ;
355 }
356 break ;
357
358
359 case ApplyNLLW2:
360 {
361 bool flag ;
362 *_pipe >> flag;
363 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
364 << ") IPC fromClient> ApplyNLLW2 " << (flag?1:0) << std::endl ;
365
366 // Do application of weight-squared here
368 }
369 break ;
370
371 case EnableOffset:
372 {
373 bool flag ;
374 *_pipe >> flag;
375 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
376 << ") IPC fromClient> EnableOffset " << (flag?1:0) << std::endl ;
377
378 // Enable likelihoof offsetting here
379 ((RooAbsReal&)_arg.arg()).enableOffsetting(flag) ;
380 }
381 break ;
382
383 case LogEvalError:
384 {
385 int iflag2;
386 *_pipe >> iflag2;
389 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
390 << ") IPC fromClient> LogEvalError flag = " << flag2 << std::endl ;
391 }
392 break ;
393
394
395 default:
396 if (_verboseServer) std::cout << "RooRealMPFE::serverLoop(" << GetName()
397 << ") IPC fromClient> Unknown message (code = " << msg << ")" << std::endl ;
398 break ;
399 }
400 }
401
402#endif // _WIN32
403}
404
405
406
407////////////////////////////////////////////////////////////////////////////////
408/// Client-side function that instructs server process to start
409/// asynchronous (re)calculation of function value. This function
410/// returns immediately. The calculated value can be retrieved
411/// using getVal()
412
413void RooRealMPFE::calculate() const
414{
415
416 // Start asynchronous calculation of arg value
417 if (_state==Initialize) {
418 const_cast<RooRealMPFE*>(this)->initialize() ;
419 }
420
421 // Inline mode -- Calculate value now
422 if (_state==Inline) {
423 _value = _arg ;
424 clearValueDirty() ;
425 }
426
427#ifndef _WIN32
428 // Compare current value of variables with saved values and send changes to server
429 if (_state==Client) {
430 Int_t i(0) ;
431
432 //for (i=0 ; i<_vars.size() ; i++) {
433 RooAbsArg *var;
435 for (std::size_t j=0 ; j<_vars.size() ; j++) {
436 var = _vars.at(j);
437 saveVar = _saveVars.at(j);
438
439 //bool valChanged = !(*var==*saveVar) ;
440 bool valChanged;
441 bool constChanged;
442 if (!_updateMaster) {
443 valChanged = !var->isIdentical(*saveVar,true) ;
444 constChanged = (var->isConstant() != saveVar->isConstant()) ;
447 } else {
448 valChanged = _updateMaster->_valueChanged[i] ;
449 constChanged = _updateMaster->_constChanged[i] ;
450 }
451
453 if (_verboseClient) std::cout << "RooRealMPFE::calculate(" << GetName()
454 << ") variable " << _vars.at(i)->GetName() << " changed" << std::endl ;
455 if (constChanged) {
456 (static_cast<RooRealVar*>(saveVar))->setConstant(var->isConstant()) ;
457 }
458 saveVar->copyCache(var) ;
459
460 // send message to server
461 if (dynamic_cast<RooAbsReal*>(var)) {
462 int msg = SendReal ;
463 double val = (static_cast<RooAbsReal*>(var))->getVal() ;
464 bool isC = var->isConstant() ;
465 *_pipe << msg << i << val << isC;
466
467 if (_verboseServer) std::cout << "RooRealMPFE::calculate(" << GetName()
468 << ") IPC toServer> SendReal [" << i << "]=" << val << (isC?" (Constant)":"") << std::endl ;
469 } else if (dynamic_cast<RooAbsCategory*>(var)) {
470 int msg = SendCat ;
471 UInt_t idx = (static_cast<RooAbsCategory*>(var))->getCurrentIndex() ;
472 *_pipe << msg << i << idx;
473 if (_verboseServer) std::cout << "RooRealMPFE::calculate(" << GetName()
474 << ") IPC toServer> SendCat [" << i << "]=" << idx << std::endl ;
475 }
476 }
477 i++ ;
478 }
479
480 int msg = hideOffset() ? Calculate : CalculateNoOffset;
481 *_pipe << msg;
482 if (_verboseServer) std::cout << "RooRealMPFE::calculate(" << GetName()
483 << ") IPC toServer> Calculate " << std::endl ;
484
485 // Clear dirty state and mark that calculation request was dispatched
486 clearValueDirty() ;
488 _forceCalc = false ;
489
490 msg = Retrieve ;
491 *_pipe << msg << BidirMMapPipe::flush;
492 if (_verboseServer) std::cout << "RooRealMPFE::evaluate(" << GetName()
493 << ") IPC toServer> Retrieve " << std::endl ;
495
496 } else if (_state!=Inline) {
497 std::cout << "RooRealMPFE::calculate(" << GetName()
498 << ") ERROR not in Client or Inline mode" << std::endl ;
499 }
500
501
502#endif // _WIN32
503}
504
505
506
507
508////////////////////////////////////////////////////////////////////////////////
509/// If value needs recalculation and calculation has not been started
510/// with a call to calculate() start it now. This function blocks
511/// until remote process has finished calculation and returns
512/// remote value
513
514double RooRealMPFE::getValV(const RooArgSet* /*nset*/) const
515{
516
517 if (isValueDirty()) {
518 // Cache is dirty, no calculation has been started yet
519 calculate() ;
520 _value = evaluate() ;
521 } else if (_calcInProgress) {
522 // Cache is clean and calculation is in progress
523 _value = evaluate() ;
524 } else {
525 // Cache is clean and calculated value is in cache
526 }
527
528 return _value ;
529}
530
531
532
533////////////////////////////////////////////////////////////////////////////////
534/// Send message to server process to retrieve output value
535/// If error were logged use logEvalError() on remote side
536/// transfer those errors to the local eval error queue.
537
538double RooRealMPFE::evaluate() const
539{
540 // Retrieve value of arg
541 double return_value = 0;
542 if (_state==Inline) {
543 return_value = _arg ;
544 } else if (_state==Client) {
545#ifndef _WIN32
546 bool needflush = false;
547 int msg;
548 double value;
549
550 // If current error logging state is not the same as remote state
551 // update the remote state
552 if (evalErrorLoggingMode() != _remoteEvalErrorLoggingState) {
553 msg = LogEvalError ;
554 RooAbsReal::ErrorLoggingMode flag = evalErrorLoggingMode() ;
555 *_pipe << msg << flag;
556 needflush = true;
557 _remoteEvalErrorLoggingState = evalErrorLoggingMode() ;
558 }
559
560 if (!_retrieveDispatched) {
561 msg = Retrieve ;
562 *_pipe << msg;
563 needflush = true;
564 if (_verboseServer) std::cout << "RooRealMPFE::evaluate(" << GetName()
565 << ") IPC toServer> Retrieve " << std::endl ;
566 }
567 if (needflush) *_pipe << BidirMMapPipe::flush;
569
570
572
573 *_pipe >> msg >> value >> _evalCarry >> numError;
574
575 if (msg!=ReturnValue) {
576 std::cout << "RooRealMPFE::evaluate(" << GetName()
577 << ") ERROR: unexpected message from server process: " << msg << std::endl ;
578 return 0 ;
579 }
580 if (_verboseServer) std::cout << "RooRealMPFE::evaluate(" << GetName()
581 << ") IPC fromServer> ReturnValue " << value << std::endl ;
582
583 if (_verboseServer) std::cout << "RooRealMPFE::evaluate(" << GetName()
584 << ") IPC fromServer> NumErrors " << numError << std::endl ;
585 if (numError) {
586 // Retrieve remote errors and feed into local error queue
587 char *msgbuf1 = nullptr;
588 char *msgbuf2 = nullptr;
589 char *msgbuf3 = nullptr;
590 RooAbsArg *ptr = nullptr;
591 while (true) {
592 *_pipe >> ptr;
593 if (!ptr) break;
594 *_pipe >> msgbuf1 >> msgbuf2 >> msgbuf3;
595 if (_verboseServer) std::cout << "RooRealMPFE::evaluate(" << GetName()
596 << ") IPC fromServer> retrieving error log Arg " << ptr << " Msg " << msgbuf1 << std::endl ;
597
598 logEvalError(reinterpret_cast<RooAbsReal*>(ptr),msgbuf3,msgbuf1,msgbuf2) ;
599 }
600 std::free(msgbuf1);
601 std::free(msgbuf2);
602 std::free(msgbuf3);
603 }
604
605 // Mark end of calculation in progress
608#endif // _WIN32
609 }
610
611 return return_value;
612}
613
614
615
616////////////////////////////////////////////////////////////////////////////////
617/// Terminate remote server process and return front-end class
618/// to standby mode. Calls to calculate() or evaluate() after
619/// this call will automatically recreated the server process.
620
621void RooRealMPFE::standby()
622{
623#ifndef _WIN32
624 if (_state==Client) {
625 if (_pipe->good()) {
626 // Terminate server process ;
627 if (_verboseServer) std::cout << "RooRealMPFE::standby(" << GetName()
628 << ") IPC toServer> Terminate " << std::endl;
629 int msg = Terminate;
630 *_pipe << msg << BidirMMapPipe::flush;
631 // read handshake
632 msg = 0;
633 *_pipe >> msg;
634 if (Terminate != msg || 0 != _pipe->close()) {
635 std::cerr << "In " << __func__ << "(" << __FILE__ ", " << __LINE__ <<
636 "): Server shutdown failed." << std::endl;
637 }
638 } else {
639 if (_verboseServer) {
640 std::cerr << "In " << __func__ << "(" << __FILE__ ", " <<
641 __LINE__ << "): Pipe has already shut down, not sending "
642 "Terminate to server." << std::endl;
643 }
644 }
645 // Close pipes
646 delete _pipe;
647 _pipe = nullptr;
648
649 // Revert to initialize state
650 _state = Initialize;
651 }
652#endif // _WIN32
653}
654
655
656////////////////////////////////////////////////////////////////////////////////
657/// Control verbose messaging related to inter process communication
658/// on both client and server side
659
660void RooRealMPFE::setVerbose(bool clientFlag, bool serverFlag)
661{
662#ifndef _WIN32
663 if (_state==Client) {
664 int msg = Verbose ;
665 *_pipe << msg << serverFlag;
666 if (_verboseServer) std::cout << "RooRealMPFE::setVerbose(" << GetName()
667 << ") IPC toServer> Verbose " << (serverFlag?1:0) << std::endl ;
668 }
669#endif // _WIN32
671}
672
673
674////////////////////////////////////////////////////////////////////////////////
675/// Control verbose messaging related to inter process communication
676/// on both client and server side
677
678void RooRealMPFE::applyNLLWeightSquared(bool flag)
679{
680#ifndef _WIN32
681 if (_state==Client) {
682 int msg = ApplyNLLW2 ;
683 *_pipe << msg << flag;
684 if (_verboseServer) std::cout << "RooRealMPFE::applyNLLWeightSquared(" << GetName()
685 << ") IPC toServer> ApplyNLLW2 " << (flag?1:0) << std::endl ;
686 }
687#endif // _WIN32
689}
690
691
692////////////////////////////////////////////////////////////////////////////////
693
694void RooRealMPFE::doApplyNLLW2(bool flag)
695{
696 RooNLLVar* nll = dynamic_cast<RooNLLVar*>(_arg.absArg()) ;
697 if (nll) {
698 nll->applyWeightSquared(flag) ;
699 }
700}
701
702
703////////////////////////////////////////////////////////////////////////////////
704/// Control verbose messaging related to inter process communication
705/// on both client and server side
706
707void RooRealMPFE::enableOffsetting(bool flag)
708{
709#ifndef _WIN32
710 if (_state==Client) {
711 int msg = EnableOffset ;
712 *_pipe << msg << flag;
713 if (_verboseServer) std::cout << "RooRealMPFE::enableOffsetting(" << GetName()
714 << ") IPC toServer> EnableOffset " << (flag?1:0) << std::endl ;
715 }
716#endif // _WIN32
717 ((RooAbsReal&)_arg.arg()).enableOffsetting(flag) ;
718}
719
720
721
722////////////////////////////////////////////////////////////////////////////////
723/// Destructor. Terminate all parallel processes still registered with
724/// the sentinel
725
726RooMPSentinel::~RooMPSentinel()
727{
728 for(auto * mpfe : static_range_cast<RooRealMPFE*>(_mpfeSet)) {
729 mpfe->standby() ;
730 }
731}
732
733
734
735////////////////////////////////////////////////////////////////////////////////
736/// Register given multi-processor front-end object with the sentinel
737
738void RooMPSentinel::add(RooRealMPFE& mpfe)
739{
740 _mpfeSet.add(mpfe,true) ;
741}
742
743
744
745////////////////////////////////////////////////////////////////////////////////
746/// Remove given multi-processor front-end object from the sentinel
747
748void RooMPSentinel::remove(RooRealMPFE& mpfe)
749{
750 _mpfeSet.remove(mpfe,true) ;
751}
752
753/// \endcond
ROOT::RRangeCast< T, false, Range_t > static_range_cast(Range_t &&coll)
static Roo_reg_AGKInteg1D instance
#define ccoutD(a)
int Int_t
Signed integer 4 bytes (int)
Definition RtypesCore.h:60
unsigned int UInt_t
Unsigned integer 4 bytes (unsigned int)
Definition RtypesCore.h:61
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 index
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void value
char name[80]
Definition TGX11.cxx:142
@ kName
R__EXTERN TSystem * gSystem
Definition TSystem.h:582
Common abstract base class for objects that represent a value and a "shape" in RooFit.
Definition RooAbsArg.h:76
bool isConstant() const
Check if the "Constant" attribute is set.
Definition RooAbsArg.h:283
virtual bool isIdentical(const RooAbsArg &other, bool assumeSameType=false) const =0
A space to attach TBranches.
void setConstant(bool value=true)
Abstract base class for objects that represent a real value and implements functionality common to al...
Definition RooAbsReal.h:63
static void setHideOffset(bool flag)
static void setEvalErrorLoggingMode(ErrorLoggingMode m)
Set evaluation error logging mode.
RooArgList is a container object that can hold multiple RooAbsArg objects.
Definition RooArgList.h:22
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Definition RooArgSet.h:24
Object to represent discrete states.
Definition RooCategory.h:28
Variable that can be changed from the outside.
Definition RooRealVar.h:37
void setVal(double value) override
Set value of variable to 'value'.
virtual int GetPid()
Get process id.
Definition TSystem.cxx:720
RooCmdArg Verbose(bool flag=true)
double nll(double pdf, double weight, int binnedL, int doBinOffset)
Definition MathFuncs.h:449
The namespace RooFit contains mostly switches that change the behaviour of functions of PDFs (or othe...
Definition CodegenImpl.h:73
void evaluate(typename Architecture_t::Tensor_t &A, EActivationFunction f)
Apply the given activation function to each value in the given tensor A.
Definition Functions.h:98
void initialize(typename Architecture_t::Matrix_t &A, EInitialization m)
Definition Functions.h:282
void Initialize(Bool_t useTMVAStyle=kTRUE)
Definition tmvaglob.cxx:176