20 #include "CLHEP/Random/RandGauss.h" 21 #include "CLHEP/Random/JamesRandom.h" 77 produces< std::vector<raw::RawDigit> >();
87 std::string channelMapFile=sp.find_file(
"protoDUNETPCChannelMap_v3.txt");
88 std::ifstream fin(channelMapFile.c_str());
90 int crateNo, slotNo, fiberNo, FEMBChannel,
91 StreamChannel, slotID, fiberID,
92 chipNo, chipChannel, asicNo,
93 asicChannel, planeType, offlineChannel;
95 while(fin >> crateNo >> slotNo >> fiberNo >> FEMBChannel
96 >> StreamChannel >> slotID >> fiberID
97 >> chipNo >> chipChannel >> asicNo
98 >> asicChannel >> planeType >> offlineChannel){
109 std::unique_ptr<std::vector<raw::RawDigit>> digits_out(
new std::vector<raw::RawDigit>);
114 for(
auto&& digit: digits_in){
115 if(digit.Compression()!=0){
117 std::cout <<
"Compression type " << digit.Compression() <<
std::endl;
119 std::vector<short> samples_out(digit.NADC(), 0);
120 std::vector<float> samples_work(digit.NADC(), 0);
121 for(
size_t i=0; i<digit.NADC(); ++i){
Collection of charge vs time digitized from a single readout channel.
void produce(art::Event &e) override
virtual int addNoise(detinfo::DetectorClocksData const &clockData, detinfo::DetectorPropertiesData const &detProp, Channel chan, AdcSignalVector &sigs) const =0
EDProducer(fhicl::ParameterSet const &pset)
NoiseAdder & operator=(NoiseAdder const &)=delete
std::map< int, ElectronicsAddress > m_channelMap
NoiseAdder(fhicl::ParameterSet const &p)
#define DEFINE_ART_MODULE(klass)
ValidHandle< PROD > getValidHandle(InputTag const &tag) const
ProductID put(std::unique_ptr< PROD > &&edp, std::string const &instance={})
ElectronicsAddress(int _crate, int _slot, int _fiber, int _asic, int _asicChannel)
art::ServiceHandle< ChannelNoiseService > m_noiseService
QTextStream & endl(QTextStream &s)