2 #include "CalibTracker/SiStripCommon/interface/TTREE_FOREACH_ENTRY.hh"
8 TTREE_FOREACH_ENTRY(tree) {
11 std::vector<unsigned> PLEAF(tsostrackmulti, tree);
12 std::vector<unsigned> PLEAF(clusterdetid, tree);
13 std::vector<unsigned> PLEAF(clusterwidth, tree);
14 std::vector<float> PLEAF(clustervariance, tree);
15 std::vector<float> PLEAF(tsosdriftx, tree);
16 std::vector<float> PLEAF(tsosdriftz, tree);
17 std::vector<float> PLEAF(tsoslocaltheta, tree);
18 std::vector<float> PLEAF(tsoslocalphi, tree);
19 std::vector<float> PLEAF(tsosglobalZofunitlocalY, tree);
21 const unsigned N(clusterdetid.size());
22 std::vector<float> BdotY(
N, 0);
24 std::vector<float> PLEAF(tsosBdotY, tree);
25 swap(BdotY, tsosBdotY);
27 std::vector<float> localy(
N, 0);
29 std::vector<float> PLEAF(tsoslocaly, tree);
30 swap(localy, tsoslocaly);
32 std::vector<unsigned> seedstrip(
N, 0);
34 std::vector<unsigned> PLEAF(clusterseedstrip, tree);
35 swap(seedstrip, clusterseedstrip);
38 for (
unsigned i = 0;
i <
N;
i++) {
40 if (tsostrackmulti[i] != 1 ||
44 const int sign = tsosglobalZofunitlocalY[
i] < 0 ? -1 : 1;
45 const float tthetaL = sign * tsosdriftx[
i] / tsosdriftz[
i];
46 const float tthetaT = sign *
tan(tsoslocaltheta[i]) *
cos(tsoslocalphi[i]);
49 granularity(detid, tthetaL, TFE_index, localy[i], seedstrip[i] % 128),
65 const float BdotY)
const {
66 book.
fill(tthetaL, gran +
"_reconstruction", 360, -1.0, 1.0);
67 book.
fill(tthetaT - tthetaL, gran +
allAndOne(width), 360, -1.0, 1.0);
68 book.
fill(tthetaT - tthetaL, variance, gran +
varWidth(width), 360, -1.0, 1.0);
70 book.
fill(tthetaT, width, gran +
method(WIDTH), 81, -0.6, 0.6);
72 book.
fill(BdotY, gran +
"_field", 101, 1, 5);
73 book.
fill(width, gran +
"_width", 10, 0, 10);
96 const Long64_t TFE_index,
98 const unsigned apvstrip)
const {
106 gran += (localy < 0 ?
"_yM" :
"_yP") + std::to_string(
abs((
int)(localy /
localYbin_ + (localy < 0 ? -1 : 0))));
116 gran *=
"_sample" + std::to_string(TFE_index %
ensembleSize_);
125 return subdetLabel(detid) +
"_module" + std::to_string(detid());
132 return subdetLabel(detid) +
"_layer" + std::to_string(layer) + (stereo ?
"s" :
"a");
std::string layerLabel(const SiStripDetId) const
unsigned int tibLayer(const DetId &id) const
uint32_t tobStereo(const DetId &id) const
const Long64_t maxEvents_
poly< std::string > granularity(const SiStripDetId, const float, const Long64_t, const float, const unsigned) const
void fill(TTree *, Book &) const
static std::string moduleLabel(const SiStripDetId)
void swap(Association< C > &lhs, Association< C > &rhs)
constexpr std::array< uint8_t, layerIndexSize > layer
Cos< T >::type cos(const T &t)
poly< std::string > varWidth(const unsigned width) const
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
Tan< T >::type tan(const T &t)
Abs< T >::type abs(const T &t)
static constexpr auto TOB
static std::string method(Method m, bool fit=true)
Detector identifier class for the strip tracker.
SubDetector subDetector() const
static constexpr auto TIB
void fill(double_t X, const char *name, uint_t NbinsX, double_t Xlow, double_t Xup, double_t W=1)
const TrackerTopology * tTopo_
static constexpr auto TIB
static std::string subdetLabel(const SiStripDetId)
const unsigned stripsPerBin_
void fill_one_cluster(Book &, const poly< std::string > &, const unsigned, const float, const float, const float, const float) const
uint32_t tibStereo(const DetId &id) const
const double ensembleLow_
poly< std::string > allAndOne(const unsigned width) const
unsigned int tobLayer(const DetId &id) const