ATLAS Offline Software
GMTreeBrowser.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // GMTreeBrowser.h, (c) ATLAS Detector software
8 
9 #ifndef TRKDETDESCRGEOMODELCNV_GMTREEBROWSER_H
10 #define TRKDETDESCRGEOMODELCNV_GMTREEBROWSER_H
11 
12 #include <GeoModelKernel/GeoDefinitions.h>
13 
14 #include <vector>
15 
16 class GeoVPhysVol;
17 class GeoShape;
18 
19 namespace Trk {
20 
31 
32  public:
34  GMTreeBrowser() = default;
35 
37  ~GMTreeBrowser() = default;
38 
45  int compareGeoVolumes(const GeoVPhysVol* gv1, const GeoVPhysVol* gv2,
46  double tolerance, bool printFullInfo = false,
47  int level = 0) const;
48 
50  bool compareShapes(const GeoShape* gs1, const GeoShape* gv2,
51  double tolerance) const;
52 
54  bool findNamePattern(const GeoVPhysVol* gv, std::string_view name) const;
55 
58  static const GeoVPhysVol* findTopBranch(const GeoVPhysVol* gv,
59  std::string_view name) ;
60 
61  private:
63  static bool identity_check(GeoTrf::RotationMatrix3D rotation, double tol) ;
65  static void printTranslationDiff(GeoTrf::Transform3D trtest,
66  GeoTrf::Transform3D trref,
67  double tolerance) ;
68  static void printRotationDiff(const GeoTrf::Transform3D& trtest,
69  const GeoTrf::Transform3D& trref, double tolerance) ;
70 };
71 
72 } // end of namespace Trk
73 
74 #endif
Trk::GMTreeBrowser::~GMTreeBrowser
~GMTreeBrowser()=default
Destructor.
Trk::GMTreeBrowser::printRotationDiff
static void printRotationDiff(const GeoTrf::Transform3D &trtest, const GeoTrf::Transform3D &trref, double tolerance)
Definition: GMTreeBrowser.cxx:483
Trk::GMTreeBrowser::findNamePattern
bool findNamePattern(const GeoVPhysVol *gv, std::string_view name) const
search of matching name patterns
Definition: GMTreeBrowser.cxx:398
python.iconfTool.models.loaders.level
level
Definition: loaders.py:20
Trk::GMTreeBrowser::identity_check
static bool identity_check(GeoTrf::RotationMatrix3D rotation, double tol)
check of rotation invariance
Definition: GMTreeBrowser.cxx:450
Trk::GMTreeBrowser::compareGeoVolumes
int compareGeoVolumes(const GeoVPhysVol *gv1, const GeoVPhysVol *gv2, double tolerance, bool printFullInfo=false, int level=0) const
Recursive comparison of trees/branches/volumes : in quiet mode (printFullInfo=False) ,...
Definition: GMTreeBrowser.cxx:42
Trk::GMTreeBrowser
Definition: GMTreeBrowser.h:30
Trk::GMTreeBrowser::printTranslationDiff
static void printTranslationDiff(GeoTrf::Transform3D trtest, GeoTrf::Transform3D trref, double tolerance)
printout diff - unify output
Definition: GMTreeBrowser.cxx:463
xAOD::rotation
rotation
Definition: TrackSurface_v1.cxx:15
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
Trk::GMTreeBrowser::findTopBranch
static const GeoVPhysVol * findTopBranch(const GeoVPhysVol *gv, std::string_view name)
search of top branch : returns mother volume for children matching name
Definition: GMTreeBrowser.cxx:442
tolerance
Definition: suep_shower.h:17
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
Amg::RotationMatrix3D
Eigen::Matrix< double, 3, 3 > RotationMatrix3D
Definition: GeoPrimitives.h:49
Trk::GMTreeBrowser::compareShapes
bool compareShapes(const GeoShape *gs1, const GeoShape *gv2, double tolerance) const
shape comparison
Definition: GMTreeBrowser.cxx:182
Trk::GMTreeBrowser::GMTreeBrowser
GMTreeBrowser()=default
Default constructor.