Skip to content
Snippets Groups Projects
Commit 50cbc0b9 authored by Margherita Spalla's avatar Margherita Spalla
Browse files

adding E/sigma upper limit

parent 3bbaf308
No related branches found
No related tags found
No related merge requests found
......@@ -365,6 +365,8 @@ class CaloClusterTopoGetter ( Configured ) :
#timing
TopoMaker.SeedCutsInT = jobproperties.CaloTopoClusterFlags.doTimeCut()
TopoMaker.CutOOTseed = jobproperties.CaloTopoClusterFlags.extendTimeCut() and jobproperties.CaloTopoClusterFlags.doTimeCut()
TopoMaker.UseTimeCutUpperLimit = jobproperties.CaloTopoClusterFlags.useUpperLimitForTimeCut()
TopoMaker.TimeCutUpperLimit = 20.0
# note E or AbsE
#
......
......@@ -125,6 +125,12 @@ class extendTimeCut(JobProperty):
allowedTypes=['bool']
StoredValue=False
class useUpperLimitForTimeCut(JobProperty):
"""
"""
statusOn=True
allowedTypes=['bool']
StoredValue=False
# add the flags container to the top container
jobproperties.add_Container(CaloTopoClusterFlags)
......@@ -148,6 +154,7 @@ list_jobproperties = [
,doMomentsfromAbs
,doTimeCut
,extendTimeCut
,useUpperLimitForTimeCut
]
for i in list_jobproperties:
......
......@@ -62,6 +62,7 @@ CaloTopoClusterMaker::CaloTopoClusterMaker(const std::string& type,
m_neighborThresholdOnEorAbsEinSigma( 3.),
m_seedThresholdOnEorAbsEinSigma ( 6.),
m_seedThresholdOnTAbs ( 12.5*ns),
m_timeCutUpperLimit ( 20.),
m_neighborOption ("super3D"),
m_nOption (LArNeighbours::super3D),
m_restrictHECIWandFCalNeighbors (false),
......@@ -74,6 +75,7 @@ CaloTopoClusterMaker::CaloTopoClusterMaker(const std::string& type,
m_treatL1PredictedCellsAsGood (true),
m_seedCutsInT (false),
m_cutOOTseed (false),
m_useTimeCutUpperLimit (false),
m_minSampling (0),
m_maxSampling (0),
m_hashMin (999999),
......@@ -104,11 +106,15 @@ CaloTopoClusterMaker::CaloTopoClusterMaker(const std::string& type,
// Time thresholds (in abs. val.)
declareProperty("SeedThresholdOnTAbs",m_seedThresholdOnTAbs);
// Significance upper limit for applying time cut
declareProperty("TimeCutUpperLimit",m_timeCutUpperLimit);
//do Seed cuts on Time
declareProperty("SeedCutsInT",m_seedCutsInT);
//exclude out-of-time seeds from neighbouring and cell stage
declareProperty("CutOOTseed",m_cutOOTseed);
//do not apply time cut on cells of large significance
declareProperty("UseTimeCutUpperLimit",m_useTimeCutUpperLimit);
// Neighbor cuts are in E or Abs E
declareProperty("NeighborCutsInAbsE",m_neighborCutsInAbsE);
......@@ -381,7 +387,8 @@ CaloTopoClusterMaker::execute(const EventContext& ctx,
bool passedNeighborCut = (m_neighborCutsInAbsE?std::abs(signedRatio):signedRatio) > m_neighborThresholdOnEorAbsEinSigma;
bool passedSeedCut = (m_seedCutsInAbsE?std::abs(signedRatio):signedRatio) > m_seedThresholdOnEorAbsEinSigma;
bool passTimeCut_seedCell = (!m_seedCutsInT || passCellTimeCut(pCell,m_seedThresholdOnTAbs));
bool applyTimeCut = m_seedCutsInT && !(m_useTimeCutUpperLimit && signedRatio > m_timeCutUpperLimit);
bool passTimeCut_seedCell = (!applyTimeCut || passCellTimeCut(pCell,m_seedThresholdOnTAbs));
bool passedSeedAndTimeCut = (passedSeedCut && passTimeCut_seedCell);
bool passedNeighborAndTimeCut = passedNeighborCut;
......
......@@ -134,6 +134,9 @@ private:
* threshold used for timing cut on seed cells. Implemented as |seed_cell_time|<m_seedThresholdOnTAbs. No such cut on neighbouring cells.*/
float m_seedThresholdOnTAbs;
/**
* upper limit on the energy significance, for applying the cell time cut */
float m_timeCutUpperLimit;
/** @brief Key of the CaloNoise Conditions data object. Typical values
......@@ -245,6 +248,11 @@ private:
*/
bool m_cutOOTseed;
/**
* if set to true, the time cut is not applied on cell of large significance
*/
bool m_useTimeCutUpperLimit;
/**
* @brief vector of names of the calorimeter samplings to consider
* for seeds.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment