#include <ClusterConeStrategy.h>
Public Methods | |
ClusterConeStrategy (double rConeBarrel, double rConeForward, double minInitiatorET, double minClusterET, bool masslessJets) | |
virtual void | makeClusters (MsgStream &log, const std::vector< IKinematic * > &storedCells, std::vector< IKinematic * > &unusedCells, ClusterCollection *clusters) const |
Private Methods | |
double | rCone () const |
Strategy for making clusters from cells. | |
Private Attributes | |
double | m_rConeBarrel |
R-cone size for summation of Cells within barrel region. | |
double | m_rConeForward |
R-cone size for summation of Cells within forward regions. | |
double | m_minInitiatorET |
Minimun eT needed for a Cell to initiate a new Cluster. | |
double | m_minClusterET |
Minimum eT which a candidate cluster must have to be retained. | |
bool | m_masslessJets |
KinematicHelper | m_kinehelp |
Help with common kinematic operations. | |
Cluster * | lnkCluster |
0..* output |
The strategy employed is to sum all Cells in a given R-cone around an initiator.
[Note: This might be more correctly called pre-jet formation as the R-cones are of jet size and therefore this algorithm does not really correspond to the normal notion of forming clusters from,say, adjacent energy deposits.]
Definition at line 63 of file ClusterConeStrategy.h.
|
Definition at line 67 of file ClusterConeStrategy.h. References m_masslessJets, m_minClusterET, m_minInitiatorET, m_rConeBarrel, and m_rConeForward.
00073 : 00074 m_rConeBarrel(rConeBarrel), 00075 m_rConeForward(rConeForward), 00076 m_minInitiatorET(minInitiatorET), 00077 m_minClusterET(minClusterET), 00078 m_masslessJets(masslessJets){} |
|
Definition at line 33 of file ClusterConeStrategy.cxx. References Atlfast::ClusterConeStrategy::PreCluster::eT(), Atlfast::localCellCollection, Atlfast::localCellIterator, m_masslessJets, m_minClusterET, m_minInitiatorET, and rCone().
00037 { 00038 log << MSG::DEBUG << storedCells.size() << "cells to start with"<<endreq; 00039 // The cell collection suppplied is not mutable as it contains items 00040 // (or pointers to items) in the TES. 00041 // Therefore we copy pointers to two local mutable collections as we want 00042 // to manipulate them as part of the clustering strategy 00043 00044 // This is to hold cells remaining available for cluster formation. 00045 localCellCollection availableCells(storedCells.begin(), 00046 storedCells.end() ); 00047 localCellIterator firstAvailableCell = availableCells.begin() ; 00048 localCellIterator lastAvailableCell = availableCells.end() ; 00049 00050 // This is to keep remaining candidate initiators. 00051 localCellCollection availableInitiators( storedCells.begin(), 00052 storedCells.end() ) ; 00053 localCellIterator firstAvailableInitiator = availableInitiators.begin() ; 00054 localCellIterator lastAvailableInitiator = availableInitiators.end() ; 00055 00056 // Partition the inititator candidates to retain only those above threshold 00057 lastAvailableInitiator 00058 = partition( firstAvailableInitiator, 00059 lastAvailableInitiator, 00060 PartitionCondition::AboveThresholdET( m_minInitiatorET ) 00061 ); 00062 00063 // Sort the remaining initiator candidates into descending order of eT 00064 // This means the first available initiator will always be the highest eT 00065 sort( firstAvailableInitiator, 00066 lastAvailableInitiator, 00067 SortAttribute::DescendingET() 00068 ); 00069 00070 00071 // Iterate over all initiator candidates 00072 00073 while( firstAvailableInitiator != lastAvailableInitiator ) { 00074 00075 // Partition the cells to find those within the required R-cone 00076 00077 //substitute an rCone with no args to stop the compiler wingeing 00078 // about unused parameters 00079 // double rCone = this->rCone( *firstAvailableInitiator ) ; 00080 double rCone = this->rCone( ) ; 00081 00082 localCellIterator endCellInCone = partition 00083 ( 00084 firstAvailableCell, 00085 lastAvailableCell, 00086 PartitionCondition::BelowThresholdDeltaR( *firstAvailableInitiator, 00087 rCone ) 00088 ); 00089 00090 // Accumulate all cells in cone to get weighted kinematic centre 00091 // We use a PreCluster helper object for this 00092 PreCluster preclus( firstAvailableCell, endCellInCone, m_masslessJets); 00093 00094 // Test if sum eT is above minumum. 00095 if( preclus.eT() > m_minClusterET ){ 00096 // Make a cluster and add to the collection 00097 HepLorentzVector temp=preclus; 00098 Cluster* newclus = 00099 new Cluster( temp, firstAvailableCell, endCellInCone ) ; 00100 // Cluster* newclus = 00101 // new Cluster( preclus, firstAvailableCell, endCellInCone ) ; 00102 clusters->push_back( newclus ) ; 00103 00104 //log << MSG::DEBUG << "New Cluster created " << newclus << endreq ; 00105 00106 // Remove all used cells from the available initiator range 00107 localCellIterator cell= firstAvailableCell; 00108 for(; cell != endCellInCone; ++cell ){ 00109 lastAvailableInitiator = 00110 std::remove( firstAvailableInitiator, 00111 lastAvailableInitiator, *cell ); 00112 } 00113 00114 // Remove all used cells from the available cell range 00115 firstAvailableCell = endCellInCone ; 00116 00117 }else{ 00118 //log << MSG::DEBUG << "Failed to form new cluster" 00119 // << *firstAvailableInitiator << endreq ; 00120 00121 // This initiator didnt lead to a good cluster. 00122 // Remove it from the available initiator range 00123 ++firstAvailableInitiator ; 00124 } 00125 00126 } 00127 00128 localCellIterator cellIter = firstAvailableCell; 00129 for(; cellIter!=lastAvailableCell; ++cellIter){ 00130 // unusedCells.push_back(new Cell(**cellIter)); 00131 //PS 24/01/03 00132 //the next line replaces the previous line 00133 // but why was it there in the first place? 00134 // unusedCells.push_back( (*cellIter)->clone() ); 00135 unusedCells.push_back(*cellIter); 00136 } 00137 return; 00138 } |
|
Strategy for making clusters from cells.
Definition at line 146 of file ClusterConeStrategy.cxx. References m_rConeBarrel. Referenced by makeClusters().
00146 { 00147 // Temporary: return barrel always as we dont have mechanism 00148 // to determine calorimeter geometry yet. 00149 return m_rConeBarrel ; 00150 } |
|
R-cone size for summation of Cells within barrel region.
Definition at line 102 of file ClusterConeStrategy.h. Referenced by ClusterConeStrategy(), and rCone(). |
|
R-cone size for summation of Cells within forward regions.
Definition at line 104 of file ClusterConeStrategy.h. Referenced by ClusterConeStrategy(). |
|
Minimun eT needed for a Cell to initiate a new Cluster.
Definition at line 107 of file ClusterConeStrategy.h. Referenced by ClusterConeStrategy(), and makeClusters(). |
|
Minimum eT which a candidate cluster must have to be retained.
Definition at line 110 of file ClusterConeStrategy.h. Referenced by ClusterConeStrategy(), and makeClusters(). |
|
Definition at line 111 of file ClusterConeStrategy.h. Referenced by ClusterConeStrategy(), and makeClusters(). |
|
Help with common kinematic operations.
Definition at line 118 of file ClusterConeStrategy.h. |
|
0..* output
Definition at line 164 of file ClusterConeStrategy.h. |