Skip to content

Commit

Permalink
Add more MuonCollider specific fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
tmadlener committed Nov 27, 2024
1 parent 0ace7ba commit eda2f60
Show file tree
Hide file tree
Showing 11 changed files with 35 additions and 25 deletions.
8 changes: 4 additions & 4 deletions source/Refitting/include/RefitFinal.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ class RefitFinal : public marlin::Processor {

/// Nhits cut struct
struct NHitsCut{
std::vector<int> detIDs ; // list of detectors IDs from which hits will be summed
int nHits_min ; // minimum number of hits
std::vector<int> detIDs {} ; // list of detectors IDs from which hits will be summed
int nHits_min {}; // minimum number of hits
};

public:
Expand Down Expand Up @@ -79,8 +79,8 @@ class RefitFinal : public marlin::Processor {
bool _MSOn = true;
bool _ElossOn = true;

StringVec _NHitsCutsStr ;
std::vector<NHitsCut> _NHitsCuts ;
StringVec _NHitsCutsStr {};
std::vector<NHitsCut> _NHitsCuts {};
double _ReducedChi2Cut = -1.0;

bool _SmoothOn = false;
Expand Down
4 changes: 2 additions & 2 deletions source/Utils/include/FilterClusters.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,10 @@ class FilterClusters : public marlin::Processor
std::string _OutRelationCollection {};

//! Ranges for theta
std::vector<std::string> _ThetaRanges;
std::vector<std::string> _ThetaRanges {};

//! Cut-offs for cluster size in various theta ranges
std::vector<std::string> _ClusterSize;
std::vector<std::string> _ClusterSize {};

//! Layers to be filtered
std::vector<std::string> _Layers;
Expand Down
2 changes: 2 additions & 0 deletions source/Utils/include/FilterConeHits.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ class FilterConeHits : public Processor {


FilterConeHits() ;
FilterConeHits(const FilterConeHits&) = delete;
FilterConeHits& operator=(const FilterConeHits&) = delete;

virtual void init() ;

Expand Down
26 changes: 14 additions & 12 deletions source/Utils/include/FilterDoubleLayerHits.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@ class FilterDoubleLayerHits : public Processor {


FilterDoubleLayerHits() ;
FilterDoubleLayerHits(const FilterDoubleLayerHits) = delete ;
FilterDoubleLayerHits& operator=(const FilterDoubleLayerHits) = delete ;

virtual const std::string & name() const { return Processor::name() ; }

Expand Down Expand Up @@ -92,40 +94,40 @@ class FilterDoubleLayerHits : public Processor {
dd4hep::rec::Vector2D globalToLocal(long int cellID, const dd4hep::rec::Vector3D& posGlobal, dd4hep::rec::ISurface** surf) ;

////Input collection name.
std::string _inColName ;
std::string _inColName {};

////Output collection name.
std::string _outColName ;
std::string _outColName {};

////Maximum time difference between hits in a doublet
double _dtMax ;
double _dtMax {};

////Double layer cuts configuration
StringVec _dlCutConfigs ;
StringVec _dlCutConfigs {};

////Whether to fill diagnostic histograms
bool _fillHistos ;
bool _fillHistos {false};

////Subdetector name (needed to get the sensor surface manager)
std::string _subDetName ;
std::string _subDetName {};

std::vector<DoubleLayerCut> _dlCuts ;
std::vector<DoubleLayerCut> _dlCuts {};

////Surface map for getting local hit positions at sensor surface
const dd4hep::rec::SurfaceMap* _map ;
const dd4hep::rec::SurfaceMap* _map {nullptr};


////Array of flags for hits to be accepted
bool _hitAccepted[NHITS_MAX] ;

////Map of vectors of hits grouped by position in the detector
std::map<SensorPosition, std::vector<size_t> > _hitsGrouped;
std::map<SensorPosition, std::vector<size_t> > _hitsGrouped{};

////Monitoring histograms
std::map<std::string, TH1*> _histos ;
std::map<std::string, TH1*> _histos {};

int _nRun ;
int _nEvt ;
int _nRun {};
int _nEvt {};
} ;

#endif
Expand Down
2 changes: 2 additions & 0 deletions source/Utils/include/FilterTimeHits.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ class FilterTimeHits : public Processor
virtual Processor *newProcessor() { return new FilterTimeHits; }

FilterTimeHits();
FilterTimeHits(const FilterTimeHits&) = delete;
FilterTimeHits& operator=(const FilterTimeHits&) = delete;

virtual void init();

Expand Down
3 changes: 3 additions & 0 deletions source/Utils/include/SplitCollectionByLayer.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,9 @@ class SplitCollectionByLayer : public Processor {

///helper struct
struct OutColInfo{
OutColInfo(const OutColInfo&) = delete;
OutColInfo& operator=(const OutColInfo&) = delete;

std::vector<size_t> layers{} ;
LCCollection* collection{nullptr};
OutColInfo() : layers(std::vector<size_t>(0)), collection(nullptr) {}
Expand Down
2 changes: 2 additions & 0 deletions source/Utils/include/SplitCollectionByPolarAngle.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ class SplitCollectionByPolarAngle : public Processor {


SplitCollectionByPolarAngle() ;
SplitCollectionByPolarAngle(const SplitCollectionByPolarAngle&) = delete ;
SplitCollectionByPolarAngle& operator=(const SplitCollectionByPolarAngle&) = delete ;

virtual void init() ;

Expand Down
1 change: 0 additions & 1 deletion source/Utils/src/FilterClusters.cc
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,6 @@ void FilterClusters::processEvent( LCEvent * evt )
//Get hit subdetector/layer
std::string _encoderString = lcio::LCTrackerCellID::encoding_string();
UTIL::CellIDDecoder<lcio::TrackerHit> decoder(_encoderString);
uint32_t systemID = decoder(trkhit)["system"];
uint32_t layerID = decoder(trkhit)["layer"];
bool filter_layer = false;
for (size_t j=0; j<_Layers.size(); ++j){
Expand Down
4 changes: 2 additions & 2 deletions source/Utils/src/FilterConeHits.cc
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ void FilterConeHits::init() {
}


void FilterConeHits::processRunHeader( LCRunHeader* run) {
void FilterConeHits::processRunHeader( LCRunHeader* ) {

_nRun++ ;

Expand Down Expand Up @@ -391,7 +391,7 @@ void FilterConeHits::processEvent( LCEvent * evt ) {



void FilterConeHits::check( LCEvent * evt ) {
void FilterConeHits::check( LCEvent * ) {
}


Expand Down
4 changes: 2 additions & 2 deletions source/Utils/src/FilterTimeHits.cc
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ void FilterTimeHits::init()
m_corrected_time = new TH1F("m_corrected_time", "Corrected time of the hit [ps]", 1000, -250., 250.);
}

void FilterTimeHits::processRunHeader(LCRunHeader *run)
void FilterTimeHits::processRunHeader(LCRunHeader *)
{
_nRun++;
}
Expand Down Expand Up @@ -326,7 +326,7 @@ void FilterTimeHits::processEvent(LCEvent *evt)
_nEvt++;
}

void FilterTimeHits::check(LCEvent *evt)
void FilterTimeHits::check(LCEvent *)
{
}

Expand Down
4 changes: 2 additions & 2 deletions source/Utils/src/SplitCollectionByPolarAngle.cc
Original file line number Diff line number Diff line change
Expand Up @@ -108,15 +108,15 @@ void SplitCollectionByPolarAngle::init() {
}


void SplitCollectionByPolarAngle::processRunHeader( LCRunHeader* run) {
void SplitCollectionByPolarAngle::processRunHeader( LCRunHeader* ) {

_nRun++ ;

}



void SplitCollectionByPolarAngle::processEvent( LCEvent * evt ) {
void SplitCollectionByPolarAngle::processEvent( LCEvent * ) {

// --- Check whether the number of input and output collections match

Expand Down

0 comments on commit eda2f60

Please sign in to comment.