CMS 3D CMS Logo

List of all members | Public Member Functions | Private Types | Private Attributes
RPCSeedFinder Class Reference

#include <RPCSeedFinder.h>

Public Member Functions

void configure (const edm::ParameterSet &iConfig)
 
 RPCSeedFinder ()
 
void seed ()
 
void setEventSetup (const edm::EventSetup &iSetup)
 
void setOutput (std::vector< weightedTrajectorySeed > *goodweightedRef, std::vector< weightedTrajectorySeed > *candidateweightedRef)
 
void setrecHits (ConstMuonRecHitContainer &recHits)
 
 ~RPCSeedFinder ()
 

Private Types

typedef MuonTransientTrackingRecHit::ConstMuonRecHitContainer ConstMuonRecHitContainer
 
typedef MuonTransientTrackingRecHit::ConstMuonRecHitPointer ConstMuonRecHitPointer
 
typedef MuonTransientTrackingRecHit::MuonRecHitContainer MuonRecHitContainer
 
typedef MuonTransientTrackingRecHit::MuonRecHitPointer MuonRecHitPointer
 
typedef RPCSeedPattern::weightedTrajectorySeed weightedTrajectorySeed
 

Private Attributes

std::vector< weightedTrajectorySeed > * candidateweightedSeedsRef
 
const edm::EventSetupeSetup
 
std::vector< weightedTrajectorySeed > * goodweightedSeedsRef
 
bool isConfigured
 
bool isEventSetupset
 
bool isOutputset
 
bool isrecHitsset
 
RPCSeedPattern oneSeed
 

Detailed Description

Author
Haiyun.Teng - Peking University

Definition at line 23 of file RPCSeedFinder.h.

Member Typedef Documentation

◆ ConstMuonRecHitContainer

Definition at line 27 of file RPCSeedFinder.h.

◆ ConstMuonRecHitPointer

Definition at line 25 of file RPCSeedFinder.h.

◆ MuonRecHitContainer

Definition at line 26 of file RPCSeedFinder.h.

◆ MuonRecHitPointer

Definition at line 24 of file RPCSeedFinder.h.

◆ weightedTrajectorySeed

Definition at line 28 of file RPCSeedFinder.h.

Constructor & Destructor Documentation

◆ RPCSeedFinder()

RPCSeedFinder::RPCSeedFinder ( )

Definition at line 12 of file RPCSeedFinder.cc.

12  {
13  // Initiate the member
14  isrecHitsset = false;
15  isConfigured = false;
16  isOutputset = false;
17  isEventSetupset = false;
18  oneSeed.clear();
19 }

◆ ~RPCSeedFinder()

RPCSeedFinder::~RPCSeedFinder ( )

Definition at line 21 of file RPCSeedFinder.cc.

21 {}

Member Function Documentation

◆ configure()

void RPCSeedFinder::configure ( const edm::ParameterSet iConfig)

Definition at line 23 of file RPCSeedFinder.cc.

23  {
24  oneSeed.configure(iConfig);
25  isConfigured = true;
26 }

◆ seed()

void RPCSeedFinder::seed ( )

Definition at line 47 of file RPCSeedFinder.cc.

47  {
48  cout << "[RPCSeedFinder] --> seeds called" << endl;
49 
50  if (isrecHitsset == false || isOutputset == false || isConfigured == false || isEventSetupset == false) {
51  cout << "Configuration or IO is not set yet" << endl;
52  return;
53  }
54 
55  weightedTrajectorySeed theweightedSeed;
56  int isGoodSeed = 0;
57  const edm::EventSetup &iSetup = *eSetup;
58  theweightedSeed = oneSeed.seed(iSetup, isGoodSeed);
59  // Push back the good seed
60  if (isGoodSeed == 1) {
61  cout << "[RPCSeedFinder] --> Seeds from " << oneSeed.nrhit() << " recHits." << endl;
62  goodweightedSeedsRef->push_back(theweightedSeed);
63  }
64  // Push back cadidate seed but not the fake seed
65  if (isGoodSeed >= 0) {
66  candidateweightedSeedsRef->push_back(theweightedSeed);
67  }
68 
69  // Unset the signal
70  oneSeed.clear();
71  isrecHitsset = false;
72 }

References gather_cfg::cout.

◆ setEventSetup()

void RPCSeedFinder::setEventSetup ( const edm::EventSetup iSetup)

Definition at line 42 of file RPCSeedFinder.cc.

42  {
43  eSetup = &iSetup;
44  isEventSetupset = true;
45 }

◆ setOutput()

void RPCSeedFinder::setOutput ( std::vector< weightedTrajectorySeed > *  goodweightedRef,
std::vector< weightedTrajectorySeed > *  candidateweightedRef 
)

Definition at line 28 of file RPCSeedFinder.cc.

29  {
30  goodweightedSeedsRef = goodweightedRef;
31  candidateweightedSeedsRef = candidateweightedRef;
32  isOutputset = true;
33 }

◆ setrecHits()

void RPCSeedFinder::setrecHits ( ConstMuonRecHitContainer recHits)

Definition at line 35 of file RPCSeedFinder.cc.

35  {
36  oneSeed.clear();
37  for (ConstMuonRecHitContainer::const_iterator iter = recHits.begin(); iter != recHits.end(); iter++)
38  oneSeed.add(*iter);
39  isrecHitsset = true;
40 }

References FastTrackerRecHitMaskProducer_cfi::recHits.

Member Data Documentation

◆ candidateweightedSeedsRef

std::vector<weightedTrajectorySeed>* RPCSeedFinder::candidateweightedSeedsRef
private

Definition at line 50 of file RPCSeedFinder.h.

◆ eSetup

const edm::EventSetup* RPCSeedFinder::eSetup
private

Definition at line 46 of file RPCSeedFinder.h.

◆ goodweightedSeedsRef

std::vector<weightedTrajectorySeed>* RPCSeedFinder::goodweightedSeedsRef
private

Definition at line 49 of file RPCSeedFinder.h.

◆ isConfigured

bool RPCSeedFinder::isConfigured
private

◆ isEventSetupset

bool RPCSeedFinder::isEventSetupset
private

Definition at line 45 of file RPCSeedFinder.h.

◆ isOutputset

bool RPCSeedFinder::isOutputset
private

◆ isrecHitsset

bool RPCSeedFinder::isrecHitsset
private

Definition at line 42 of file RPCSeedFinder.h.

◆ oneSeed

RPCSeedPattern RPCSeedFinder::oneSeed
private

Definition at line 47 of file RPCSeedFinder.h.

RPCSeedFinder::isrecHitsset
bool isrecHitsset
Definition: RPCSeedFinder.h:42
RPCSeedFinder::oneSeed
RPCSeedPattern oneSeed
Definition: RPCSeedFinder.h:47
gather_cfg.cout
cout
Definition: gather_cfg.py:144
RPCSeedFinder::isEventSetupset
bool isEventSetupset
Definition: RPCSeedFinder.h:45
RPCSeedFinder::candidateweightedSeedsRef
std::vector< weightedTrajectorySeed > * candidateweightedSeedsRef
Definition: RPCSeedFinder.h:50
RPCSeedFinder::isOutputset
bool isOutputset
Definition: RPCSeedFinder.h:44
RPCSeedFinder::goodweightedSeedsRef
std::vector< weightedTrajectorySeed > * goodweightedSeedsRef
Definition: RPCSeedFinder.h:49
RPCSeedPattern::add
void add(const ConstMuonRecHitPointer &hit)
Definition: RPCSeedPattern.h:43
FastTrackerRecHitMaskProducer_cfi.recHits
recHits
Definition: FastTrackerRecHitMaskProducer_cfi.py:8
RPCSeedPattern::nrhit
unsigned int nrhit() const
Definition: RPCSeedPattern.h:44
RPCSeedFinder::eSetup
const edm::EventSetup * eSetup
Definition: RPCSeedFinder.h:46
RPCSeedPattern::seed
weightedTrajectorySeed seed(const edm::EventSetup &eSetup, int &isGoodSeed)
Definition: RPCSeedPattern.cc:53
edm::EventSetup
Definition: EventSetup.h:57
weightedTrajectorySeed
RPCSeedPattern::weightedTrajectorySeed weightedTrajectorySeed
Definition: RPCSeedGenerator.cc:65
RPCSeedPattern::clear
void clear()
Definition: RPCSeedPattern.h:42
RPCSeedFinder::isConfigured
bool isConfigured
Definition: RPCSeedFinder.h:43
RPCSeedPattern::configure
void configure(const edm::ParameterSet &iConfig)
Definition: RPCSeedPattern.cc:40