37 : nSigmas_(
pset.getUntrackedParameter<unsigned
int>(
"nSigmasFitRange", 1)),
43 bool debug =
pset.getUntrackedParameter<
bool>(
"debug",
false);
69 throw cms::Exception(
"Configuration") <<
"only version 1 is presently supported for VDriftDB";
82 throw cms::Exception(
"DTCalibration") <<
"Could not find vDrift entry in DB for" << slId << endl;
89 LogTrace(
"Calibration") <<
"[DTVDriftSegment]: RZ superlayer\n" 90 <<
" Will use original vDrift and resolution.";
93 TH1F* vDriftCorrHisto =
getHisto(slId);
95 if (vDriftCorrHisto->GetEntries() == 0) {
96 LogError(
"Calibration") <<
"[DTVDriftSegment]: Histogram " << vDriftCorrHisto->GetName() <<
" is empty.\n" 97 <<
" Will use original vDrift and resolution.";
101 LogTrace(
"Calibration") <<
"[DTVDriftSegment]: Fitting histogram " << vDriftCorrHisto->GetName();
103 LogTrace(
"Calibration") <<
"[DTVDriftSegment]: \n" 107 float vDriftCorr = fitResult.
fitMean;
108 float vDriftNew = vDrift * (1. - vDriftCorr);
130 string chHistoName =
"_W" +
wheel +
"_St" +
station +
"_Sec" + sector;
132 return (slId.
superLayer() != 2) ? (
"hRPhiVDriftCorr" + chHistoName) : (
"hRZVDriftCorr" + chHistoName);
int station() const
Return the station number.
float get(const DTWireId &wireid, double *x=nullptr) const
Get the value correspoding to the given WireId, / using x[] as parameters of the parametrization when...
int superLayer() const
Return the superlayer number.
int version() const
Version numer specifying the structure of the payload. See .cc file for details.
std::string to_string(const V &value)
int get(int wheelId, int stationId, int sectorId, int slId, float &mTime, float &mTrms, DTTimeUnits::type unit) const
Log< level::Error, false > LogError
std::string getHistoName(const DTSuperLayerId &)
DTChamberId chamberId() const
Return the corresponding ChamberId.
edm::ESGetToken< DTMtime, DTMtimeRcd > mTimeMapToken_
void setES(const edm::EventSetup &setup) override
edm::ESGetToken< DTRecoConditions, DTRecoConditionsVdriftRcd > vDriftMapToken_
const DTRecoConditions * vDriftMap_
const DTMtime * mTimeMap_
DTResidualFitResult fitResiduals(TH1F &histo, int nSigmas=1)
constexpr uint32_t rawId() const
get the raw id
DTResidualFitter * fitter_
int wheel() const
Return the wheel number.
~DTVDriftSegment() override
TH1F * getHisto(const DTSuperLayerId &)
DTVDriftData compute(const DTSuperLayerId &) override