172 unsigned int lNDigis = lInputDigis->
size();
176 std::vector<edm::DetSetVector<SiStripRawDigi>::detset> pedsData;
177 pedsData.reserve(lNDigis);
178 std::vector<edm::DetSetVector<SiStripProcessedRawDigi>::detset> noiseData;
179 noiseData.reserve(lNDigis);
180 std::vector<edm::DetSetVector<SiStripRawDigi>::detset> pedSubtrData;
181 pedSubtrData.reserve(lNDigis);
182 std::vector<edm::DetSetVector<SiStripRawDigi>::detset> cmSubtrData;
183 cmSubtrData.reserve(lNDigis);
185 std::vector<edm::DetSet<SiStripDigi> > zsData;
188 std::map<uint32_t, std::vector<uint32_t> > medsData;
192 for (; inputChannel != lInputDigis->
end(); ++inputChannel) {
193 uint32_t lDetId = inputChannel->detId();
200 unsigned int lNStrips = inputChannel->
size();
203 std::vector<SiStripRawDigi>& pedsDetSetData = pedsData.back().data;
204 pedsDetSetData.reserve(lNStrips);
205 std::vector<SiStripProcessedRawDigi>& noiseDetSetData = noiseData.back().data;
206 noiseDetSetData.reserve(lNStrips);
207 std::vector<SiStripRawDigi>& pedSubtrDetSetData = pedSubtrData.back().data;
208 pedSubtrDetSetData.reserve(lNStrips);
209 std::vector<SiStripRawDigi>& cmSubtrDetSetData = cmSubtrData.back().data;
210 cmSubtrDetSetData.reserve(lNStrips);
218 std::vector<uint32_t> medsDetSetData;
219 medsDetSetData.reserve(lNPairs * 2);
224 uint16_t lFedChannel = 0;
228 lDetId = lConnection.
detId();
244 inputChannel, pedsDetSetData, noiseDetSetData, pedSubtrDetSetData, medsDetSetData,
true);
249 medsData[inputChannel->detId()] = medsDetSetData;
253 if (!zsDetSetData.empty())
254 zsData.push_back(zsDetSetData);
259 std::unique_ptr<edm::DetSetVector<SiStripProcessedRawDigi> > lNoises(
262 std::unique_ptr<edm::DetSetVector<SiStripRawDigi> > lOutputPedSubtr(
265 std::unique_ptr<edm::DetSetVector<SiStripRawDigi> > lOutputCMSubtr(
268 std::unique_ptr<std::map<uint32_t, std::vector<uint32_t> > > lMedians(
269 new std::map<uint32_t, std::vector<uint32_t> >(medsData));
edm::ESWatcher< SiStripNoisesRcd > noisesWatcher_
const SiStripNoises * noises_
void subtractPedestals(const edm::DetSetVector< SiStripRawDigi >::const_iterator &inputChannel, std::vector< SiStripRawDigi > &pedsDetSetData, std::vector< SiStripProcessedRawDigi > &noiseDetSetData, std::vector< SiStripRawDigi > &pedSubtrDetSetData, std::vector< uint32_t > &medsDetSetData, const bool fillApvsForCM)
FedChannelConnection fedConnection(uint16_t fed_id, uint16_t fed_ch) const
T const * product() const
const SiStripFedCabling * fedCabling_
void fedIndex(uint32_t aFedIndex, uint16_t &aFedId, uint16_t &aFedChannel)
void retrieveNoises(const edm::ESHandle< SiStripNoises > &aHandle)
size_type size() const
Return the number of contained DetSets.
edm::EDGetTokenT< edm::DetSetVector< SiStripRawDigi > > spyReorderedDigisToken_
Class containning control, module, detector and connection information, at the level of a FED channel...
void initialiseModule(const uint32_t aDetId, const uint32_t aNPairs, const uint32_t aPair)
void subtractCM(const std::vector< SiStripRawDigi > &pedSubtrDetSetData, std::vector< SiStripRawDigi > &cmSubtrDetSetData)
iterator end()
Return the off-the-end iterator.
const uint32_t & detId() const
edm::ESWatcher< SiStripPedestalsRcd > pedestalsWatcher_
static const uint16_t STRIPS_PER_FEDCH
std::unique_ptr< SiStripRawProcessingAlgorithms > algorithms_
object for zero-suppression
void zeroSuppress(const std::vector< SiStripRawDigi > &cmSubtrDetSetData, edm::DetSet< SiStripDigi > &zsDetSetData, const std::unique_ptr< SiStripRawProcessingAlgorithms > &algorithms)
const uint16_t & nApvPairs() const
uint16_t apvPairNumber() const
bool check(const edm::EventSetup &iSetup)
iterator begin()
Return an iterator to the first DetSet.
void retrievePedestals(const edm::ESHandle< SiStripPedestals > &aHandle)
collection_type::const_iterator const_iterator
sistrip::FEDEmulator fedEmulator_
edm::ESWatcher< SiStripFedCablingRcd > cablingWatcher_
edm::EDGetTokenT< edm::DetSetVector< SiStripRawDigi > > spyVirginRawDigisToken_
const SiStripPedestals * pedestals_