CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Private Attributes
ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer Class Reference
Inheritance diagram for ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer:
ALPAKA_ACCELERATOR_NAMESPACE::stream::EDProducer<> edm::ProducerBase< edm::stream::EDProducer, Args... >

Public Member Functions

 HGCalSoARecHitsLayerClustersProducer (edm::ParameterSet const &config)
 
void produce (device::Event &iEvent, device::EventSetup const &iSetup) override
 
 ~HGCalSoARecHitsLayerClustersProducer () override=default
 
- Public Member Functions inherited from ALPAKA_ACCELERATOR_NAMESPACE::stream::EDProducer<>
void produce (edm::Event &iEvent, edm::EventSetup const &iSetup) final
 
- Public Member Functions inherited from edm::ProducerBase< edm::stream::EDProducer, Args... >
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
std::vector< edm::ProductResolverIndex > const & indiciesForPutProducts (BranchType iBranchType) const
 
 ProducerBase ()
 
std::vector< edm::ProductResolverIndex > const & putTokenIndexToProductResolverIndex () const
 
std::vector< bool > const & recordProvenanceList () const
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
std::function< void(BranchDescription const &)> registrationCallback () const
 used by the fwk to register list of products More...
 
void resolvePutIndicies (BranchType iBranchType, ModuleToResolverIndicies const &iIndicies, std::string const &moduleLabel)
 
TypeLabelList const & typeLabelList () const
 used by the fwk to register the list of products of this module More...
 
 ~ProducerBase () noexcept(false) override
 

Static Public Member Functions

static void fillDescriptions (edm::ConfigurationDescriptions &descriptions)
 

Private Attributes

HGCalLayerClustersAlgoWrapper algo_
 
const float deltac_
 
device::EDPutToken< HGCalSoARecHitsExtraDeviceCollection > const deviceToken_
 
device::EDGetToken< HGCalSoARecHitsDeviceCollection > const getTokenDevice_
 
const float kappa_
 
const float outlierDeltaFactor_
 

Additional Inherited Members

- Public Types inherited from edm::ProducerBase< edm::stream::EDProducer, Args... >
using BranchAliasSetterT = ProductRegistryHelper::BranchAliasSetterT< T >
 
using ModuleToResolverIndicies = std::unordered_multimap< std::string, std::tuple< edm::TypeID const *, const char *, edm::ProductResolverIndex > >
 
typedef ProductRegistryHelper::TypeLabelList TypeLabelList
 
- Protected Member Functions inherited from edm::ProducerBase< edm::stream::EDProducer, Args... >
auto produces (std::string instanceName) noexcept
 declare what type of product will make and with which optional label More...
 
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
BranchAliasSetterT< ProductType > produces ()
 
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
BranchAliasSetterT< ProductType > produces ()
 
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
BranchAliasSetterT< ProductType > produces ()
 
auto produces () noexcept
 
ProducesCollector producesCollector ()
 

Detailed Description

Definition at line 33 of file HGCalSoARecHitsLayerClustersProducer.cc.

Constructor & Destructor Documentation

◆ HGCalSoARecHitsLayerClustersProducer()

ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer::HGCalSoARecHitsLayerClustersProducer ( edm::ParameterSet const &  config)
inline

Definition at line 35 of file HGCalSoARecHitsLayerClustersProducer.cc.

36  : getTokenDevice_{consumes(config.getParameter<edm::InputTag>("hgcalRecHitsSoA"))},
38  deltac_((float)config.getParameter<double>("deltac")),
39  kappa_((float)config.getParameter<double>("kappa")),
40  outlierDeltaFactor_((float)config.getParameter<double>("outlierDeltaFactor")) {}
device::EDGetToken< HGCalSoARecHitsDeviceCollection > const getTokenDevice_
Definition: config.py:1
auto produces(std::string instanceName) noexcept
declare what type of product will make and with which optional label
device::EDPutToken< HGCalSoARecHitsExtraDeviceCollection > const deviceToken_

◆ ~HGCalSoARecHitsLayerClustersProducer()

ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer::~HGCalSoARecHitsLayerClustersProducer ( )
overridedefault

Member Function Documentation

◆ fillDescriptions()

static void ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer::fillDescriptions ( edm::ConfigurationDescriptions descriptions)
inlinestatic

Definition at line 57 of file HGCalSoARecHitsLayerClustersProducer.cc.

References edm::ConfigurationDescriptions::addWithDefaultLabel(), submitPVResolutionJobs::desc, and ProducerED_cfi::InputTag.

57  {
59  desc.add<edm::InputTag>("hgcalRecHitsSoA", edm::InputTag("TO BE DEFINED"));
60  desc.add<double>("deltac", 1.3);
61  desc.add<double>("kappa", 9.);
62  desc.add<double>("outlierDeltaFactor", 2.);
63  descriptions.addWithDefaultLabel(desc);
64  }
void addWithDefaultLabel(ParameterSetDescription const &psetDescription)

◆ produce()

void ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer::produce ( device::Event iEvent,
device::EventSetup const &  iSetup 
)
inlineoverridevirtual

Implements ALPAKA_ACCELERATOR_NAMESPACE::stream::EDProducer<>.

Definition at line 44 of file HGCalSoARecHitsLayerClustersProducer.cc.

References algo_, deltac_, deviceToken_, getTokenDevice_, iEvent, kappa_, eostools::move(), outlierDeltaFactor_, convertSQLitetoXML_cfg::output, and ALPAKA_ACCELERATOR_NAMESPACE::HGCalLayerClustersAlgoWrapper::run().

44  {
45  auto const& deviceInput = iEvent.get(getTokenDevice_);
46  //std::cout << "Size of device collection: " << deviceInput->metadata().size() << std::endl;
47  auto const input_v = deviceInput.view();
48  // Allocate output SoA
49  HGCalSoARecHitsExtraDeviceCollection output(deviceInput->metadata().size(), iEvent.queue());
50  auto output_v = output.view();
51 
52  algo_.run(
53  iEvent.queue(), deviceInput->metadata().size(), deltac_, kappa_, outlierDeltaFactor_, input_v, output_v);
55  }
device::EDGetToken< HGCalSoARecHitsDeviceCollection > const getTokenDevice_
PortableCollection< HGCalSoARecHitsExtra > HGCalSoARecHitsExtraDeviceCollection
int iEvent
Definition: GenABIO.cc:224
void run(Queue &queue, const unsigned int size, const float dc, const float kappa, const float outlierDeltaFactor, const HGCalSoARecHitsDeviceCollection::ConstView inputs, HGCalSoARecHitsExtraDeviceCollection::View outputs) const
device::EDPutToken< HGCalSoARecHitsExtraDeviceCollection > const deviceToken_
Definition: output.py:1
def move(src, dest)
Definition: eostools.py:511

Member Data Documentation

◆ algo_

HGCalLayerClustersAlgoWrapper ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer::algo_
private

Definition at line 70 of file HGCalSoARecHitsLayerClustersProducer.cc.

Referenced by produce().

◆ deltac_

const float ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer::deltac_
private

Definition at line 71 of file HGCalSoARecHitsLayerClustersProducer.cc.

Referenced by produce().

◆ deviceToken_

device::EDPutToken<HGCalSoARecHitsExtraDeviceCollection> const ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer::deviceToken_
private

Definition at line 69 of file HGCalSoARecHitsLayerClustersProducer.cc.

Referenced by produce().

◆ getTokenDevice_

device::EDGetToken<HGCalSoARecHitsDeviceCollection> const ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer::getTokenDevice_
private

Definition at line 68 of file HGCalSoARecHitsLayerClustersProducer.cc.

Referenced by produce().

◆ kappa_

const float ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer::kappa_
private

Definition at line 72 of file HGCalSoARecHitsLayerClustersProducer.cc.

Referenced by produce().

◆ outlierDeltaFactor_

const float ALPAKA_ACCELERATOR_NAMESPACE::HGCalSoARecHitsLayerClustersProducer::outlierDeltaFactor_
private

Definition at line 73 of file HGCalSoARecHitsLayerClustersProducer.cc.

Referenced by produce().