63 includeErrors_(iConfig.getParameter<
bool>(
"IncludeErrors")),
64 clusterThresholds_{iConfig.
getParameter<int32_t>(
"clusterThreshold_layer1"),
65 iConfig.
getParameter<int32_t>(
"clusterThreshold_otherLayers"),
66 static_cast<float>(iConfig.
getParameter<
double>(
"ElectronPerADCGain")),
67 static_cast<int8_t
>(iConfig.
getParameter<
int>(
"Phase2ReadoutMode")),
68 static_cast<uint16_t
>(iConfig.
getParameter<uint32_t>(
"Phase2DigiBaseline")),
69 static_cast<uint8_t
>(iConfig.
getParameter<uint32_t>(
"Phase2KinkADC"))} {
71 digiErrorPutToken_ = produces<cms::cuda::Product<SiPixelDigiErrorsCUDA>>();
78 desc.add<
bool>(
"IncludeErrors",
true);
79 desc.add<int32_t>(
"clusterThreshold_layer1", 4000);
80 desc.add<int32_t>(
"clusterThreshold_otherLayers", 4000);
81 desc.add<
double>(
"ElectronPerADCGain", 1500);
82 desc.add<int32_t>(
"Phase2ReadoutMode", 3);
83 desc.add<uint32_t>(
"Phase2DigiBaseline", 1000);
84 desc.add<uint32_t>(
"Phase2KinkADC", 8);
107 for (
auto DSViter =
input.begin(); DSViter !=
input.end(); DSViter++) {
108 unsigned int detid = DSViter->detId();
109 DetId detIdObject(detid);
111 auto const gind = genericDet->
index();
112 for (
auto const&
px : *DSViter) {
113 moduleIds[
nDigis_] = uint16_t(gind);
119 packedData[
nDigis_] = uint32_t(
px.packedData());
121 rawIds[
nDigis_] = uint32_t(detid);
void addWithDefaultLabel(ParameterSetDescription const &psetDescription)
void produce(edm::Event &iEvent, const edm::EventSetup &iSetup) override
T getParameter(std::string const &) const
edm::EDPutTokenT< cms::cuda::Product< SiPixelClustersCUDA > > clusterPutToken_
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
const TrackerGeomDet * idToDetUnit(DetId) const override
Return the pointer to the GeomDetUnit corresponding to a given DetId.
const edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecord > geomToken_
const edm::EDGetTokenT< edm::DetSetVector< PixelDigi > > pixelDigiToken_
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
static constexpr uint16_t numberOfModules
edm::EDPutTokenT< cms::cuda::Product< SiPixelDigiErrorsCUDA > > digiErrorPutToken_
static std::string const input
cms::cuda::ContextState ctxState_
SiPixelDigiErrorsCUDA && getErrors()
void makePhase2ClustersAsync(const SiPixelClusterThresholds clusterThresholds, const uint16_t *moduleIds, const uint16_t *xDigis, const uint16_t *yDigis, const uint16_t *adcDigis, const uint32_t *packedData, const uint32_t *rawIds, const uint32_t numDigis, cudaStream_t stream)
const SiPixelClusterThresholds clusterThresholds_
std::pair< SiPixelDigisCUDA, SiPixelClustersCUDA > getResults()
#define DEFINE_FWK_MODULE(type)
SiPixelPhase2DigiToClusterCUDA(const edm::ParameterSet &iConfig)
Namespace of DDCMS conversion namespace.
edm::EDPutTokenT< cms::cuda::Product< SiPixelDigisCUDA > > digiPutToken_
void acquire(const edm::Event &iEvent, const edm::EventSetup &iSetup, edm::WaitingTaskWithArenaHolder waitingTaskHolder) override
const bool includeErrors_
~SiPixelPhase2DigiToClusterCUDA() override=default
constexpr uint32_t maxNumDigis