20 : mJets (fConfig.getParameter<edm::InputTag> (
"jets")),
21 mTracks (fConfig.getParameter<edm::InputTag> (
"tracks")),
22 mAssociator (fConfig.getParameter<double> (
"coneSize")),
23 mAssociatorAssigned (fConfig.getParameter<double> (
"coneSize")),
24 useAssigned(
false), pvSrc()
27 if ( fConfig.
exists(
"useAssigned") ) {
32 produces<reco::JetTracksAssociation::Container> ();
46 std::vector <edm::RefToBase<reco::Jet> >
allJets;
47 allJets.reserve (jets_h->size());
48 for (
unsigned i = 0;
i < jets_h->size(); ++
i) allJets.push_back (jets_h->refAt(
i));
50 allTracks.reserve (tracks_h->size());
52 for (
unsigned i = 0;
i < tracks_h->size(); ++
i) {
66 fEvent.
put (jetTracks);
std::vector< reco::JetBaseRef > allJets(const Container &)
fill list of all jets associated with values. Return # of jets in the list
T getParameter(std::string const &) const
bool exists(std::string const ¶meterName) const
checks if a parameter exists
std::vector< Vertex > VertexCollection
collection of Vertex objects
JetTracksAssociatorAtVertex(const edm::ParameterSet &)
virtual void produce(edm::Event &, const edm::EventSetup &)
void produce(reco::JetTracksAssociation::Container *fAssociation, const std::vector< edm::RefToBase< reco::Jet > > &fJets, const std::vector< reco::TrackRef > &fTracks, const reco::VertexCollection &vertices) const
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
void produce(reco::JetTracksAssociation::Container *fAssociation, const std::vector< edm::RefToBase< reco::Jet > > &fJets, const std::vector< reco::TrackRef > &fTracks) const
edm::InputTag pvSrc
if true, use the track/jet association with vertex assignment to tracks
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
virtual ~JetTracksAssociatorAtVertex()
JetTracksAssociationDRVertexAssigned mAssociatorAssigned
JetTracksAssociationDRVertex mAssociator
T const * product() const