Common base class for variable processors. More...
#include <VarProcessor.h>
Classes | |
class | Config |
Helper class for discriminator computer set-up procedure. More... | |
class | ConfigCtx |
class | ConfIterator |
Iterator to loop over the input/output variable configuration. More... | |
struct | Dummy |
struct | ValueIterator |
Public Types | |
enum | LoopStatus { kStop, kNext, kReset, kSkip } |
typedef edmplugin::PluginFactory < Dummy *()> | PluginFactory |
Public Member Functions | |
void | configure (ConfigCtx &config) |
called from the discriminator computer to configure processor More... | |
void | deriv (double *input, int *conf, double *output, int *outConf, int *loop, unsigned int offset, unsigned int in, unsigned int out, std::vector< double > &deriv) const |
run the processor evaluation pass on this processor and compute derivatives More... | |
void | eval (double *input, int *conf, double *output, int *outConf, int *loop, unsigned int offset) const |
run the processor evaluation pass on this processor More... | |
virtual LoopStatus | loop (double *output, int *outConf, unsigned int nOutput, unsigned int &nOffset) const |
virtual | ~VarProcessor () |
Public Member Functions inherited from PhysicsTools::ProcessRegistry< Base_t, CalibBase_t, Parent_t >::Factory | |
template<> | |
VarProcessor * | create (const char *name, const Calibration::VarProcessor *calib, const MVAComputer *parent) |
template<> | |
TrainProcessor * | create (const char *, const AtomicId *, MVATrainer *) |
template<> | |
TrainProcessor * | create (const char *name, const AtomicId *id, MVATrainer *trainer) |
template<> | |
VarProcessor * | create (const char *, const Calibration::VarProcessor *, const MVAComputer *) |
Protected Types | |
typedef ProcessRegistry < VarProcessor, Calibration::VarProcessor, const MVAComputer > | Registry |
Protected Member Functions | |
virtual void | configure (ConfIterator iter, unsigned int n)=0 |
virtual configure method, implemented in actual processor More... | |
virtual ConfigCtx::Context * | configureLoop (ConfigCtx::Context *ctx, ConfigCtx::iterator begin, ConfigCtx::iterator cur, ConfigCtx::iterator end) |
virtual loop configure method More... | |
virtual std::vector< double > | deriv (ValueIterator iter, unsigned int n) const |
virtual derivative evaluation method, implemented in actual processor More... | |
virtual void | eval (ValueIterator iter, unsigned int n) const =0 |
virtual evaluation method, implemented in actual processor More... | |
VarProcessor (const char *name, const Calibration::VarProcessor *calib, const MVAComputer *computer) | |
Protected Attributes | |
const MVAComputer * | computer |
Private Attributes | |
BitSet | inputVars |
bit set to select the input variables to be passed to this processor More... | |
unsigned int | nInputVars |
Additional Inherited Members | |
Static Public Member Functions inherited from PhysicsTools::ProcessRegistry< Base_t, CalibBase_t, Parent_t >::Factory | |
static Base_t * | create (const char *name, const CalibBase_t *calib, Parent_t *parent=0) |
Common base class for variable processors.
This base class for variable processors manages the common interface to the global discriminator class and how the individual variable processors are interconnected.
Definition at line 39 of file VarProcessor.h.
Definition at line 120 of file VarProcessor.h.
|
protected |
Definition at line 275 of file VarProcessor.h.
|
virtual |
Definition at line 46 of file VarProcessor.cc.
References inputVars, and nInputVars.
|
protected |
Definition at line 37 of file VarProcessor.cc.
void PhysicsTools::VarProcessor::configure | ( | ConfigCtx & | config | ) |
called from the discriminator computer to configure processor
Definition at line 52 of file VarProcessor.cc.
References PhysicsTools::VarProcessor::ConfigCtx::begin(), cmsDriver::config, configureLoop(), PhysicsTools::VarProcessor::ConfigCtx::ctx, PhysicsTools::VarProcessor::ConfigCtx::end(), inputVars, PhysicsTools::BitSet::iter(), PhysicsTools::VarProcessor::ConfigCtx::loop, loop(), nInputVars, pos, PhysicsTools::VarProcessor::ConfigCtx::size(), and PhysicsTools::BitSet::size().
Referenced by PhysicsTools::MVAComputer::setup().
|
protectedpure virtual |
virtual configure method, implemented in actual processor
Implemented in PhysicsTools::Interceptor.
|
protectedvirtual |
virtual loop configure method
Definition at line 86 of file VarProcessor.cc.
Referenced by configure().
void PhysicsTools::VarProcessor::deriv | ( | double * | input, |
int * | conf, | ||
double * | output, | ||
int * | outConf, | ||
int * | loop, | ||
unsigned int | offset, | ||
unsigned int | in, | ||
unsigned int | out, | ||
std::vector< double > & | deriv | ||
) | const |
run the processor evaluation pass on this processor and compute derivatives
Definition at line 120 of file VarProcessor.cc.
References begin, dbtoconf::conf, gather_cfg::cout, end, eval(), i, recoMuon::in, collect_tpl::input, inputVars, PhysicsTools::BitSet::iter(), j, gen::k, loop(), m, n, nInputVars, evf::evtn::offset(), dbtoconf::out, convertSQLitetoXML_cfg::output, L1TEmulatorMonitor_cff::p, pos, lumiQueryAPI::q, and findQualityFiles::size.
Referenced by PhysicsTools::MVAComputer::DerivContext::eval().
|
inlineprotectedvirtual |
virtual derivative evaluation method, implemented in actual processor
Definition at line 292 of file VarProcessor.h.
|
inline |
run the processor evaluation pass on this processor
Definition at line 99 of file VarProcessor.h.
References dbtoconf::conf, collect_tpl::input, inputVars, PhysicsTools::BitSet::iter(), loop(), nInputVars, evf::evtn::offset(), and convertSQLitetoXML_cfg::output.
Referenced by deriv(), and PhysicsTools::MVAComputer::EvalContext::eval().
|
protectedpure virtual |
virtual evaluation method, implemented in actual processor
Implemented in PhysicsTools::Interceptor.
|
inlinevirtual |
Definition at line 114 of file VarProcessor.h.
References kStop.
Referenced by configure(), deriv(), and eval().
|
protected |
Definition at line 297 of file VarProcessor.h.
Referenced by PhysicsTools::Interceptor::configure().
|
private |
bit set to select the input variables to be passed to this processor
Definition at line 301 of file VarProcessor.h.
Referenced by configure(), deriv(), eval(), and ~VarProcessor().
|
private |
Definition at line 302 of file VarProcessor.h.
Referenced by configure(), deriv(), eval(), and ~VarProcessor().