Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/cms-sw/cmssw into CMSSW_1…
Browse files Browse the repository at this point in the history
…1_0_X_TauEnablePhase2Validation
  • Loading branch information
steggema committed Jun 6, 2019
2 parents af33e54 + 8ebef5b commit 29a76e9
Show file tree
Hide file tree
Showing 3,312 changed files with 232,922 additions and 243,203 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
1 change: 1 addition & 0 deletions Alignment/CommonAlignmentMonitor/plugins/AlignmentStats.cc
Expand Up @@ -6,6 +6,7 @@
#include "Alignment/TrackerAlignment/interface/AlignableTracker.h"
#include "Alignment/CommonAlignment/interface/Alignable.h"
#include "Alignment/CommonAlignment/interface/Utilities.h"
#include "DataFormats/SiStripDetId/interface/SiStripDetId.h"

#include "DataFormats/TrackerRecHit2D/interface/SiStripRecHit1D.h"
#include "DataFormats/TrackerRecHit2D/interface/SiStripRecHit2D.h"
Expand Down
1 change: 0 additions & 1 deletion Alignment/OfflineValidation/scripts/validateAlignments.py
Expand Up @@ -11,7 +11,6 @@
import six
import Alignment.OfflineValidation.TkAlAllInOneTool.configTemplates \
as configTemplates
import Alignment.OfflineValidation.TkAlAllInOneTool.crabWrapper as crabWrapper
from Alignment.OfflineValidation.TkAlAllInOneTool.TkAlExceptions \
import AllInOneError
from Alignment.OfflineValidation.TkAlAllInOneTool.helperFunctions \
Expand Down
2 changes: 1 addition & 1 deletion Alignment/SurveyAnalysis/src/SurveyDataReader.cc
Expand Up @@ -6,7 +6,7 @@

#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "Geometry/Records/interface/IdealGeometryRecord.h"
// #include "DataFormats/SiStripDetId/interface/StripSubdetector.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"

#include "Alignment/SurveyAnalysis/interface/SurveyDataReader.h"

Expand Down
1 change: 1 addition & 0 deletions Alignment/TrackerAlignment/plugins/MCMisalignmentScaler.cc
Expand Up @@ -46,6 +46,7 @@
#include "CondFormats/SiPixelObjects/interface/SiPixelQuality.h"

#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"

#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h"
#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeomBuilderFromGeometricDet.h"
Expand Down
1 change: 1 addition & 0 deletions Alignment/TrackerAlignment/plugins/TkAlCaOverlapTagger.cc
Expand Up @@ -11,6 +11,7 @@
#include "DataFormats/Common/interface/View.h"
#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "Geometry/Records/interface/TrackerTopologyRcd.h"
#include "DataFormats/SiStripDetId/interface/SiStripDetId.h"

#include "TrackingTools/TrajectoryState/interface/TrajectoryStateOnSurface.h"
#include "DataFormats/TrackReco/interface/Track.h"
Expand Down
1 change: 1 addition & 0 deletions Alignment/TrackerAlignment/src/AlignableTrackerBuilder.cc
Expand Up @@ -14,6 +14,7 @@
#include "Alignment/TrackerAlignment/interface/AlignableSiStripDet.h"
#include "Alignment/TrackerAlignment/interface/TrackerAlignableIndexer.h"

#include "DataFormats/SiStripDetId/interface/SiStripDetId.h"


//=============================================================================
Expand Down
Expand Up @@ -7,6 +7,7 @@
// topology and geometry
#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"



Expand Down
2 changes: 2 additions & 0 deletions Alignment/TrackerAlignment/test/TrackerGeometryAnalyzer.cc
Expand Up @@ -13,6 +13,8 @@
// for creation of TrackerTopology
#include "Geometry/Records/interface/TrackerTopologyRcd.h"

#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"

// tracker-alignables aka AlignableTracker
#include "Alignment/TrackerAlignment/interface/AlignableTracker.h"
#include "Alignment/TrackerAlignment/interface/AlignableSiStripDet.h"
Expand Down
1 change: 1 addition & 0 deletions BigProducts/Simulation/BuildFile.xml
Expand Up @@ -15,6 +15,7 @@
<use name="SimG4Core/SensitiveDetector"/>
<use name="SimG4Core/PrintGeomInfo"/>
<use name="SimRomanPot/SimFP420"/>
<use name="SimG4Core/DD4hepGeometry"/>
<use name="Validation/HcalHits"/>
<use name="Validation/EcalHits"/>
<use name="SimDataFormats/ValidationFormats"/>
Expand Down
58 changes: 22 additions & 36 deletions CalibCalorimetry/HcalTPGEventSetup/src/HcalTPGCoderULUT.cc
Expand Up @@ -50,11 +50,13 @@ class HcalTPGCoderULUT : public edm::ESProducer {
private:
using HostType = edm::ESProductHost<HcaluLUTTPGCoder, HcalDbRecord>;

void setupDBRecord(const HcalDbRecord&, HcaluLUTTPGCoder*);
void buildCoder(const HcalTopology*, const edm::ESHandle<HcalTimeSlew>&, HcaluLUTTPGCoder*);
void buildCoder(const HcalTopology*, const HcalTimeSlew*, HcaluLUTTPGCoder*);

// ----------member data ---------------------------
edm::ReusableObjectHolder<HostType> holder_;
edm::ESGetToken<HcalTopology, HcalRecNumberingRecord> topoToken_;
edm::ESGetToken<HcalTimeSlew, HcalTimeSlewRecord> delayToken_;
edm::ESGetToken<HcalDbService, HcalDbRecord> serviceToken_;
bool read_FGLut_, read_Ascii_, read_XML_, LUTGenerationMode_, linearLUTs_;
double linearLSB_QIE8_, linearLSB_QIE11Overlap_, linearLSB_QIE11_;
int maskBit_;
Expand All @@ -78,8 +80,12 @@ HcalTPGCoderULUT::HcalTPGCoderULUT(const edm::ParameterSet& iConfig) {
read_XML_ = iConfig.getParameter<bool>("read_XML_LUTs");
read_FGLut_ = iConfig.getParameter<bool>("read_FG_LUTs");
fgfile_ = iConfig.getParameter<edm::FileInPath>("FGLUTs");

//the following line is needed to tell the framework what
// data is being produced
auto cc = setWhatProduced(this);
cc.setConsumes(topoToken_).setConsumes(delayToken_, edm::ESInputTag{"", "HBHE"});

if (!(read_Ascii_ || read_XML_)) {
LUTGenerationMode_ = iConfig.getParameter<bool>("LUTGenerationMode");
linearLUTs_ = iConfig.getParameter<bool>("linearLUTs");
Expand All @@ -89,17 +95,15 @@ HcalTPGCoderULUT::HcalTPGCoderULUT(const edm::ParameterSet& iConfig) {
linearLSB_QIE11Overlap_ = scales.getParameter<double>("LSBQIE11Overlap");
maskBit_ = iConfig.getParameter<int>("MaskBit");
FG_HF_thresholds_ = iConfig.getParameter<std::vector<uint32_t> >("FG_HF_thresholds");
cc.setConsumes(serviceToken_);
} else {
ifilename_ = iConfig.getParameter<edm::FileInPath>("inputLUTs");
}
setWhatProduced(this);
}

void HcalTPGCoderULUT::buildCoder(const HcalTopology* topo,
const edm::ESHandle<HcalTimeSlew>& delay,
HcaluLUTTPGCoder* theCoder) {
void HcalTPGCoderULUT::buildCoder(const HcalTopology* topo, const HcalTimeSlew* delay, HcaluLUTTPGCoder* theCoder) {
using namespace edm::es;
theCoder->init(topo, delay.product());
theCoder->init(topo, delay);
if (read_Ascii_ || read_XML_) {
edm::LogInfo("HCAL") << "Using ASCII/XML LUTs" << ifilename_.fullPath() << " for HcalTPGCoderULUT initialization";
if (read_Ascii_) {
Expand Down Expand Up @@ -132,40 +136,22 @@ HcalTPGCoderULUT::~HcalTPGCoderULUT() {
HcalTPGCoderULUT::ReturnType HcalTPGCoderULUT::produce(const HcalTPGRecord& iRecord) {
auto host = holder_.makeOrGet([]() { return new HostType; });

const auto& topo = iRecord.get(topoToken_);
const auto& delay = iRecord.getRecord<HcalDbRecord>().get(delayToken_);
if (read_Ascii_ || read_XML_) {
edm::ESHandle<HcalTopology> htopo;
iRecord.getRecord<HcalRecNumberingRecord>().get(htopo);
const HcalTopology* topo = &(*htopo);

edm::ESHandle<HcalTimeSlew> delay;
iRecord.getRecord<HcalDbRecord>().getRecord<HcalTimeSlewRecord>().get("HBHE", delay);

buildCoder(topo, delay, host.get());
buildCoder(&topo, &delay, host.get());
} else {
host->ifRecordChanges<HcalDbRecord>(iRecord, [this, h = host.get()](auto const& rec) { setupDBRecord(rec, h); });
host->ifRecordChanges<HcalDbRecord>(iRecord, [this, &topo, &delay, h = host.get()](auto const& rec) {
buildCoder(&topo, &delay, h);
h->update(rec.get(serviceToken_));
// Temporary update for FG Lut
// Will be moved to DB
if (read_FGLut_)
h->update(fgfile_.fullPath().c_str(), true);
});
}
return host;
}

void HcalTPGCoderULUT::setupDBRecord(const HcalDbRecord& theRec, HcaluLUTTPGCoder* theCoder) {
edm::ESHandle<HcalDbService> conditions;
theRec.get(conditions);
edm::ESHandle<HcalTopology> htopo;
theRec.getRecord<HcalRecNumberingRecord>().get(htopo);
const HcalTopology* topo = &(*htopo);

edm::ESHandle<HcalTimeSlew> delay;
theRec.getRecord<HcalTimeSlewRecord>().get("HBHE", delay);

buildCoder(topo, delay, theCoder);

theCoder->update(*conditions);

// Temporary update for FG Lut
// Will be moved to DB
if (read_FGLut_)
theCoder->update(fgfile_.fullPath().c_str(), true);
}

//define this as a plug-in
DEFINE_FWK_EVENTSETUP_MODULE(HcalTPGCoderULUT);
1 change: 1 addition & 0 deletions CalibFormats/SiStripObjects/src/SiStripDetCabling.cc
Expand Up @@ -5,6 +5,7 @@
// Created: Wed Mar 22 12:24:33 CET 2006
#include "CalibFormats/SiStripObjects/interface/SiStripDetCabling.h"
#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"
#include "FWCore/MessageLogger/interface/MessageLogger.h"
#include "FWCore/Utilities/interface/typelookup.h"

Expand Down
Expand Up @@ -583,19 +583,19 @@ void SiPixelErrorEstimation::analyze(const edm::Event& e, const edm::EventSetup&

//enum ModuleGeometry {UNKNOWNGEOMETRY, IB1, IB2, OB1, OB2, W1A, W2A, W3A, W1B, W2B, W3B, W4, W5, W6, W7};

if (si_strip_det_id.moduleGeometry() == 1) {
if (si_strip_det_id.moduleGeometry() == SiStripModuleGeometry::IB1) {
detector_type = 1;
//cout << "si_strip_det_id.moduleGeometry() = IB1" << endl;
//cout << "si_strip_det_id.moduleGeometry() = " << si_strip_det_id.moduleGeometry() << endl;
} else if (si_strip_det_id.moduleGeometry() == 2) {
} else if (si_strip_det_id.moduleGeometry() == SiStripModuleGeometry::IB2) {
detector_type = 2;
//cout << "si_strip_det_id.moduleGeometry() = IB2" << endl;
//cout << "si_strip_det_id.moduleGeometry() = " << si_strip_det_id.moduleGeometry() << endl;
} else if (si_strip_det_id.moduleGeometry() == 3) {
} else if (si_strip_det_id.moduleGeometry() == SiStripModuleGeometry::OB1) {
detector_type = 3;
//cout << "si_strip_det_id.moduleGeometry() = OB1" << endl;
//cout << "si_strip_det_id.moduleGeometry() = " << si_strip_det_id.moduleGeometry() << endl;
} else if (si_strip_det_id.moduleGeometry() == 4) {
} else if (si_strip_det_id.moduleGeometry() == SiStripModuleGeometry::OB2) {
detector_type = 4;
//cout << "si_strip_det_id.moduleGeometry() = OB2" << endl;
//cout << "si_strip_det_id.moduleGeometry() = " << si_strip_det_id.moduleGeometry() << endl;
Expand Down
Expand Up @@ -8,6 +8,7 @@
#include "DataFormats/Common/interface/DetSetVectorNew.h"
#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "Geometry/Records/interface/TrackerTopologyRcd.h"
#include "DataFormats/SiStripDetId/interface/SiStripDetId.h"

ShallowClustersProducer::ShallowClustersProducer(const edm::ParameterSet& iConfig)
: Prefix(iConfig.getParameter<std::string>("Prefix") )
Expand Down
Expand Up @@ -69,7 +69,7 @@ SiStripBackPlaneCorrectionFakeESSource::produce(const SiStripBackPlaneCorrection

const edm::Service<SiStripDetInfoFileReader> reader;
for ( const auto& detId : reader->getAllDetIds() ) {
unsigned int moduleGeometry = tTopo->moduleGeometry(DetId(detId))-1;
const auto moduleGeometry = static_cast<unsigned int>(tTopo->moduleGeometry(DetId(detId)))-1;
if ( moduleGeometry > m_valuePerModuleGeometry.size() ) {
edm::LogError("SiStripBackPlaneCorrectionGenerator") << " BackPlaneCorrection_PerModuleGeometry only contains " << m_valuePerModuleGeometry.size() << "elements and module is out of range";
}
Expand Down
Expand Up @@ -20,6 +20,7 @@

#include "CondFormats/SiStripObjects/interface/SiStripBadStrip.h"
#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "DataFormats/SiStripDetId/interface/SiStripDetId.h"
#include "CondFormats/DataRecord/interface/SiStripCondDataRecords.h"
#include "FWCore/ParameterSet/interface/ParameterSet.h"

Expand Down
Expand Up @@ -30,6 +30,8 @@
#include "CondFormats/SiStripObjects/interface/SiStripLorentzAngle.h"
#include "CondFormats/DataRecord/interface/SiStripCondDataRecords.h"
#include "FWCore/ParameterSet/interface/ParameterSet.h"
#include "DataFormats/SiStripDetId/interface/SiStripDetId.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"

class SiStripLorentzAngleFakeESSource : public edm::ESProducer, public edm::EventSetupRecordIntervalFinder {
public:
Expand Down
Expand Up @@ -17,6 +17,7 @@

#include "CalibTracker/SiStripHitEfficiency/interface/HitEff.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"
#include "DataFormats/SiStripDetId/interface/SiStripDetId.h"
#include "DataFormats/Common/interface/Handle.h"
#include "DataFormats/GeometryVector/interface/GlobalPoint.h"
#include "DataFormats/GeometryVector/interface/GlobalVector.h"
Expand Down
1 change: 1 addition & 0 deletions CalibTracker/SiStripLorentzAngle/src/LA_Filler.cc
@@ -1,5 +1,6 @@
#include "CalibTracker/SiStripLorentzAngle/interface/LA_Filler_Fitter.h"
#include "CalibTracker/SiStripCommon/interface/TTREE_FOREACH_ENTRY.hh"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"

#include <cmath>
#include <boost/lexical_cast.hpp>
Expand Down
Expand Up @@ -21,6 +21,7 @@

#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "Geometry/Records/interface/TrackerTopologyRcd.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"

#include <iostream>
#include <iomanip>
Expand Down
Expand Up @@ -3,6 +3,7 @@
#include "FWCore/MessageLogger/interface/MessageLogger.h"
#include "DataFormats/DetId/interface/DetId.h"
#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"
#include "Geometry/TrackerGeometryBuilder/interface/StripGeomDetUnit.h"
#include "Geometry/CommonTopologies/interface/StripTopology.h"
#include "CalibFormats/SiStripObjects/interface/SiStripQuality.h"
Expand Down
Expand Up @@ -4,6 +4,7 @@
#include "FWCore/MessageLogger/interface/MessageLogger.h"
#include "DataFormats/DetId/interface/DetId.h"
#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"
#include "Geometry/TrackerGeometryBuilder/interface/StripGeomDetUnit.h"
#include "Geometry/CommonTopologies/interface/StripTopology.h"
#include "CalibFormats/SiStripObjects/interface/SiStripQuality.h"
Expand Down
@@ -1,5 +1,6 @@
#include "CalibTracker/SiStripQuality/interface/SiStripHotStripAlgorithmFromClusterOccupancy.h"
#include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"

SiStripHotStripAlgorithmFromClusterOccupancy::SiStripHotStripAlgorithmFromClusterOccupancy(
const edm::ParameterSet& iConfig, const TrackerTopology* theTopo)
Expand Down
Expand Up @@ -2,6 +2,7 @@

#include "tinyxml2.h"
#include "FWCore/Utilities/interface/Exception.h"
#include "DataFormats/SiStripDetId/interface/StripSubdetector.h"

namespace {
// split into tokens and convert them to uint32_t
Expand Down
6 changes: 3 additions & 3 deletions CommonTools/CandUtils/interface/AddFourMomenta.h 100755 → 100644
Expand Up @@ -17,11 +17,11 @@

struct AddFourMomenta {
/// default constructor
AddFourMomenta() { }
AddFourMomenta() {}
/// constructor
explicit AddFourMomenta( const edm::ParameterSet & ) { }
explicit AddFourMomenta(const edm::ParameterSet&) {}
/// set up a candidate
void set( reco::Candidate& c ) const;
void set(reco::Candidate& c) const;
};

#endif
6 changes: 3 additions & 3 deletions CommonTools/CandUtils/interface/ApplyEnergyCorrection.h
Expand Up @@ -15,10 +15,10 @@
#include "DataFormats/Candidate/interface/CandidateFwd.h"

struct ApplyEnergyCorrection {
ApplyEnergyCorrection( double correction ) : correction_( correction ) { }
ApplyEnergyCorrection(double correction) : correction_(correction) {}
/// set up a candidate
void set( reco::Candidate& c );
void set(reco::Candidate& c);

private:
double correction_;
};
Expand Down
5 changes: 3 additions & 2 deletions CommonTools/CandUtils/interface/Booster.h 100755 → 100644
Expand Up @@ -16,9 +16,10 @@

struct Booster {
/// constructor from a boost vector
Booster( const math::XYZVector & b ) : boost( b ) { }
Booster(const math::XYZVector& b) : boost(b) {}
/// set up a candidate kinematics according to the boost
void set( reco::Candidate& c );
void set(reco::Candidate& c);

private:
const math::XYZVector boost;
};
Expand Down

0 comments on commit 29a76e9

Please sign in to comment.