CMS 3D CMS Logo

Functions
CaloSamples.cc File Reference
#include "CalibFormats/CaloObjects/interface/CaloSamples.h"
#include "FWCore/MessageLogger/interface/MessageLogger.h"
#include <cmath>
#include <iostream>

Go to the source code of this file.

Functions

std::ostream & operator<< (std::ostream &s, const CaloSamples &samples)
 

Function Documentation

◆ operator<<()

std::ostream& operator<< ( std::ostream &  s,
const CaloSamples samples 
)

Definition at line 101 of file CaloSamples.cc.

101  {
102  s << "DetId " << samples.id();
103  // print out every so many precise samples
104  float preciseStep = samples.preciseSize() / samples.size();
105  s << ", " << samples.size() << " samples";
106  if (preciseStep > 0)
107  s << ", " << samples.preciseSize() << " preciseSamples"
108  << ", " << preciseStep << " preciseStep";
109  s << '\n';
110  for (int i = 0; i < samples.size(); i++) {
111  s << i << ":" << samples[i] << " precise:";
112  int precise_start(i * preciseStep), precise_end(precise_start + preciseStep);
113  for (int j(precise_start); ((j < precise_end) && (j < samples.preciseSize())); ++j)
114  s << " " << samples.preciseAt(j);
115  s << std::endl;
116  }
117  return s;
118 }

References mps_fire::i, dqmiolumiharvest::j, alignCSCRings::s, and EgammaValidation_cff::samples.

mps_fire.i
i
Definition: mps_fire.py:428
EgammaValidation_cff.samples
samples
Definition: EgammaValidation_cff.py:19
alignCSCRings.s
s
Definition: alignCSCRings.py:92
dqmiolumiharvest.j
j
Definition: dqmiolumiharvest.py:66