26 produces<edm::ValueMap<unsigned int> >().setBranchAlias(
"cosmicsVeto");
27 produces<edm::ValueMap<reco::MuonCosmicCompatibility> >().setBranchAlias(
"cosmicCompatibility");
44 std::vector<unsigned int>
values;
45 values.reserve(muons->size());
47 std::vector<reco::MuonCosmicCompatibility> compValues;
48 compValues.reserve(muons->size());
50 for(reco::MuonCollection::const_iterator
muon = muons->begin();
53 unsigned int foundPartner(0);
54 if (
muon->innerTrack().isNonnull() ){
65 values.push_back(foundPartner);
73 filler.
insert(muons, values.begin(), values.end());
79 fillerC.
insert(muons, compValues.begin(), compValues.end());
virtual void produce(edm::Event &, const edm::EventSetup &)
reco::TrackRef findOppositeTrack(const edm::Handle< reco::TrackCollection > &collection, const reco::Track &muon, double angleMatch=0.01, double momentumMatch=0.05)
#define DEFINE_FWK_MODULE(type)
void insert(const H &h, I begin, I end)
std::vector< edm::InputTag > inputTrackCollections_
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
edm::InputTag inputMuonCollection_
virtual ~CosmicsMuonIdProducer()
reco::MuonCosmicCompatibility fillCompatibility(const reco::Muon &muon, edm::Event &, const edm::EventSetup &)
fill cosmic compatibility variables
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
MuonCosmicCompatibilityFiller compatibilityFiller_
CosmicsMuonIdProducer(const edm::ParameterSet &iConfig)