ATLAS Offline Software
Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | Static Private Attributes | List of all members
Trk::TrackingVolumeDisplayer Class Reference

#include <TrackingVolumeDisplayer.h>

Inheritance diagram for Trk::TrackingVolumeDisplayer:
Collaboration diagram for Trk::TrackingVolumeDisplayer:

Public Member Functions

 TrackingVolumeDisplayer (const std::string &, const std::string &, const IInterface *)
 Constructor. More...
 
virtual ~TrackingVolumeDisplayer ()
 Destructor. More...
 
StatusCode initialize ()
 AlgTool initialize method. More...
 
StatusCode finalize ()
 AlgTool finalize method. More...
 
virtual StatusCode process (TrackingGeometry &tgeo) const
 Processor Action to work on TrackingGeometry& tgeo. More...
 
virtual StatusCode process (TrackingVolume &tvol, size_t level=0) const
 Processor Action to work on TrackingVolumes - the level is for the hierachy tree. More...
 
virtual StatusCode process (Layer &lay, size_t level=0) const
 Processor Action to work on Layers. More...
 
virtual StatusCode process (Surface &surf, size_t level=0) const
 Processor Action to work on Surfaces. More...
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 
 DeclareInterfaceID (IGeometryProcessor, 1, 0)
 Creates the InterfaceID and interfaceID() method. More...
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
 
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed. More...
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

StatusCode processNode (const TrackingVolume &tvol, size_t level=0) const
 Current implementation: write root visualization to file stream. More...
 
StatusCode processNode (const Layer &lay, size_t level=0) const
 Current implementation: write root visualization to file stream. More...
 
StatusCode processNode (const Surface &, size_t level=0) const
 Current implementation: write root visualization to file stream. More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Static Private Member Functions

static void openFile (std::ofstream &output, const std::string &filename)
 File handling: open + write header. More...
 
static void closeFile (std::ofstream &output)
 File handling: write footer + close. More...
 
static int colorCodeFromMaterial (const Trk::MaterialProperties *prop, std::ofstream &output)
 calculate the color code from the Material More...
 

Private Attributes

int m_volumeCounter
 volume counter More...
 
std::ofstream m_fileVolumeOutput
 file output for visualization action More...
 
std::string m_fileVolumeOutputName
 file name for visualization action More...
 
bool m_fileVolumeOutputMode
 steer writing More...
 
std::ofstream m_fileLayerOutput
 file output for visualization action More...
 
std::string m_fileLayerOutputName
 file name for visualization action More...
 
bool m_fileLayerOutputMode
 steer writing More...
 
std::ofstream m_fileSurfaceOutput
 file output for visualization action More...
 
std::string m_fileSurfaceOutputName
 file name for visualization action More...
 
bool m_fileSurfaceOutputMode
 steer writing More...
 
bool m_fileSurfaceOutputSplit
 use one file for each layer More...
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Static Private Attributes

static int s_displaySurfaces = 0
 static surface counter More...
 

Detailed Description

The TrackingVolumeDisplayer writes a root .C file which can be executed and used the OpenGL root viewer

Author
Andre.nosp@m.as.S.nosp@m.alzbu.nosp@m.rger.nosp@m.@cern.nosp@m..ch

Definition at line 34 of file TrackingVolumeDisplayer.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ TrackingVolumeDisplayer()

Trk::TrackingVolumeDisplayer::TrackingVolumeDisplayer ( const std::string &  t,
const std::string &  n,
const IInterface *  p 
)

Constructor.

Definition at line 36 of file TrackingVolumeDisplayer.cxx.

36  :
38  m_volumeCounter(0),
39  m_fileVolumeOutputName("TrackingGeometryVolumeDisplay.C"),
41  m_fileLayerOutputName("TrackingGeometryLayerDisplay.C"),
43  m_fileSurfaceOutputName("TrackingGeometrySurfaceDisplay.C"),
46 {
47  // set name and output type
48  declareProperty("TrackingVolumeOutputFile", m_fileVolumeOutputName);
49  declareProperty("TrackingVolumeOutput", m_fileVolumeOutputMode);
50  declareProperty("LayerOutputFile", m_fileLayerOutputName);
51  declareProperty("LayerOutput", m_fileLayerOutputMode);
52  declareProperty("SurfaceOutputFile", m_fileSurfaceOutputName);
53  declareProperty("SurfaceOutput", m_fileSurfaceOutputMode);
54  declareProperty("SurfaceOutputSplit", m_fileSurfaceOutputSplit);
55 }

◆ ~TrackingVolumeDisplayer()

Trk::TrackingVolumeDisplayer::~TrackingVolumeDisplayer ( )
virtualdefault

Destructor.

Member Function Documentation

◆ closeFile()

void Trk::TrackingVolumeDisplayer::closeFile ( std::ofstream &  output)
staticprivate

File handling: write footer + close.

Definition at line 118 of file TrackingVolumeDisplayer.cxx.

119 {
120  out << "worldnode->cd();" << '\n';
121  out << "worldnode->Draw(\"ogl\");" << '\n';
122  out << "tg->Update();" << '\n';
123  out << "}" << '\n';
124  out.close();
125 }

◆ colorCodeFromMaterial()

int Trk::TrackingVolumeDisplayer::colorCodeFromMaterial ( const Trk::MaterialProperties prop,
std::ofstream &  output 
)
staticprivate

calculate the color code from the Material

Definition at line 372 of file TrackingVolumeDisplayer.cxx.

373 {
374  if (!prop) return 6;
375  // start from 100 and reduce by radiation length
376  int color = 100;
377  double tInX0 = prop->thicknessInX0();
378  // write out a comment line
379  output << "// MaterialProperties : t/X0 = " << tInX0 << std::endl;
380  output << "// zOverAtimesRho : Z/A*rho = " << prop->zOverAtimesRho() << std::endl;
381  // 0 % : --> color code 100
382  // 4 % : --> color code 52
383  color -= int(tInX0 * 1200);
384  return color;
385 }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ DeclareInterfaceID()

Trk::IGeometryProcessor::DeclareInterfaceID ( IGeometryProcessor  ,
,
 
)
inherited

Creates the InterfaceID and interfaceID() method.

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ finalize()

StatusCode Trk::TrackingVolumeDisplayer::finalize ( )

AlgTool finalize method.

Definition at line 87 of file TrackingVolumeDisplayer.cxx.

88 {
89  ATH_MSG_INFO( "finalize() successful" );
90 
91  // open the file for writing
94  // open the file for writing
97  // open the file for writing
100 
101  return StatusCode::SUCCESS;
102 }

◆ initialize()

StatusCode Trk::TrackingVolumeDisplayer::initialize ( )

AlgTool initialize method.

Definition at line 63 of file TrackingVolumeDisplayer.cxx.

64 {
65 
66  ATH_MSG_INFO( "initialize()" );
67 
69  ATH_MSG_FATAL("Could not initialize base tool. Aborting.");
70  return StatusCode::FAILURE;
71  }
72 
73  // open the file for writing
76  // open the file for writing
79  // open the file for writing
82 
83  return StatusCode::SUCCESS;
84 
85 }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ msg() [1/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ openFile()

void Trk::TrackingVolumeDisplayer::openFile ( std::ofstream &  output,
const std::string &  filename 
)
staticprivate

File handling: open + write header.

Definition at line 105 of file TrackingVolumeDisplayer.cxx.

106 {
107  // open the file
108  out.open(filename.c_str());
109  // write the header
110  out << "{" << '\n';
111  out << "tg = new TCanvas(\"tg\",\"Geometry Shapes\",200,10,700,500);" <<'\n';
112  out << " world = new TBRIK(\"BRIK\",\"BRIK\",\"void\",2,2,2);" << '\n';
113  out << " worldnode = new TNode(\"NODE1\",\"NODE1\",\"BRIK\");" << '\n';
114  out << " worldnode->cd();" << '\n';
115 }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ process() [1/4]

StatusCode Trk::RecursiveGeometryProcessor::process ( Trk::Layer lay,
size_t  level = 0 
) const
virtualinherited

Processor Action to work on Layers.

Implements Trk::IGeometryProcessor.

Definition at line 128 of file RecursiveGeometryProcessor.cxx.

128  {
129 
130  std::stringstream displayBuffer;
131  for (size_t il = 0; il < level; ++il) displayBuffer << " ";
132  ATH_MSG_VERBOSE(displayBuffer.str() << " processing Layer with Index: " << lay.layerIndex() );
133 
134  // process the node itself
135  if (processNode(lay, level).isFailure()){
136  ATH_MSG_FATAL("Failed to call processNode(const Layer&). Aborting.");
137  return StatusCode::FAILURE;
138  }
139  // get the subsurface array
140  Trk::SurfaceArray* surfArray = lay.surfaceArray();
141  if (surfArray) {
142  Trk::BinnedArraySpan<Trk::Surface * const > layerSurfaces = surfArray->arrayObjects();
143  ATH_MSG_VERBOSE(displayBuffer.str() << " ---> has " << layerSurfaces.size() << " surfaces on the layer.");
144 
145  auto laySurfIter = layerSurfaces.begin();
146  auto laySurfIterEnd = layerSurfaces.end();
147  // loop over the surfaces and draw them
148  for ( ; laySurfIter != laySurfIterEnd; ++laySurfIter) {
149  if (!(*laySurfIter))
150  ATH_MSG_WARNING("Zero-pointer found in SurfaceArray - indicates problem !");
151  if ((*laySurfIter) && process(**laySurfIter, level).isFailure()){
152  ATH_MSG_FATAL("Failed to call process(const Surface&) on confined layer surfaces. Aborting.");
153  return StatusCode::FAILURE;
154  }
155  }
156  }
157  // return SUCCESS
158  return StatusCode::SUCCESS;
159 }

◆ process() [2/4]

StatusCode Trk::RecursiveGeometryProcessor::process ( Trk::Surface surf,
size_t  level = 0 
) const
virtualinherited

Processor Action to work on Surfaces.

Implements Trk::IGeometryProcessor.

Definition at line 162 of file RecursiveGeometryProcessor.cxx.

162  {
163  return processNode(surf, level);
164 }

◆ process() [3/4]

StatusCode Trk::RecursiveGeometryProcessor::process ( Trk::TrackingGeometry tgeo) const
virtualinherited

Processor Action to work on TrackingGeometry& tgeo.

Implements Trk::IGeometryProcessor.

Definition at line 46 of file RecursiveGeometryProcessor.cxx.

46  {
47 
48  ATH_MSG_VERBOSE("Start processing the TrackingGeometry recursively");
49  // retrieve the highest tracking volume
50  Trk::TrackingVolume* worldVolume = tgeo.highestTrackingVolume();
51  if (worldVolume){
52  ATH_MSG_VERBOSE("TrackingVolume '" << worldVolume->volumeName() << "' retrieved as highest level node.");
53  return process(*worldVolume, 0);
54  }
55  // abort job
56  ATH_MSG_FATAL("No highest level TrackingVolume found. Stopping recursive parsing, abort job.");
57  return StatusCode::FAILURE;
58 }

◆ process() [4/4]

StatusCode Trk::RecursiveGeometryProcessor::process ( Trk::TrackingVolume tvol,
size_t  level = 0 
) const
virtualinherited

Processor Action to work on TrackingVolumes - the level is for the hierachy tree.

Implements Trk::IGeometryProcessor.

Definition at line 61 of file RecursiveGeometryProcessor.cxx.

61  {
62 
63  std::stringstream displayBuffer;
64  for (size_t il = 0; il < level; ++il) displayBuffer << " ";
65  // formatted screen output
66  ATH_MSG_VERBOSE(displayBuffer.str() << "TrackingVolume '" << tvol.volumeName() << "'");
67 
68  // create the action on the volume part of the TrackingVolume
69  if (processNode(tvol, level).isFailure() ){
70  ATH_MSG_FATAL("Failed to call processNode(const TrackingVolume&). Aborting.");
71  return StatusCode::FAILURE;
72  }
73 
74  // Process the contained layers if they exist
75  Trk::LayerArray* layerArray = tvol.confinedLayers();
76  if (layerArray) {
77  // display output
78  auto layers = layerArray->arrayObjects();
79  ATH_MSG_VERBOSE(displayBuffer.str() << "--> has " << layers.size() << " confined layers." );
80  for (const auto & layIter : layers){
81  if (!layIter)
82  ATH_MSG_WARNING("Zero-pointer found in LayerArray - indicates problem !");
83  if ((layIter) && process(*layIter, level).isFailure()){
84  ATH_MSG_FATAL("Failed to call process(const Layer&) on confined layers. Aborting.");
85  return StatusCode::FAILURE;
86  }
87  }
88  }
89 
90  // Process the boundary surface layers
91  auto bSurfaces = tvol.boundarySurfaces();
92  for (auto & bSurface : bSurfaces){
93  if (bSurface->surfaceRepresentation().associatedLayer()){
94  ATH_MSG_VERBOSE(displayBuffer.str() << "--> has a boundary layer." );
95  if (process(
96  const_cast<Trk::Layer&>(
97  *bSurface->surfaceRepresentation().associatedLayer()),level)
98  .isFailure()) {
99  ATH_MSG_FATAL("Failed to call process(const Layer&) on boundary "
100  "layer. Aborting.");
101  return StatusCode::FAILURE;
102  }
103  }
104  }
105 
106 
107  // Process the contained TrackingVolumes (recursively) if they exist
109  // register the next round
110  if (confinedVolumes) {
111  auto volumes = confinedVolumes->arrayObjects();
112  for (const auto & volumesIter : volumes){
113  if (!volumesIter)
114  ATH_MSG_WARNING("Zero-pointer found in VolumeArray - indicates problem !");
115  if (volumesIter && process(*volumesIter, ++level).isFailure() ){
116  ATH_MSG_FATAL("Failed to call process(const TrackingVolume&) on confined volumes. Aborting.");
117  return StatusCode::FAILURE;
118  }
119  }
120  }
121 
122  // return
123  return StatusCode::SUCCESS;
124 
125 }

◆ processNode() [1/3]

StatusCode Trk::TrackingVolumeDisplayer::processNode ( const Layer lay,
size_t  level = 0 
) const
privatevirtual

Current implementation: write root visualization to file stream.

Reimplemented from Trk::RecursiveGeometryProcessor.

Definition at line 166 of file TrackingVolumeDisplayer.cxx.

167 {
168 
169  ATH_MSG_VERBOSE("Writing display information for Layer.");
170  // get the identifier
171  int layerIndex = lay.layerIndex().value();
172  int layerIndexStr = (layerIndex < 0) ? (-layerIndex)+1 : layerIndex;
173  // the layer position
174  const Amg::Vector3D& layerPosition = lay.surfaceRepresentation().center();
175  double layerPositionZ = layerPosition.z();
176  // output mode
178  std::stringstream ss;
179  std::string str;
180  ss << "Layer" << layerIndexStr << "_" << m_fileSurfaceOutputName;
181  ss >> str;
183  m_fileSurfaceOutput<<"// Enclosing Volume: "<<lay.enclosingTrackingVolume()->volumeName()<<std::endl;
184  }
185 
187  const Trk::SurfaceArray* surfArray = lay.surfaceArray();
188  if (surfArray) {
189  const auto & layerSurfaces = surfArray->arrayObjects();
190  // loop over the surfaces and draw them
191  for (const auto & laySurfIter : layerSurfaces) {
192  if ( laySurfIter && processNode(*laySurfIter).isFailure()){
193  ATH_MSG_FATAL("Failed to call processNode(const Surface& sf) on sub surface. Abort.");
194  return StatusCode::FAILURE;
195  }
196  }
197  }
198  }
201 
202  const Trk::Surface& lSurface = lay.surfaceRepresentation();
203  int layerColor = lay.enclosingTrackingVolume() ? lay.enclosingTrackingVolume()->colorCode() : 22;
204 
205  // CYLINDER SECTION
206  if (lSurface.type() == Trk::SurfaceType::Cylinder && layerIndex > 0) {
207  // get the Bounds
208  const Trk::CylinderBounds* cylBo = dynamic_cast<const Trk::CylinderBounds*>(&lSurface.bounds());
209  if (!cylBo) {
210  m_fileLayerOutput << "ERROR Cylinder surface without CylinderBounds\n";
211  return StatusCode::FAILURE;
212  }
213  else {
214  // set the boundaries
215  double radius = cylBo->r();
216  double halfZ = cylBo->halflengthZ();
217  m_fileLayerOutput << "Cylinder" << layerIndexStr << " = new TTUBE(\"CylinderLayer";
218  m_fileLayerOutput << layerIndexStr << "\",\"CylinderLayer" << layerIndex << "\",\"void\",";
219  m_fileLayerOutput << int(radius-5) << "," << int(radius+5) << "," << int(halfZ) << ");" << '\n';
220  // get the line color
221  m_fileLayerOutput << "Cylinder" << layerIndexStr << "->SetLineColor(" << layerColor << ");" << '\n';
222  // write the node
223  m_fileLayerOutput <<"Node" << layerIndexStr << " = new TNode(\"CylinderNode" << layerIndex;
224  m_fileLayerOutput << "\",\"CylinderNode" << layerIndexStr << "\",\"CylinderLayer";
225  m_fileLayerOutput << layerIndexStr << "\"," << 0 << "," << 0 << "," << int(layerPositionZ) << ");" << '\n';
226  m_fileLayerOutput <<'\n';
227 
228  return StatusCode::SUCCESS;
229  }
230  } else if (lSurface.type() == Trk::SurfaceType::Disc && layerIndex > 0) {
231  // get the Bounds
232  const Trk::DiscBounds* discBo = dynamic_cast<const Trk::DiscBounds*>(&lSurface.bounds());
233  if (!discBo) {
234  m_fileLayerOutput << "ERROR Disc surface without DiscBounds\n";
235  return StatusCode::FAILURE;
236  }
237  else {
238 
239  // set the boundaries
240  double rMin = discBo->rMin();
241  double rMax = discBo->rMax();
242 
243  m_fileLayerOutput << "Disc" << layerIndexStr << " = new TTUBE(\"DiscLayer" << layerIndexStr << "\",\"DiscLayer" << layerIndex << "\",\"void\",";
244  m_fileLayerOutput << int(rMin+1.) << "," << int(rMax-1.) << ",10);" << '\n';
245  // get the line color
246  m_fileLayerOutput << "Disc" << layerIndexStr << "->SetLineColor(" << layerColor << ");" << '\n';
247  // write the node
248  m_fileLayerOutput << "DiscNode" << layerIndexStr << " = new TNode(\"DiscNode" << layerIndex;
249  m_fileLayerOutput << "\",\"DiscNode" << layerIndexStr << "\",\"DiscLayer";
250  m_fileLayerOutput << layerIndexStr << "\"," << 0 << "," << 0 << "," << int(layerPositionZ) << ");" << '\n';
251  m_fileLayerOutput <<'\n';
252  return StatusCode::SUCCESS;
253  }
254  }
255  return StatusCode::SUCCESS;
256 }

◆ processNode() [2/3]

StatusCode Trk::TrackingVolumeDisplayer::processNode ( const Surface sf,
size_t  level = 0 
) const
privatevirtual

Current implementation: write root visualization to file stream.

Reimplemented from Trk::RecursiveGeometryProcessor.

Definition at line 259 of file TrackingVolumeDisplayer.cxx.

260 {
261 
263 
264  ATH_MSG_VERBOSE("Writing display information for Surface.");
265 
266 
267  m_fileSurfaceOutput << "// ---------------------- Surface -------------------------------// " << std::endl;
268 
269  // surface center
270  double surfX = sf.center().x();
271  double surfY = sf.center().y();
272  double surfZ = sf.center().z();
273  // rotation matrix
274  const Amg::RotationMatrix3D sfRot = sf.transform().rotation();
275 
276  // ROOT wants the angles in degrees
277  const double convFac = 180./M_PI;
278  double xPhi = sfRot.col(0).phi()*convFac;
279  double xTheta = sfRot.col(0).theta()*convFac;
280  double yPhi = sfRot.col(1).phi()*convFac;
281  double yTheta = sfRot.col(1).theta()*convFac;
282  double zPhi = sfRot.col(2).phi()*convFac;
283  double zTheta = sfRot.col(2).theta()*convFac;
284 
285  // surface
286  TString surfaceString = "Surface_";
287  surfaceString += s_displaySurfaces;
288  TString rotationString = "Rotation_";
289  rotationString += s_displaySurfaces;
290  TString nodeString = "Node";
291  nodeString += s_displaySurfaces;
292  // test version just with planar bounds
293  const Trk::RectangleBounds* recBo = dynamic_cast<const Trk::RectangleBounds*>(&(sf.bounds()));
294  const Trk::TrapezoidBounds* traBo = recBo ? nullptr : dynamic_cast<const Trk::TrapezoidBounds*>(&(sf.bounds()));
295  const Trk::DiscTrapezoidalBounds* disctraBo = (recBo || traBo) ? nullptr : dynamic_cast<const Trk::DiscTrapezoidalBounds*>(&(sf.bounds()));
296  if (recBo) {
297  // it is a rectangle surface
298  double halfX = recBo->halflengthX();
299  double halfY = recBo->halflengthY();
300  // prepare the surface
301  m_fileSurfaceOutput << surfaceString << " = new TBRIK(\""<< surfaceString << "\",\"" << surfaceString<< "\",\"void\",";
302  m_fileSurfaceOutput << halfX << ","<< halfY <<" ,2);" << '\n';
303 
304  m_fileSurfaceOutput << surfaceString << "->SetLineColor(80);" << std::endl;
305 
306  // the rotation
307  m_fileSurfaceOutput << rotationString << "= new TRotMatrix(\" "<< rotationString << " \",\" " << rotationString << " \", ";
308  m_fileSurfaceOutput << xTheta << "," << xPhi << "," << yTheta << "," << yPhi << ", " << zTheta << "," << zPhi << ");" << std::endl;
309 
310  } else if (traBo) {
311  //example
312  //TGTRA gtra = new TGTRA("GTRA","GTRA","void",390,0,0,20,60,40,90,15120,80180,15);
313  // prepare the surface (swap Y and Z)
314  m_fileSurfaceOutput << surfaceString << " = new TTRD1(\""<< surfaceString << "\",\"" << surfaceString<< "\",\"void\",";
315  m_fileSurfaceOutput << traBo->minHalflengthX() << "," << traBo->maxHalflengthX() << ",2," << traBo->halflengthY() << ");" << '\n';
316 
317  m_fileSurfaceOutput << surfaceString << "->SetLineColor(80);" << std::endl;
318 
319  // the rotation (swap Y and Z)
320  m_fileSurfaceOutput << rotationString << "= new TRotMatrix(\" "<< rotationString << " \",\" " << rotationString << " \", ";
321  m_fileSurfaceOutput << xTheta << "," << xPhi << ", " << zTheta << "," << zPhi << "," << yTheta << "," << yPhi << ");" << std::endl;
322  } else if (disctraBo) {
323  //double rMedium = disctraBo->rCenter();
324  //double Rc = (sf.center()).perp();
325  //double side = (sf.normal()).z();
326  //double stereo = side*2.*asin(Rc/(2.*rMedium));
327  //double avePhi = (side>0) ? disctraBo->averagePhi()+stereo : -disctraBo->averagePhi()+M_PI+stereo;
328 
329  double stereo = disctraBo->stereo();
330  double rMedium = disctraBo->rCenter();
331  double avePhi = disctraBo->averagePhi()+stereo;
332 
333  surfX = rMedium*cos(avePhi);
334  surfY = rMedium*sin(avePhi);
335  surfZ = (sf.center()).z();
336 
338  rotation = Amg::AngleAxis3D(0., Amg::Vector3D::UnitX())*
339  Amg::AngleAxis3D(0., Amg::Vector3D::UnitY())*
340  Amg::AngleAxis3D(-M_PI/2.+avePhi-surfZ/fabs(surfZ)*stereo, Amg::Vector3D::UnitZ());
341 
342  // ROOT wants the angles in degrees
343  xPhi = rotation.col(0).phi()*convFac;
344  xTheta = rotation.col(0).theta()*convFac;
345  yPhi = rotation.col(1).phi()*convFac;
346  yTheta = rotation.col(1).theta()*convFac;
347  zPhi = rotation.col(2).phi()*convFac;
348  zTheta = rotation.col(2).theta()*convFac;
349 
350  //example
351  //TGTRA gtra = new TGTRA("GTRA","GTRA","void",390,0,0,20,60,40,90,15120,80180,15);
352  // prepare the surface (swap Y and Z)
353  m_fileSurfaceOutput << surfaceString << " = new TTRD1(\""<< surfaceString << "\",\"" << surfaceString<< "\",\"void\",";
354  m_fileSurfaceOutput << disctraBo->minHalflengthX() << "," << disctraBo->maxHalflengthX() << ",2," << disctraBo->halflengthY() << ");" << '\n';
355 
356  m_fileSurfaceOutput << surfaceString << "->SetLineColor(80);" << std::endl;
357 
358  // the rotation (swap Y and Z)
359  m_fileSurfaceOutput << rotationString << "= new TRotMatrix(\" "<< rotationString << " \",\" " << rotationString << " \", ";
360  m_fileSurfaceOutput << xTheta << "," << xPhi << ", " << zTheta << "," << zPhi << "," << yTheta << "," << yPhi << ");" << std::endl;
361  }
362 
363  // the node
364  m_fileSurfaceOutput << nodeString << " = new TNode(\"" << nodeString << "\",\"" << nodeString << "\"," << surfaceString;
365  m_fileSurfaceOutput << "," << surfX << ", " << surfY << "," << surfZ << ", " << rotationString << ");" << std::endl;
366 
367  return StatusCode::SUCCESS;
368 
369 }

◆ processNode() [3/3]

StatusCode Trk::TrackingVolumeDisplayer::processNode ( const TrackingVolume tvol,
size_t  level = 0 
) const
privatevirtual

Current implementation: write root visualization to file stream.

Reimplemented from Trk::RecursiveGeometryProcessor.

Definition at line 128 of file TrackingVolumeDisplayer.cxx.

129 {
130 
131  ATH_MSG_VERBOSE("Writing display information for TrackingVolume.");
132 
133  // make a dynamic cast to the CylinderVolumeBounds
134  const Trk::CylinderVolumeBounds* cvol = dynamic_cast<const Trk::CylinderVolumeBounds*>(&tvol.volumeBounds());
135 
136  double rMin = 0.;
137  double rMax = 0.;
138  double halfZ = 0.;
139 
140  if (cvol) {
141  // from the color code one can determine if its a gap volume
142  // set the boundaries
143  rMin = cvol->innerRadius();
144  rMax = cvol->outerRadius();
145  halfZ = cvol->halflengthZ();
146  }
147 
148  // get the name
149  const std::string& volumeName = tvol.volumeName();
150  // write a debug line
151  m_fileVolumeOutput << "// Processing TrackingVolume '" << volumeName << "'. " << '\n';
152  m_fileVolumeOutput << "CylinderVolume" << m_volumeCounter << " = new TTUBE(\"" << volumeName << "\",\"" << volumeName << "\",\"void\",";
153  m_fileVolumeOutput << int(rMin)+1 << "," << int(rMax)-1 << "," << int(halfZ)-1 << ");" << '\n';
154  m_fileVolumeOutput << "CylinderVolume" << m_volumeCounter << "->SetLineColor(" << tvol.colorCode() << ");" << '\n';
155  double zPos = tvol.center().z();
156  m_fileVolumeOutput << "CylinderNode" << m_volumeCounter << " = new TNode(\"" << volumeName << "Node\",\"" << volumeName << "Node\",\"";
157  m_fileVolumeOutput << volumeName << "\"," << 0 << "," << 0 << "," << int(zPos) << ");" << '\n';
158  m_fileVolumeOutput <<'\n';
159  ++m_volumeCounter;
160 
161  // return successful
162  return StatusCode::SUCCESS;
163 }

◆ renounce()

std::enable_if_t<std::is_void_v<std::result_of_t<decltype(&T::renounce)(T)> > && !std::is_base_of_v<SG::VarHandleKeyArray, T> && std::is_base_of_v<Gaudi::DataHandle, T>, void> AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

Member Data Documentation

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_fileLayerOutput

std::ofstream Trk::TrackingVolumeDisplayer::m_fileLayerOutput
mutableprivate

file output for visualization action

Definition at line 73 of file TrackingVolumeDisplayer.h.

◆ m_fileLayerOutputMode

bool Trk::TrackingVolumeDisplayer::m_fileLayerOutputMode
mutableprivate

steer writing

Definition at line 75 of file TrackingVolumeDisplayer.h.

◆ m_fileLayerOutputName

std::string Trk::TrackingVolumeDisplayer::m_fileLayerOutputName
mutableprivate

file name for visualization action

Definition at line 74 of file TrackingVolumeDisplayer.h.

◆ m_fileSurfaceOutput

std::ofstream Trk::TrackingVolumeDisplayer::m_fileSurfaceOutput
mutableprivate

file output for visualization action

Definition at line 77 of file TrackingVolumeDisplayer.h.

◆ m_fileSurfaceOutputMode

bool Trk::TrackingVolumeDisplayer::m_fileSurfaceOutputMode
mutableprivate

steer writing

Definition at line 79 of file TrackingVolumeDisplayer.h.

◆ m_fileSurfaceOutputName

std::string Trk::TrackingVolumeDisplayer::m_fileSurfaceOutputName
mutableprivate

file name for visualization action

Definition at line 78 of file TrackingVolumeDisplayer.h.

◆ m_fileSurfaceOutputSplit

bool Trk::TrackingVolumeDisplayer::m_fileSurfaceOutputSplit
mutableprivate

use one file for each layer

Definition at line 80 of file TrackingVolumeDisplayer.h.

◆ m_fileVolumeOutput

std::ofstream Trk::TrackingVolumeDisplayer::m_fileVolumeOutput
mutableprivate

file output for visualization action

Definition at line 69 of file TrackingVolumeDisplayer.h.

◆ m_fileVolumeOutputMode

bool Trk::TrackingVolumeDisplayer::m_fileVolumeOutputMode
mutableprivate

steer writing

Definition at line 71 of file TrackingVolumeDisplayer.h.

◆ m_fileVolumeOutputName

std::string Trk::TrackingVolumeDisplayer::m_fileVolumeOutputName
mutableprivate

file name for visualization action

Definition at line 70 of file TrackingVolumeDisplayer.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.

◆ m_volumeCounter

int Trk::TrackingVolumeDisplayer::m_volumeCounter
mutableprivate

volume counter

Definition at line 67 of file TrackingVolumeDisplayer.h.

◆ s_displaySurfaces

int Trk::TrackingVolumeDisplayer::s_displaySurfaces = 0
staticprivate

static surface counter

Definition at line 82 of file TrackingVolumeDisplayer.h.


The documentation for this class was generated from the following files:
PlotCalibFromCool.il
il
Definition: PlotCalibFromCool.py:381
Trk::TrapezoidBounds::maxHalflengthX
double maxHalflengthX() const
This method returns the maximal halflength in X (first coordinate of local surface frame)
Trk::RectangleBounds
Definition: RectangleBounds.h:38
Trk::TrackingVolumeDisplayer::m_fileLayerOutputMode
bool m_fileLayerOutputMode
steer writing
Definition: TrackingVolumeDisplayer.h:75
Trk::TrackingVolumeDisplayer::m_fileVolumeOutputName
std::string m_fileVolumeOutputName
file name for visualization action
Definition: TrackingVolumeDisplayer.h:70
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
color
Definition: jFexInputByteStreamTool.cxx:25
Trk::RecursiveGeometryProcessor::processNode
virtual StatusCode processNode(const TrackingVolume &tvol, size_t level=0) const
Dedicated action for the different processors.
Definition: RecursiveGeometryProcessor.cxx:167
Trk::z
@ z
global position (cartesian)
Definition: ParamDefs.h:57
PowhegControl_ttHplus_NLO.ss
ss
Definition: PowhegControl_ttHplus_NLO.py:83
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
Trk::RecursiveGeometryProcessor::initialize
StatusCode initialize()
AlgTool initialize method.
Definition: RecursiveGeometryProcessor.cxx:32
AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
Trk::TrackingVolume::boundarySurfaces
std::vector< SharedObject< BoundarySurface< TrackingVolume > > > & boundarySurfaces()
Method to return the BoundarySurfaces.
Definition: TrackingVolume.cxx:982
Trk::TrapezoidBounds::halflengthY
double halflengthY() const
This method returns the halflength in Y (second coordinate of local surface frame)
Trk::MaterialProperties::thicknessInX0
float thicknessInX0() const
Return the radiationlength fraction.
module_driven_slicing.layers
layers
Definition: module_driven_slicing.py:114
python.AthDsoLogger.out
out
Definition: AthDsoLogger.py:71
Trk::TrackingVolumeDisplayer::m_volumeCounter
int m_volumeCounter
volume counter
Definition: TrackingVolumeDisplayer.h:67
M_PI
#define M_PI
Definition: ActiveFraction.h:11
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
Trk::RecursiveGeometryProcessor::process
virtual StatusCode process(TrackingGeometry &tgeo) const
Processor Action to work on TrackingGeometry& tgeo.
Definition: RecursiveGeometryProcessor.cxx:46
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
Trk::TrapezoidBounds::minHalflengthX
double minHalflengthX() const
This method returns the minimal halflength in X (first coordinate of local surface frame)
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
Trk::TrackingVolumeDisplayer::m_fileSurfaceOutputMode
bool m_fileSurfaceOutputMode
steer writing
Definition: TrackingVolumeDisplayer.h:79
Trk::DiscBounds::rMax
double rMax() const
This method returns outer radius.
Trk::TrackingVolumeDisplayer::m_fileLayerOutputName
std::string m_fileLayerOutputName
file name for visualization action
Definition: TrackingVolumeDisplayer.h:74
Trk::DiscTrapezoidalBounds
Definition: DiscTrapezoidalBounds.h:42
python.iconfTool.models.loaders.level
level
Definition: loaders.py:20
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
Trk::TrackingVolume::confinedLayers
const LayerArray * confinedLayers() const
Return the subLayer array.
Trk::Layer::surfaceArray
const SurfaceArray * surfaceArray() const
Return the entire SurfaceArray, returns nullptr if no SurfaceArray.
Trk::TrackingVolumeDisplayer::m_fileLayerOutput
std::ofstream m_fileLayerOutput
file output for visualization action
Definition: TrackingVolumeDisplayer.h:73
Trk::DiscBounds::rMin
double rMin() const
This method returns inner radius.
Trk::TrackingGeometry::highestTrackingVolume
const TrackingVolume * highestTrackingVolume() const
return the world
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
Trk::RectangleBounds::halflengthX
double halflengthX() const
for consistant naming
beamspotman.n
n
Definition: beamspotman.py:731
xAOD::rotation
rotation
Definition: TrackSurface_v1.cxx:15
Trk::CylinderBounds
Definition: CylinderBounds.h:46
Trk::DiscTrapezoidalBounds::averagePhi
double averagePhi() const
This method returns the average phi.
color
color
Definition: BinsDiffFromStripMedian.h:18
Trk::CylinderVolumeBounds::halflengthZ
double halflengthZ() const
This method returns the halflengthZ.
Definition: CylinderVolumeBounds.h:207
Trk::TrackingVolumeDisplayer::m_fileSurfaceOutput
std::ofstream m_fileSurfaceOutput
file output for visualization action
Definition: TrackingVolumeDisplayer.h:77
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
Trk::DiscTrapezoidalBounds::rCenter
double rCenter() const
This method returns the center radius.
Trk::DiscTrapezoidalBounds::halflengthY
double halflengthY() const
This method returns the halflength in Y (this is Rmax -Rmin)
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
merge.output
output
Definition: merge.py:17
Trk::CylinderVolumeBounds
Definition: CylinderVolumeBounds.h:70
Trk::TrackingVolume::volumeName
const std::string & volumeName() const
Returns the VolumeName - for debug reason, might be depreciated later.
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
Trk::Surface::bounds
virtual const SurfaceBounds & bounds() const =0
Surface Bounds method.
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
Trk::TrackingVolumeDisplayer::openFile
static void openFile(std::ofstream &output, const std::string &filename)
File handling: open + write header.
Definition: TrackingVolumeDisplayer.cxx:105
Trk::CylinderVolumeBounds::outerRadius
double outerRadius() const
This method returns the outer radius.
Definition: CylinderVolumeBounds.h:191
Trk::BinnedArray::arrayObjects
virtual BinnedArraySpan< T *const > arrayObjects()=0
Return all objects of the Array non-const we can still modify the T.
Trk::RecursiveGeometryProcessor
Definition: RecursiveGeometryProcessor.h:39
Trk::RectangleBounds::halflengthY
double halflengthY() const
for consitant naming
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
ParticleGun_SamplingFraction.radius
radius
Definition: ParticleGun_SamplingFraction.py:96
Trk::TrapezoidBounds
Definition: TrapezoidBounds.h:43
Trk::TrackingVolumeDisplayer::closeFile
static void closeFile(std::ofstream &output)
File handling: write footer + close.
Definition: TrackingVolumeDisplayer.cxx:118
Trk::TrackingVolumeDisplayer::s_displaySurfaces
static int s_displaySurfaces
static surface counter
Definition: TrackingVolumeDisplayer.h:82
a
TList * a
Definition: liststreamerinfos.cxx:10
h
python.CaloScaleNoiseConfig.str
str
Definition: CaloScaleNoiseConfig.py:78
Trk::TrackingVolumeDisplayer::m_fileSurfaceOutputSplit
bool m_fileSurfaceOutputSplit
use one file for each layer
Definition: TrackingVolumeDisplayer.h:80
mapkey::sf
@ sf
Definition: TElectronEfficiencyCorrectionTool.cxx:38
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
Trk::CylinderVolumeBounds::innerRadius
double innerRadius() const
This method returns the inner radius.
Definition: CylinderVolumeBounds.h:187
Amg::RotationMatrix3D
Eigen::Matrix< double, 3, 3 > RotationMatrix3D
Definition: GeoPrimitives.h:49
Trk::TrackingVolume::confinedVolumes
const TrackingVolumeArray * confinedVolumes() const
Return the subLayer array.
Trk::TrackingVolumeDisplayer::m_fileVolumeOutputMode
bool m_fileVolumeOutputMode
steer writing
Definition: TrackingVolumeDisplayer.h:71
Trk::SurfaceType::Disc
@ Disc
Trk::TrackingVolumeDisplayer::processNode
StatusCode processNode(const TrackingVolume &tvol, size_t level=0) const
Current implementation: write root visualization to file stream.
Definition: TrackingVolumeDisplayer.cxx:128
Trk::SurfaceType::Cylinder
@ Cylinder
CaloCellTimeCorrFiller.filename
filename
Definition: CaloCellTimeCorrFiller.py:24
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
Amg::AngleAxis3D
Eigen::AngleAxisd AngleAxis3D
Definition: GeoPrimitives.h:45
Trk::MaterialProperties::zOverAtimesRho
float zOverAtimesRho() const
Return the .
str
Definition: BTagTrackIpAccessor.cxx:11
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
Trk::DiscTrapezoidalBounds::minHalflengthX
double minHalflengthX() const
This method returns the minimal halflength in X.
Trk::BinnedArray
Definition: BinnedArray.h:38
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
Trk::DiscTrapezoidalBounds::stereo
double stereo() const
This method returns the stereo angle.
Trk::Surface
Definition: Tracking/TrkDetDescr/TrkSurfaces/TrkSurfaces/Surface.h:75
Trk::TrackingVolumeDisplayer::m_fileVolumeOutput
std::ofstream m_fileVolumeOutput
file output for visualization action
Definition: TrackingVolumeDisplayer.h:69
Trk::TrackingVolume
Definition: TrackingVolume.h:121
Trk::DiscTrapezoidalBounds::maxHalflengthX
double maxHalflengthX() const
This method returns the maximal halflength in X.
Trk::BinnedArraySpan
std::span< T > BinnedArraySpan
Definition: BinnedArray.h:34
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
Trk::Surface::type
constexpr virtual SurfaceType type() const =0
Returns the Surface type to avoid dynamic casts.
fitman.k
k
Definition: fitman.py:528
Trk::DiscBounds
Definition: DiscBounds.h:44
Trk::CylinderBounds::halflengthZ
double halflengthZ() const
This method returns the halflengthZ.
Trk::CylinderBounds::r
virtual double r() const override final
This method returns the radius.
Trk::Layer
Definition: Layer.h:73
Trk::Layer::layerIndex
const LayerIndex & layerIndex() const
get the layerIndex
Trk::TrackingVolumeDisplayer::m_fileSurfaceOutputName
std::string m_fileSurfaceOutputName
file name for visualization action
Definition: TrackingVolumeDisplayer.h:78