|
|
Go to the documentation of this file.
42 using std::stable_sort;
54 : _zvertex(0), _isMC(
false), _runnum(runnum), _evnum(evnum), _dlb(-1), _dnn(-1) {}
384 _leps[
i].smear(engine, smear_dir);
389 _jets[
i].smear(engine, smear_dir);
404 std::stable_sort(
_leps.begin(),
_leps.end(), std::not_fn(std::less<Lepjets_Event_Lep>()));
405 std::stable_sort(
_jets.begin(),
_jets.end(), std::not_fn(std::less<Lepjets_Event_Lep>()));
413 std::vector<int>
ret;
426 if (
_jets.size() != _jet_types.size()) {
429 bool saw_hadw1 =
false;
431 int t = _jet_types[
i];
444 struct Lepjets_Event_Cutter
449 Lepjets_Event_Cutter(
double pt_cut,
double eta_cut) :
_pt_cut(pt_cut),
_eta_cut(eta_cut) {}
450 bool operator()(
const Lepjets_Event_Lep&
l)
const;
455 bool Lepjets_Event_Cutter::operator()(
const Lepjets_Event_Lep&
l)
const
477 _leps.erase(remove_if(
_leps.begin(),
_leps.end(), Lepjets_Event_Cutter(pt_cut, eta_cut)),
_leps.end());
493 _jets.erase(remove_if(
_jets.begin(),
_jets.end(), Lepjets_Event_Cutter(pt_cut, eta_cut)),
_jets.end());
522 s <<
"Run: " << _runnum <<
" Event: " << _evnum <<
"\n";
535 s <<
"Missing Et: " << _met <<
"\n";
537 s <<
"z-vertex: " << _zvertex <<
"\n";
ret
prodAgent to be discontinued
std::vector< int > jet_types() const
Return the jet types in the event.
CLHEP::HepLorentzVector Fourvec
Typedef for a HepLorentzVector.
std::string jet_permutation() const
Return a string representing the jet permutation. The following notation is used for each type of jet...
const int & runnum() const
Return a constant reference to the run number.
void trimjets(std::vector< Lepjets_Event_Jet >::size_type n)
Remove all but the first n jets.
Lepjets_Event_Lep & lep(std::vector< Lepjets_Event_Lep >::size_type i)
Return a reference to lepton at index position i.
const int & evnum() const
Return a constant reference to the event number.
Lepjets_Event(int runnum, int evnum)
Constructor.
std::vector< Lepjets_Event_Lep > _leps
Represent a simple event consisting of lepton(s) and jet(s).
Fourvec & met()
Return a reference to the missing transverse energy.
std::vector< Lepjets_Event_Jet >::size_type njets() const
Return the number of jets in the event.
Represent a simple event consisting of lepton(s) and jet(s). An instance of this class holds a list o...
bool isMC() const
Return the Monte Carlo flag.
A class to represent a jet in an instance of Lepjets_Event class. The class is derived from the Lepje...
Fourvec sum(int type) const
Return the sum of all objects' four-momentum which have a particular type.
int cut_jets(double pt_cut, double eta_cut)
Remove jets which fail transverse momentum and pseudorapidity cut.
std::ostream & operator<<(std::ostream &s, const Constraint_Intermed &ci)
Output stream operator, print the content of this Constraint_Intermed to an output stream.
void add_jet(const Lepjets_Event_Jet &jet)
Add a new jet to the event.
int cut_leps(double pt_cut, double eta_cut)
Remove leptons which fail transverse momentum and pseudorapidity cut.
bool set_jet_types(const std::vector< int > &)
Set the jet types in the event.
std::vector< Lepjets_Event_Jet > _jets
std::string jetTypeString(int type)
Helper function: Translate jet type code from integer to char. The following notation is used for eac...
int & type()
Return a reference to the type code.
std::ostream & dump(std::ostream &s, bool full=false) const
Print the content of this object.
void smear(CLHEP::HepRandomEngine &engine, bool smear_dir=false)
Smear the objects in the event according to their resolutions.
Lepjets_Event_Jet & jet(std::vector< Lepjets_Event_Jet >::size_type i)
Return a reference to jet at index position i.
void sort()
Sort objects in the event according to their transverse momentum .
double & dlb()
Return a reference to the value of low-bias (LB) discriminant (Irrelevant for non-D0 experiment).
double pick(double x, double p, CLHEP::HepRandomEngine &engine) const
Generate random value from a Gaussian distribution described by this resolution. Given a value ,...
double zvertex() const
Return the value of z-vertex.
double & dnn()
Return a reference to the value of neural network (NN) discriminant (Irrelevant for non-D0 experiment...
Resolution & kt_res()
Return a reference to the resolution.
Fourvec kt() const
Return the sum of all objects' four-momentum and missing transverse energy.
void setMC(bool isMC)
Set the Monte Carlo flag.
std::vector< Lepjets_Event_Lep >::size_type nleps() const
Return the number of leptons in the event.
Abs< T >::type abs(const T &t)
void add_lep(const Lepjets_Event_Lep &lep)
Add a new lepton to the event.
Represent a lepton in an instance of Lepjets_Event class. This class hold the following information: