52 METProducer::METProducer(
const edm::ParameterSet& iConfig) : alg_() , resolutions_(0), tcmetalgorithm(0)
61 if( METtype ==
"CaloMET" )
64 produces<CaloMETCollection>().setBranchAlias(alias.c_str());
65 calculateSignificance_ = iConfig.
getParameter<
bool>(
"calculateSignificance");
67 else if( METtype ==
"GenMET" )
71 produces<GenMETCollection>().setBranchAlias(alias.c_str());
73 else if( METtype ==
"PFMET" )
75 produces<PFMETCollection>().setBranchAlias(alias.c_str());
77 calculateSignificance_ = iConfig.
getParameter<
bool>(
"calculateSignificance");
79 if(calculateSignificance_){
84 else if( METtype ==
"PFClusterMET" )
86 produces<PFClusterMETCollection>().setBranchAlias(alias.c_str());
88 else if (METtype ==
"TCMET" )
90 produces<METCollection>().setBranchAlias(alias.c_str());
93 bool correctShowerTracks_ = iConfig.
getParameter<
bool>(
"correctShowerTracks");
95 if(correctShowerTracks_){
104 else if( rfType_ == 2 ){
113 produces<METCollection>().setBranchAlias(alias.c_str());
115 if (calculateSignificance_ && ( METtype ==
"CaloMET" || METtype ==
"PFMET")){
128 produces<METCollection>();
188 std::auto_ptr<CaloMETCollection> calometcoll;
190 calometcoll->push_back( calomet ) ;
191 event.put( calometcoll );
197 std::auto_ptr<METCollection> tcmetcoll;
200 event.put( tcmetcoll );
207 std::auto_ptr<PFMETCollection> pfmetcoll;
218 pfmetcoll->push_back( pf.
addInfo(input, output) );
219 event.put( pfmetcoll );
222 else if(
METtype ==
"PFClusterMET" )
226 std::auto_ptr<PFClusterMETCollection> pfclustermetcoll;
229 pfclustermetcoll->push_back( pfcluster.
addInfo(input, output) );
230 event.put( pfclustermetcoll );
236 std::auto_ptr<GenMETCollection> genmetcoll;
239 event.put( genmetcoll );
247 std::auto_ptr<METCollection> metcoll;
249 metcoll->push_back( met );
250 event.put( metcoll );
T getParameter(std::string const &) const
T getUntrackedParameter(std::string const &, T const &) const
bool calculateSignificance_
reco::PFClusterMET addInfo(edm::Handle< edm::View< reco::Candidate > > PFClusterCandidates, CommonMETData met)
reco::GenMET addInfo(edm::Handle< edm::View< reco::Candidate > > particles, CommonMETData *met, double globalThreshold, bool onlyFiducial=false, bool usePt=false)
Make GenMET. Assumes MET is made from MCCandidates.
virtual void produce(edm::Event &, const edm::EventSetup &)
void calculateBaseCaloMET(edm::Handle< edm::View< reco::Candidate > > towers, CommonMETData met, const metsig::SignAlgoResolutions &resolutions, bool noHF, double globalthreshold)
Structure containing data common to all types of MET.
void setSignificanceMatrix(const TMatrixD &matrix)
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
TCMETAlgo * tcmetalgorithm
reco::CaloMET addInfo(edm::Handle< edm::View< reco::Candidate > > towers, CommonMETData met, bool noHF, double globalThreshold)
Make CaloMET. Assumes MET is made from CaloTowerCandidates.
int myResponseFunctionType
TMatrixD getSignificanceMatrix() const
Collection of PFCluster MET.
metsig::SignAlgoResolutions * resolutions_
math::XYZTLorentzVector LorentzVector
reco::PFMET addInfo(edm::Handle< edm::View< reco::Candidate > > PFCandidates, CommonMETData met)
void runSignificance(metsig::SignAlgoResolutions &resolutions, edm::Handle< edm::View< reco::PFJet > > jets)
void setup(std::vector< TH2F > &depth, std::string name, std::string units="")
void SetMetSignificance(double metsig)