org.lcsim.emcluster
Class EMConeClusterBuilder

java.lang.Object
  extended byhep.lcd.util.driver.AbstractProcessor
      extended byorg.lcsim.emcluster.EMConeClusterBuilder
All Implemented Interfaces:
hep.lcd.util.driver.Processor

public class EMConeClusterBuilder
extends hep.lcd.util.driver.AbstractProcessor

EMConeClusterBuilder implements a q-f cone clustering algorithm that assigns all neighboring hits to the same cluster if they fall within a radius R of the cluster axis. The axis is originally defined by a seed cell, and is iteratively updated as cells are added. This version of the ClusterBuilder splits overlapping clusters by assigning cells in the overlap region to the nearest cluster axis.

Author:
Norman A. Graf

Field Summary
 
Fields inherited from class hep.lcd.util.driver.AbstractProcessor
context
 
Constructor Summary
EMConeClusterBuilder(double radius, double seed, double minE)
          Constructor
 
Method Summary
 java.util.List cluster(hep.lcd.event.CalorimeterHits hits)
          Takes a list of CalorimeterHits, clusters them, and returns a list of EMClusters
 java.util.List cluster(java.util.Vector in)
          Takes a list of CalorimeterHits, clusters them, and returns a list of EMClusters
 double dTheta(EMCluster c1, EMCluster c2)
          Calculate the angle between two EMClusters
 void process(hep.lcd.event.LCDEvent event)
          Processes an LCDEvent to find EMClusters
 void resolve(EMCluster c1, EMCluster c2)
          Given two overlapping clusters, assign cells to nearest axis.
 
Methods inherited from class hep.lcd.util.driver.AbstractProcessor
clearContext, getDebugLevel, getDebugStream, getEventPrefix, getHistogramLevel, getName, getParameterFile, getParameters, getParameters, getRandom, histogram, init, setContext, setDebugLevel, setDetector, setEventPrefix, setHistogramLevel, start, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EMConeClusterBuilder

public EMConeClusterBuilder(double radius,
                            double seed,
                            double minE)
Constructor

Parameters:
radius - The cone radius in q-f space
seed - The minimum energy for a cone seed cell (in GeV)
minE - The minimum energy for a cluster (in GeV)
Method Detail

process

public void process(hep.lcd.event.LCDEvent event)
Processes an LCDEvent to find EMClusters

Parameters:
event - The LCDEvent to process

cluster

public java.util.List cluster(hep.lcd.event.CalorimeterHits hits)
Takes a list of CalorimeterHits, clusters them, and returns a list of EMClusters

Parameters:
hits - The CalorimeterHits collection of CalorimeterHits
Returns:
Vector of found EMClusters

cluster

public java.util.List cluster(java.util.Vector in)
Takes a list of CalorimeterHits, clusters them, and returns a list of EMClusters

Returns:
Vector of found EMClusters

dTheta

public double dTheta(EMCluster c1,
                     EMCluster c2)
Calculate the angle between two EMClusters

Parameters:
c1 - First EMCluster
c2 - Second EMCluster
Returns:
The angle between the two clusters

resolve

public void resolve(EMCluster c1,
                    EMCluster c2)
Given two overlapping clusters, assign cells to nearest axis. The cluster axes are not iterated. Cluster quantities are recalculated after the split.

Parameters:
c1 - First EMCluster
c2 - Second EMCluster