|
|
Go to the documentation of this file.
70 #include "CLHEP/Matrix/SymMatrix.h"
143 theCurrentTracker(nullptr),
172 m_treeErrors =
new TTree(
"alignTreeErrors",
"alignTreeErrors");
218 for (std::vector<AlignTransform>::const_iterator
i = theAlignments->
m_align.begin();
222 CLHEP::Hep3Vector translation =
i->translation();
223 m_x = translation.x();
224 m_y = translation.y();
225 m_z = translation.z();
227 CLHEP::HepRotation
rotation =
i->rotation();
243 delete theAlignments;
245 std::vector<AlignTransformErrorExtended> alignErrors = alignmentErrors->m_alignError;
246 for (std::vector<AlignTransformErrorExtended>::const_iterator
i = alignErrors.begin();
i != alignErrors.end(); ++
i) {
248 CLHEP::HepSymMatrix errMatrix =
i->matrix();
251 m_xx = errMatrix[0][0];
252 m_xy = errMatrix[0][1];
253 m_xz = errMatrix[0][2];
254 m_yy = errMatrix[1][1];
255 m_yz = errMatrix[1][2];
256 m_zz = errMatrix[2][2];
261 auto const& detUnits = theCurTracker->
detUnits();
264 for (
auto iunit = detUnits.begin(); iunit != detUnits.end(); ++iunit) {
265 DetId detid = (*iunit)->geographicalId();
271 auto geomDetUnit = *iunit;
274 if (geomDetUnit->surfaceDeformation()) {
275 std::vector<double> surfaceDeformParams = (geomDetUnit->surfaceDeformation())->
parameters();
277 m_dNpar = surfaceDeformParams.size();
278 m_dtype = (geomDetUnit->surfaceDeformation())->
type();
279 m_d1 = surfaceDeformParams.at(0);
280 m_d2 = surfaceDeformParams.at(1);
281 m_d3 = surfaceDeformParams.at(2);
283 for (std::vector<double>::const_iterator it = surfaceDeformParams.begin(); it != surfaceDeformParams.end();
UInt_t numDeformationValues_
std::vector< double > * mp_dpar
TrackerGeometry * build(const GeometricDet *gd, const PTrackerAdditionalParametersPerDet *ptitp, const PTrackerParameters &ptp, const TrackerTopology *tTopo)
AlignableTracker * theCurrentTracker
Float_t deformationValues_[kMaxNumPar]
std::string m_outputTreename
T getUntrackedParameter(std::string const &, T const &) const
Log< level::Info, false > LogInfo
const edm::ESGetToken< PTrackerAdditionalParametersPerDet, PTrackerAdditionalParametersPerDetRcd > ptitpToken_
void applyAlignments(const C *geometry, const Alignments *alignments, const AlignmentErrorsExtended *alignmentErrors, const AlignTransform &globalCoordinates)
const edm::ESGetToken< PTrackerParameters, PTrackerParametersRcd > ptpToken_
const edm::ESGetToken< Alignments, TrackerAlignmentRcd > aliToken_
#define DEFINE_FWK_MODULE(type)
const DetContainer & detUnits() const override
Returm a vector of all GeomDet.
const edm::ESGetToken< AlignmentSurfaceDeformations, TrackerSurfaceDeformationRcd > surfDefToken_
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum)
const edm::ESGetToken< Alignments, GlobalPositionRcd > gprToken_
const AlignTransform & DetectorGlobalPosition(const Alignments &allGlobals, const DetId &id)
TrackerGeometryIntoNtuples(const edm::ParameterSet &)
void analyze(const edm::Event &iEvent, const edm::EventSetup &iSetup) override
const edm::ESGetToken< GeometricDet, IdealGeometryRecord > geomDetToken_
bool getData(T &iHolder) const
void attachSurfaceDeformations(const C *geometry, const AlignmentSurfaceDeformations *surfaceDeformations)
~TrackerGeometryIntoNtuples() override
constexpr uint32_t rawId() const
get the raw id
Alignments * alignments() const override
Return alignments, sorted by DetId.
const edm::ESGetToken< AlignmentErrorsExtended, TrackerAlignmentErrorExtendedRcd > aliErrorToken_
const edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > topoToken_
std::vector< AlignTransform > m_align
Class to update a given geometry with a set of alignments.
TTree * m_treeDeformations