Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /include/root/RooConvGenContext.h was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 /*****************************************************************************
0002  * Project: RooFit                                                           *
0003  * Package: RooFitCore                                                       *
0004  *    File: $Id: RooConvGenContext.h,v 1.12 2007/05/11 09:11:30 verkerke Exp $
0005  * Authors:                                                                  *
0006  *   WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu       *
0007  *   DK, David Kirkby,    UC Irvine,         dkirkby@uci.edu                 *
0008  *                                                                           *
0009  * Copyright (c) 2000-2005, Regents of the University of California          *
0010  *                          and Stanford University. All rights reserved.    *
0011  *                                                                           *
0012  * Redistribution and use in source and binary forms,                        *
0013  * with or without modification, are permitted according to the terms        *
0014  * listed in LICENSE (http://roofit.sourceforge.net/license.txt)             *
0015  *****************************************************************************/
0016 #ifndef ROO_CONV_GEN_CONTEXT
0017 #define ROO_CONV_GEN_CONTEXT
0018 
0019 #include "RooAbsGenContext.h"
0020 #include "RooArgSet.h"
0021 
0022 class RooAbsAnaConvPdf;
0023 class RooDataSet;
0024 class RooRealIntegral;
0025 class RooAcceptReject;
0026 class TRandom;
0027 class RooRealVar ;
0028 class RooNumConvPdf ;
0029 class RooFFTConvPdf ;
0030 
0031 class RooConvGenContext : public RooAbsGenContext {
0032 public:
0033   RooConvGenContext(const RooFFTConvPdf &model, const RooArgSet &vars, const RooDataSet *prototype= nullptr,
0034           const RooArgSet* auxProto=nullptr, bool _verbose= false);
0035   RooConvGenContext(const RooNumConvPdf &model, const RooArgSet &vars, const RooDataSet *prototype= nullptr,
0036           const RooArgSet* auxProto=nullptr, bool _verbose= false);
0037   RooConvGenContext(const RooAbsAnaConvPdf &model, const RooArgSet &vars, const RooDataSet *prototype= nullptr,
0038           const RooArgSet* auxProto=nullptr, bool _verbose= false);
0039 
0040   void setProtoDataOrder(Int_t* lut) override ;
0041 
0042   void attach(const RooArgSet& params) override ;
0043 
0044   void printMultiline(std::ostream &os, Int_t content, bool verbose=false, TString indent="") const override ;
0045 
0046   void initGenerator(const RooArgSet &theEvent) override;
0047   void generateEvent(RooArgSet &theEvent, Int_t remaining) override;
0048 
0049 protected:
0050 
0051   RooConvGenContext(const RooConvGenContext& other) ;
0052 
0053   std::unique_ptr<RooAbsGenContext> _pdfGen ;    ///< Physics model generator context
0054   std::unique_ptr<RooAbsGenContext> _modelGen ;  ///< Resolution model generator context
0055   TString _convVarName ;                         ///< Name of convolution variable
0056   std::unique_ptr<RooArgSet> _pdfVarsOwned ;     ///< Owning version of pdfVars ;
0057   std::unique_ptr<RooArgSet> _modelVarsOwned ;   ///< Owning version of modelVars ;
0058   std::unique_ptr<RooArgSet> _pdfVars ;          ///< Holder of PDF x truth event
0059   std::unique_ptr<RooArgSet> _modelVars ;        ///< Holder of resModel event
0060   std::unique_ptr<RooArgSet> _pdfCloneSet ;      ///< Owner of PDF clone
0061   std::unique_ptr<RooArgSet> _modelCloneSet ;    ///< Owner of resModel clone
0062   RooRealVar* _cvModel{nullptr};                 ///< Convolution variable in resModel event
0063   RooRealVar* _cvPdf{nullptr};                   ///< Convolution variable in PDFxTruth event
0064   RooRealVar* _cvOut{nullptr};                   ///< Convolution variable in output event
0065 
0066   ClassDefOverride(RooConvGenContext,0) // Context for generating a dataset from a PDF
0067 };
0068 
0069 #endif