CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
SingleCellClusterAlgo Class Reference
Inheritance diagram for SingleCellClusterAlgo:
HGCalTriggerBackend::Algorithm< HGCalBestChoiceCodec > HGCalTriggerBackendAlgorithmBase

Public Member Functions

virtual void putInEvent (edm::Event &evt) overridefinal
 
virtual void reset () overridefinal
 
virtual void run (const l1t::HGCFETriggerDigiCollection &coll, const std::unique_ptr< HGCalTriggerGeometryBase > &geom) overridefinal
 
virtual void setProduces (edm::EDProducer &prod) const overridefinal
 
 SingleCellClusterAlgo (const edm::ParameterSet &conf)
 
- Public Member Functions inherited from HGCalTriggerBackend::Algorithm< HGCalBestChoiceCodec >
 Algorithm (const edm::ParameterSet &conf)
 
- Public Member Functions inherited from HGCalTriggerBackendAlgorithmBase
 HGCalTriggerBackendAlgorithmBase (const edm::ParameterSet &conf)
 
const std::string & name () const
 
virtual ~HGCalTriggerBackendAlgorithmBase ()
 

Private Attributes

std::unique_ptr
< l1t::HGCalClusterBxCollection
cluster_product_
 

Additional Inherited Members

- Protected Attributes inherited from HGCalTriggerBackend::Algorithm< HGCalBestChoiceCodec >
HGCalBestChoiceCodec codec_
 

Detailed Description

Definition at line 9 of file SingleCellClusterAlgo.cc.

Constructor & Destructor Documentation

SingleCellClusterAlgo::SingleCellClusterAlgo ( const edm::ParameterSet conf)
inline

Member Function Documentation

virtual void SingleCellClusterAlgo::putInEvent ( edm::Event evt)
inlinefinaloverridevirtual

Implements HGCalTriggerBackendAlgorithmBase.

Definition at line 25 of file SingleCellClusterAlgo.cc.

References eostools::move(), and mergeVDriftHistosByStation::name.

26  {
28  }
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
Definition: Event.h:122
def move
Definition: eostools.py:510
std::unique_ptr< l1t::HGCalClusterBxCollection > cluster_product_
virtual void SingleCellClusterAlgo::reset ( void  )
inlinefinaloverridevirtual

Implements HGCalTriggerBackendAlgorithmBase.

Definition at line 30 of file SingleCellClusterAlgo.cc.

31  {
33  }
std::unique_ptr< l1t::HGCalClusterBxCollection > cluster_product_
void SingleCellClusterAlgo::run ( const l1t::HGCFETriggerDigiCollection coll,
const std::unique_ptr< HGCalTriggerGeometryBase > &  geom 
)
finaloverridevirtual

Implements HGCalTriggerBackendAlgorithmBase.

Definition at line 41 of file SingleCellClusterAlgo.cc.

References data, PV3DBase< T, PVType, FrameType >::eta(), i, HGCalDetId::layer(), p4, HGCalBestChoiceDataPayload::payload, PV3DBase< T, PVType, FrameType >::phi(), point, HGCalBestChoiceDataPayload::reset(), l1t::HGCalCluster::setLayer(), l1t::HGCalCluster::setModule(), reco::LeafCandidate::setP4(), l1t::HGCalCluster::setSubDet(), DetId::subdetId(), relativeConstraints::value, and HGCalDetId::wafer().

44 {
45  for( const auto& digi : coll )
46  {
48  data.reset();
49  const HGCalDetId& moduleId = digi.getDetId<HGCalDetId>();
50  digi.decode(codec_, data);
51  int i = 0;
52  for(const auto& value : data.payload)
53  {
54  if(value>0)
55  {
56  GlobalPoint point = geom->getModulePosition(moduleId);
57  math::PtEtaPhiMLorentzVector p4((double)value/cosh(point.eta()), point.eta(), point.phi(), 0.);
58  // index in module stored as hwEta
59  l1t::HGCalCluster cluster(
61  value, i, 0);
62  cluster.setP4(p4);
63  cluster.setModule(moduleId.wafer());
64  cluster.setLayer(moduleId.layer());
65  cluster.setSubDet(moduleId.subdetId());
66  cluster_product_->push_back(0,cluster);
67  }
68  i++;
69  }
70 
71  }
72 }
int i
Definition: DBlmapReader.cc:9
Geom::Phi< T > phi() const
Definition: PV3DBase.h:69
PtEtaPhiMLorentzVectorD PtEtaPhiMLorentzVector
Lorentz vector with cartesian internal representation.
Definition: LorentzVector.h:25
double p4[4]
Definition: TauolaWrapper.h:92
int wafer() const
get the wafer #
Definition: HGCalDetId.h:42
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:37
T eta() const
Definition: PV3DBase.h:76
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:82
math::XYZTLorentzVector LorentzVector
Lorentz vector.
Definition: LeafCandidate.h:23
int layer() const
get the layer #
Definition: HGCalDetId.h:48
*vegas h *****************************************************used in the default bin number in original ***version of VEGAS is ***a higher bin number might help to derive a more precise ***grade subtle point
Definition: invegas.h:5
std::unique_ptr< l1t::HGCalClusterBxCollection > cluster_product_
virtual void SingleCellClusterAlgo::setProduces ( edm::EDProducer prod) const
inlinefinaloverridevirtual

Implements HGCalTriggerBackendAlgorithmBase.

Definition at line 17 of file SingleCellClusterAlgo.cc.

References mergeVDriftHistosByStation::name, and parseEventContent::prod.

18  {
19  prod.produces<l1t::HGCalClusterBxCollection>(name());
20  }

Member Data Documentation

std::unique_ptr<l1t::HGCalClusterBxCollection> SingleCellClusterAlgo::cluster_product_
private

Definition at line 36 of file SingleCellClusterAlgo.cc.