36 granularity_( pset.getUntrackedParameter<string>(
"calibGranularity",
"bySL") ) {
38 LogVerbatim(
"Calibration") <<
"[DTVDriftWriter]Constructor called!";
41 throw cms::Exception(
"Configuration") <<
"[DTVDriftWriter] Check parameter calibGranularity: " <<
granularity_ <<
" option not available.";
44 string algoName = pset.
getParameter<
string>(
"vDriftAlgo");
50 LogVerbatim(
"Calibration") <<
"[DTVDriftWriter]Destructor called!";
72 const vector<DTSuperLayer*>& superLayers =
dtGeom_->superLayers();
73 vector<DTSuperLayer*>::const_iterator sl = superLayers.begin();
74 vector<DTSuperLayer*>::const_iterator sl_end = superLayers.end();
75 for(; sl != sl_end; ++sl){
85 float vDriftNew = vDriftData.
vdrift;
88 mTimeNewMap->
set(slId,
92 LogVerbatim(
"Calibration") <<
"vDrift for: " << slId
93 <<
" Mean " << vDriftNew
94 <<
" Resolution " << resolutionNew;
99 mTimeNewMap->
set(slId,
103 LogVerbatim(
"Calibration") <<
"Keep original vDrift for: " << slId
104 <<
" Mean " << vDrift
112 LogVerbatim(
"Calibration") <<
"[DTVDriftWriter]Writing vdrift object to DB!";
113 string record =
"DTMtimeRcd";
114 DTCalibDBUtils::writeToDB<DTMtime>(
record, mTimeNewMap);
T getParameter(std::string const &) const
edm::ESHandle< DTGeometry > dtGeom_
int set(int wheelId, int stationId, int sectorId, int slId, float mTime, float mTrms, DTTimeUnits::type unit)
virtual std::string explainSelf() const
virtual void beginRun(const edm::Run &run, const edm::EventSetup &setup)
DTVDriftBaseAlgo * vDriftAlgo_
virtual ~DTVDriftWriter()
DTVDriftWriter(const edm::ParameterSet &pset)
virtual void setES(const edm::EventSetup &setup)=0
int get(int wheelId, int stationId, int sectorId, int slId, float &mTime, float &mTrms, DTTimeUnits::type unit) const
const DTMtime * mTimeMap_
virtual DTVDriftData compute(const DTSuperLayerId &)=0
void setup(std::vector< TH2F > &depth, std::string name, std::string units="")
T get(const Candidate &c)