Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PurgeDuplicates test-vectors (11_3_X) #70

Merged
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
13 changes: 13 additions & 0 deletions L1Trigger/TrackFindingTracklet/interface/Settings.h
Original file line number Diff line number Diff line change
Expand Up @@ -248,6 +248,13 @@ namespace trklet {
unsigned int nbitstrackletindex() const { return nbitstrackletindex_; }
void setNbitstrackletindex(unsigned int nbitstrackletindex) { nbitstrackletindex_ = nbitstrackletindex; }

unsigned int nbitsitc() const { return nbitsitc_; }
unsigned int nbitsseed() const { return (extended_ ? nbitsseedextended_ : nbitsseed_); }
unsigned int nbitstcindex() const { return nbitsseed() + nbitsitc(); }
void setNbitsitc(unsigned int nbitsitc) { nbitsitc_ = nbitsitc; }
void setNbitsseed(unsigned int nbitsseed) { nbitsseed_ = nbitsseed; }
void setNbitsseedextended(unsigned int nbitsseed) { nbitsseedextended_ = nbitsseed; }

double dphisectorHG() const {
return 2 * M_PI / N_SECTOR +
2 * std::max(std::abs(asin(0.5 * rinvmax() * rmean(0)) - asin(0.5 * rinvmax() * rcrit_)),
Expand Down Expand Up @@ -450,6 +457,12 @@ namespace trklet {

unsigned int nbitstrackletindex_{7}; //Bits used to store the tracklet index

unsigned int nbitsitc_{4}; //Bits used to store the iTC, a unique
//identifier assigned to each TC within a sector
unsigned int nbitsseed_{3}; //Bits used to store the seed number
unsigned int nbitsseedextended_{4}; //Bits used to store the seed number
//in the extended project

//Bits used to store track parameter in tracklet
int nbitsrinv_{14};
int nbitsphi0_{18};
Expand Down
12 changes: 9 additions & 3 deletions L1Trigger/TrackFindingTracklet/interface/Tracklet.h
Original file line number Diff line number Diff line change
Expand Up @@ -470,7 +470,9 @@ namespace trklet {
int hitpattern,
const std::vector<const L1TStub*>& l1stubs = std::vector<const L1TStub*>());

std::string trackfitstr();
const std::string layerstubstr(const unsigned layer) const;
const std::string diskstubstr(const unsigned disk) const;
std::string trackfitstr() const;

Track makeTrack(const std::vector<const L1TStub*>& l1stubs);

Expand Down Expand Up @@ -499,8 +501,11 @@ namespace trklet {

int TCID() const { return TCIndex_ * (1 << settings_.nbitstrackletindex()) + trackletIndex_; }

int getISeed() const;
int getITC() const;
const int getISeed() const;
const int getITC() const;

void setTrackIndex(int index);
const int trackIndex() const;

unsigned int PSseed() const { return ((layer() == 1) || (layer() == 2) || (disk() != 0)) ? 1 : 0; }

Expand All @@ -527,6 +532,7 @@ namespace trklet {

int trackletIndex_;
int TCIndex_;
int trackIndex_;

//Tracklet track parameters
TrackPars<FPGAWord> fpgapars_;
Expand Down
2 changes: 2 additions & 0 deletions L1Trigger/TrackFindingTracklet/src/FitTrack.cc
Original file line number Diff line number Diff line change
Expand Up @@ -996,6 +996,7 @@ void FitTrack::execute() {
if (settings_.removalType() == "merge") {
trackfit_->addStubList(trackstublist);
trackfit_->addStubidsList(stubidslist);
bestTracklet->setTrackIndex(trackfit_->nTracks());
trackfit_->addTrack(bestTracklet);
} else if (bestTracklet->fit()) {
assert(trackfit_ != nullptr);
Expand All @@ -1005,6 +1006,7 @@ void FitTrack::execute() {
<< endl;
fout.close();
}
bestTracklet->setTrackIndex(trackfit_->nTracks());
trackfit_->addTrack(bestTracklet);
}
}
Expand Down