 |
ATLAS Offline Software
|
#include <CylinderVolumeCreator.h>
|
| CylinderVolumeCreator (const std::string &, const std::string &, const IInterface *) |
| Constructor. More...
|
|
| ~CylinderVolumeCreator () |
| Destructor. More...
|
|
virtual StatusCode | initialize () override |
| AlgTool initialize method. More...
|
|
virtual TrackingVolume * | createTrackingVolume (const std::vector< Layer * > &layers, Material &matprop, VolumeBounds *volBounds=0, Amg::Transform3D *transform=0, const std::string &volumeName="UndefinedVolume", BinningType btype=arbitrary) const override final |
|
virtual TrackingVolume * | createTrackingVolume (const std::vector< Layer * > &layers, Material &matprop, double loc1Min, double loc1Max, double loc2Min, double loc2Max, const std::string &volumeName="UndefinedVolume", BinningType btype=arbitrary) const override final |
|
virtual TrackingVolume * | createGapTrackingVolume (Material &matprop, double rMin, double rMax, double zMin, double zMax, unsigned int materialLayers, bool cylinder=true, const std::string &volumeName="UndefinedVolume") const override final |
|
virtual TrackingVolume * | createGapTrackingVolume (Material &matprop, double rMin, double rMax, double zMin, double zMax, const std::vector< double > &layerPositions, bool cylinder=true, const std::string &volumeName="UndefinedVolume", BinningType btype=arbitrary) const override final |
|
virtual TrackingVolume * | createContainerTrackingVolume (const std::vector< TrackingVolume * > &volumes, const Material &matprop, const std::string &volumeName="UndefinedVolume", bool buildBoundaryLayers=false, bool replaceBoundaryFace=false) const override final |
|
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, V, H > &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 (ITrackingVolumeCreator, 1, 0) |
| Creates the InterfaceID and interfaceID() method. More...
|
|
|
StatusCode | estimateAndCheckDimension (const std::vector< Layer * > &layers, Trk::CylinderVolumeBounds *&cylBounds, Amg::Transform3D *&translation, std::vector< CylinderLayer * > &cylLayers, std::vector< DiscLayer * > &discLayers, double &rMinClean, double &rMaxClean, double &zMinClean, double &zMaxClean, BinningType bType=arbitrary) const |
| Private method - it estimates the CylinderBounds and Translation of layers, if given, these are checked against the layer positions/dimensions. More...
|
|
StatusCode | interGlueTrackingVolume (TrackingVolume &tVolume, bool rBinned, bool buildBoundaryLayers, bool replaceBoundaryFace=false) const |
| Private method - interglue all volumes contained by a TrackingVolume and set the outside glue volumes in the descriptor. More...
|
|
void | addFaceVolumes (TrackingVolume &tvol, Trk::BoundarySurfaceFace bsf, std::vector< Trk::TrackingVolume * > &vols) const |
| Private method - helper method not to duplicate code. More...
|
|
void | glueTrackingVolumes (TrackingVolume &volumeOne, BoundarySurfaceFace faceOne, TrackingVolume &volumeTwo, BoundarySurfaceFace faceTwo, bool buildBoundaryLayers, bool replaceBoundaryFace=false) const |
| Private method - glue volume to the other – use trackingVolume helper. More...
|
|
CylinderLayer * | createCylinderLayer (double z, double r, double halflength, double thickness, int binsPhi, int binsZ) const |
| Private method - helper method to save some code. More...
|
|
DiscLayer * | createDiscLayer (double z, double rMin, double rMax, double thickness, int binsPhi, int binsR) const |
| Private method - helper method to save some code. More...
|
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &) |
| specialization for handling Gaudi::Property<SG::VarHandleKey> More...
|
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyArrayType &) |
| specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
|
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleType &) |
| specialization for handling Gaudi::Property<SG::VarHandleBase> More...
|
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &t, const SG::NotHandleType &) |
| specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
|
|
◆ StoreGateSvc_t
◆ CylinderVolumeCreator()
Trk::CylinderVolumeCreator::CylinderVolumeCreator |
( |
const std::string & |
t, |
|
|
const std::string & |
n, |
|
|
const IInterface * |
p |
|
) |
| |
◆ ~CylinderVolumeCreator()
Trk::CylinderVolumeCreator::~CylinderVolumeCreator |
( |
| ) |
|
|
default |
◆ addFaceVolumes()
Private method - helper method not to duplicate code.
Definition at line 710 of file CylinderVolumeCreator.cxx.
721 std::vector<Trk::TrackingVolume*>::const_iterator volIter = gvDescriptor.
glueVolumes(glueFace).begin();
722 std::vector<Trk::TrackingVolume*>::const_iterator volEnd = gvDescriptor.
glueVolumes(glueFace).end();
723 for ( ; volIter != volEnd; ++volIter){
724 ATH_MSG_VERBOSE(
" -> adding volumes : " << (*volIter)->volumeName() );
725 vols.push_back(*volIter);
728 ATH_MSG_VERBOSE( vols.size() <<
" navigation volumes registered as glue volumes." );
732 vols.push_back(&tvol);
◆ createContainerTrackingVolume()
Trk::TrackingVolume * Trk::CylinderVolumeCreator::createContainerTrackingVolume |
( |
const std::vector< TrackingVolume * > & |
volumes, |
|
|
const Material & |
matprop, |
|
|
const std::string & |
volumeName = "UndefinedVolume" , |
|
|
bool |
buildBoundaryLayers = false , |
|
|
bool |
replaceBoundaryFace = false |
|
) |
| const |
|
finaloverridevirtual |
;
Implements Trk::ITrackingVolumeCreator.
Definition at line 343 of file CylinderVolumeCreator.cxx.
351 if (volumes.size() <= (
unsigned int)1) {
352 ATH_MSG_WARNING(
"None (only one) TrackingVolume given to create container "
353 "volume (min required: 2) - returning 0 ");
359 << volumeName <<
"' with " << volumes.size()
363 auto firstVolume = volumes.begin();
364 auto lastVolume = volumes.end();
366 for (
unsigned int ivol = 0; firstVolume != lastVolume;
367 ++firstVolume, ++ivol) {
369 << ivol <<
") is : " << (*firstVolume)->volumeName());
371 " at position : " <<
Amg::toString((*firstVolume)->center()));
376 firstVolume = volumes.begin();
379 if (firstVolume == lastVolume) {
380 ATH_MSG_WARNING(
"Only one TrackingVolume given to create Top level volume "
381 "(min required: 2) - returning 0 ");
388 &((*firstVolume)->volumeBounds()));
391 &((*lastVolume)->volumeBounds()));
393 if (!firstVolumeBounds || !lastVolumeBounds) {
395 "Trk::CylinderVolumeBounds (required) - returning 0 ");
400 bool rCase = fabs(firstVolumeBounds->
innerRadius() -
409 zMin = (*firstVolume)->center().z() - firstVolumeBounds->
halflengthZ();
410 zMax = (*firstVolume)->center().z() + firstVolumeBounds->
halflengthZ();
414 zMin = (*firstVolume)->center().z() - firstVolumeBounds->
halflengthZ();
415 zMax = (*lastVolume)->center().z() + lastVolumeBounds->
halflengthZ();
421 double zPos = 0.5 * (zMin + zMax);
423 std::unique_ptr<Amg::Transform3D> topVolumeTransform =
424 fabs(zPos) > 0.1 ? std::make_unique<Amg::Transform3D>(
Amg::Translation3D(0., 0., zPos)) : nullptr;
426 auto topVolumeBounds =
428 ? std::make_shared<Trk::CylinderVolumeBounds>(rMin, rMax, 0.5 * fabs(zMax - zMin))
429 : std::make_shared<
Trk::CylinderVolumeBounds>(rMax, 0.5 * fabs(zMax - zMin));
431 std::unique_ptr<Trk::BinnedArray<Trk::TrackingVolume>> volumeArray =
436 "Creation of TrackingVolume array did not succeed - returning 0 ");
442 std::move(topVolumeTransform),
443 std::move(topVolumeBounds),
446 std::move(volumeArray),
452 *topVolume, rCase, buildBoundaryLayers, replaceBoundaryFace)
455 "Problem with inter-glueing of TrackingVolumes (needed) - returning 0 ");
461 "[ end ] return newly created container : " << topVolume->
volumeName());
◆ createCylinderLayer()
Trk::CylinderLayer * Trk::CylinderVolumeCreator::createCylinderLayer |
( |
double |
z, |
|
|
double |
r, |
|
|
double |
halflength, |
|
|
double |
thickness, |
|
|
int |
binsPhi, |
|
|
int |
binsZ |
|
) |
| const |
|
private |
Private method - helper method to save some code.
Definition at line 808 of file CylinderVolumeCreator.cxx.
815 ATH_MSG_VERBOSE(
"Creating a CylinderLayer at position " <<
z <<
" and radius " <<
r );
819 std::unique_ptr<Amg::Transform3D>
transform =
829 <<
binsZ <<
" bins in Z. ");
834 layerBinUtilityRPhiZ += layerBinUtility;
839 << binsPhi <<
" / " <<
binsZ <<
" bins in R*phi / Z. ");
842 auto cylinderBounds = std::make_shared<Trk::CylinderBounds>(
r,halflengthZ);
847 cylinderMaterial, thickness,
nullptr,
849 :
new Trk::CylinderLayer(cylinderBounds, cylinderMaterial,
852 return cylinderLayer;
◆ createDiscLayer()
Trk::DiscLayer * Trk::CylinderVolumeCreator::createDiscLayer |
( |
double |
z, |
|
|
double |
rMin, |
|
|
double |
rMax, |
|
|
double |
thickness, |
|
|
int |
binsPhi, |
|
|
int |
binsR |
|
) |
| const |
|
private |
Private method - helper method to save some code.
Definition at line 856 of file CylinderVolumeCreator.cxx.
864 ATH_MSG_VERBOSE(
"Creating a DiscLayer at position " <<
z <<
" and rMin/rMax " << rMin <<
" / " << rMax);
874 << binsR <<
" bins in R. ");
879 << binsPhi <<
" / " << binsR <<
" bins in phi / R. ");
884 auto discBounds = std::make_shared<Trk::DiscBounds>(rMin,rMax);
◆ createGapTrackingVolume() [1/2]
Trk::TrackingVolume * Trk::CylinderVolumeCreator::createGapTrackingVolume |
( |
Trk::Material & |
matprop, |
|
|
double |
rMin, |
|
|
double |
rMax, |
|
|
double |
zMin, |
|
|
double |
zMax, |
|
|
const std::vector< double > & |
layerPositions, |
|
|
bool |
cylinder = true , |
|
|
const std::string & |
volumeName = "UndefinedVolume" , |
|
|
BinningType |
btype = arbitrary |
|
) |
| const |
|
finaloverridevirtual |
ITrackingVolumeCreator::createGaoTrackingVolume(Material&,,std::vector<double>&,int,bool,const std::string&) const;
Implements Trk::ITrackingVolumeCreator.
Definition at line 286 of file CylinderVolumeCreator.cxx.
300 << volumeName <<
"' with (rMin/rMax/zMin/Max) = ");
301 ATH_MSG_VERBOSE(
'\t' << rMin <<
" / " << rMax <<
" / " << zMin <<
" / "
305 std::vector<Trk::Layer*>
layers;
306 layers.reserve(layerPositions.size());
308 std::vector<double>::const_iterator layerPropIter = layerPositions.begin();
309 std::vector<double>::const_iterator layerPropEnd = layerPositions.end();
310 for (; layerPropIter != layerPropEnd; ++layerPropIter) {
314 double zMinLayer = zMin;
315 double zMaxLayer = zMax;
319 fabs(0.5 * (zMaxLayer - zMinLayer)),
326 double rMinLayer = rMin;
327 double rMaxLayer = rMax;
339 layers, matprop, rMin, rMax, zMin, zMax, volumeName, btype);
◆ createGapTrackingVolume() [2/2]
Trk::TrackingVolume * Trk::CylinderVolumeCreator::createGapTrackingVolume |
( |
Trk::Material & |
matprop, |
|
|
double |
rMin, |
|
|
double |
rMax, |
|
|
double |
zMin, |
|
|
double |
zMax, |
|
|
unsigned int |
materialLayers, |
|
|
bool |
cylinder = true , |
|
|
const std::string & |
volumeName = "UndefinedVolume" |
|
) |
| const |
|
finaloverridevirtual |
◆ createTrackingVolume() [1/2]
;
Implements Trk::ITrackingVolumeCreator.
Definition at line 195 of file CylinderVolumeCreator.cxx.
210 ATH_MSG_VERBOSE(
"Create cylindrical TrackingVolume '" << volumeName <<
"'.");
212 << rMin <<
" / " << rMax <<
" / " << zMin <<
" / " << zMax);
215 if (zMin > zMax || rMin > rMax) {
217 << ((zMin > zMax) ?
" zMin > zMax (" :
" rMin > rMax (")
218 << ((zMin > zMax) ? zMin : rMin) <<
" > "
219 << ((zMin > zMax) ? zMax : rMax) <<
" ) - return 0");
224 double halflengthZ = 0.5 * (zMax - zMin);
225 double zPosition = 0.5 * (zMin + zMax);
226 zPosition = fabs(zPosition) < 0.1 ? 0. : zPosition;
230 :
new Trk::CylinderVolumeBounds(rMax, halflengthZ);
◆ createTrackingVolume() [2/2]
;
Implements Trk::ITrackingVolumeCreator.
Definition at line 93 of file CylinderVolumeCreator.cxx.
115 if (!cylinderBounds){
116 ATH_MSG_WARNING(
"[!] Problem: given bounds were not cylindrical - return 0" );
120 std::vector<Trk::CylinderLayer*> cylLayers;
121 cylLayers.reserve(
layers.size());
122 std::vector<Trk::DiscLayer*> discLayers;
123 discLayers.reserve(
layers.size());
139 btype).isFailure()) {
140 ATH_MSG_WARNING(
"[!] Problem with given dimensions - return 0 and delete provided objects" );
142 delete cylinderBounds;
148 ( cylinderBounds ? -cylinderBounds->
halflengthZ() : 0. );
150 ( cylinderBounds ? cylinderBounds->
halflengthZ() : 0. );
163 if (!cylinderBounds) {
173 std::unique_ptr<Trk::BinnedArray1D<Trk::Layer>> layerArray =
175 cylLayers, rMin, rMax, btype)
177 discLayers, zMin, zMax, btype);
181 std::shared_ptr<Trk::CylinderVolumeBounds>(cylinderBounds),
183 std::move(layerArray),
◆ declareGaudiProperty() [1/4]
specialization for handling Gaudi::Property<SG::VarHandleKeyArray>
Definition at line 170 of file AthCommonDataStore.h.
175 hndl.documentation());
◆ declareGaudiProperty() [2/4]
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition at line 156 of file AthCommonDataStore.h.
161 hndl.documentation());
◆ declareGaudiProperty() [3/4]
specialization for handling Gaudi::Property<SG::VarHandleBase>
Definition at line 184 of file AthCommonDataStore.h.
189 hndl.documentation());
◆ declareGaudiProperty() [4/4]
◆ DeclareInterfaceID()
Creates the InterfaceID and interfaceID() method.
◆ declareProperty() [1/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation 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.
250 this->declare(hndl.
vhKey());
251 hndl.
vhKey().setOwner(
this);
253 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [2/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation 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.
229 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [3/6]
◆ declareProperty() [4/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation 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.
338 return PBASE::declareProperty(
name, property,
doc);
◆ declareProperty() [5/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation 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.
◆ declareProperty() [6/6]
◆ detStore()
◆ estimateAndCheckDimension()
Private method - it estimates the CylinderBounds and Translation of layers, if given, these are checked against the layer positions/dimensions.
private helper method to estimate and check the dimensions of a tracking volume
Definition at line 468 of file CylinderVolumeCreator.cxx.
484 return StatusCode::FAILURE;
489 if (cylinderVolumeBounds)
ATH_MSG_VERBOSE(
"Cylinder volume bounds are given." );
492 double layerRmin = 10e10;
493 double layerRmax = 0.;
494 double layerZmin = 10e10;
495 double layerZmax = -10e10;
504 for (
auto *
const layerIter :
layers) {
507 double currentRmin = 0.;
508 double currentRmax = 0.;
509 double currentZmin = 0.;
510 double currentZmax = 0.;
520 double currentR = cylBounds->
r();
521 double centerZ = (layerIter->surfaceRepresentation()).center().z();
524 currentRmin = currentR; currentRmax = currentR;
526 currentRmin = currentR-(0.5*(layerIter)->thickness());
527 currentRmax = currentR+(0.5*(layerIter)->thickness());
534 dynamic_cast<const Trk::DiscBounds*
>(&(layerIter->surfaceRepresentation()).bounds());
539 double centerZ = (layerIter->surfaceRepresentation()).center().z();
540 currentRmin = discBounds->
rMin();
541 currentRmax = discBounds->
rMax();
543 currentZmin = centerZ; currentZmax = centerZ;
545 currentZmin = centerZ - (0.5*(layerIter)->thickness());
546 currentZmax = centerZ + (0.5*(layerIter)->thickness());
550 rMinClean =
std::min(rMinClean, currentRmin);
551 rMaxClean =
std::max(rMaxClean, currentRmax);
552 zMinClean =
std::min(zMinClean, currentZmin);
553 zMaxClean =
std::max(zMaxClean, currentZmax);
556 layerRmin =
std::min(layerRmin,currentRmin);
557 layerRmax =
std::max(layerRmax, currentRmax);
558 layerZmin =
std::min(layerZmin,currentZmin);
559 layerZmax =
std::max(layerZmax, currentZmax);
565 double rStepHalf = 0.5*(layerRmax-layerRmin)/(
layers.size()-1);
566 layerRmin -= rStepHalf;
567 layerRmax += rStepHalf;
569 double zStepHalf = 0.5*(layerZmax-layerZmin)/(
layers.size()-1);
570 layerZmin -= zStepHalf;
571 layerZmax += zStepHalf;
575 ATH_MSG_VERBOSE(
"Estimate/check CylinderVolumeBounds from/w.r.t. enclosed layers + envelope covers" );
577 double zEstFromLayerEnv = 0.5*((layerZmax)+(layerZmin));
578 double halflengthFromLayer = 0.5*fabs((layerZmax)-(layerZmin));
580 bool concentric = (zEstFromLayerEnv*zEstFromLayerEnv < 0.001);
583 if (!cylinderVolumeBounds && !
transform) {
590 }
else if (cylinderVolumeBounds && !
transform &&!concentric){
594 else if (
transform && !cylinderVolumeBounds) {
596 double halflengthFromLayer = 0.5*fabs((layerZmax)-(layerZmin));
599 halflengthFromLayer);
603 << layerRmin <<
" / " << layerRmax <<
" / " << layerZmin <<
" / " << layerZmax );
605 ATH_MSG_VERBOSE(
" -> while created bounds are (rMin/rMax/zMin/zMax) = "
606 << cylinderVolumeBounds->innerRadius() <<
" / " << cylinderVolumeBounds->outerRadius() <<
" / "
607 << zFromTransform-cylinderVolumeBounds->halflengthZ() <<
" / " << zFromTransform+cylinderVolumeBounds->halflengthZ() );
611 if (cylinderVolumeBounds) {
613 if (zFromTransform-cylinderVolumeBounds->halflengthZ() <= layerZmin &&
614 zFromTransform+cylinderVolumeBounds->halflengthZ() >= layerZmax &&
615 cylinderVolumeBounds->innerRadius() <= layerRmin &&
616 cylinderVolumeBounds->outerRadius() >= layerRmax)
617 return StatusCode::SUCCESS;
619 ATH_MSG_WARNING(
"Provided layers are not contained by volume ! Bailing out. " );
620 return StatusCode::FAILURE;
626 return StatusCode::SUCCESS;
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ extraDeps_update_handler()
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
◆ glueTrackingVolumes()
Private method - glue volume to the other – use trackingVolume helper.
private helper method to fill the glue volumes (or the volume itself in)
Definition at line 738 of file CylinderVolumeCreator.cxx.
750 ATH_MSG_VERBOSE(
"Glue method called with " << (replaceBoundaryFace ?
"joint boundaries." :
"individual boundaries." ) );
752 size_t volOneGlueVols = gvDescriptorOne.
glueVolumes(faceOne).size();
754 << volOneGlueVols <<
" @ " << faceOne );
755 size_t volTwoGlueVols = gvDescriptorTwo.
glueVolumes(faceTwo).size();
757 << volTwoGlueVols <<
" @ " << faceTwo );
760 TrackingVolume* glueVolOne = volOneGlueVols ?
761 gvDescriptorOne.
glueVolumes(faceOne)[0] : &tvolOne;
763 TrackingVolume* glueVolTwo = volTwoGlueVols ?
764 gvDescriptorTwo.
glueVolumes(faceTwo)[0] : &tvolTwo;
768 if ( volOneGlueVols <= 1 && volTwoGlueVols <= 1) {
770 ATH_MSG_VERBOSE(
" glue : one[ "<< glueVolOne->volumeName() <<
" @ " << faceOne
771 <<
" ]-to-one[ "<< glueVolTwo->volumeName() <<
" @ " << faceTwo <<
" ]" );
776 createBoundaryLayers);
777 }
else if (volOneGlueVols <= 1) {
778 ATH_MSG_VERBOSE(
" glue : one[ "<< glueVolOne->volumeName() <<
" @ " << faceOne
779 <<
" ]-to-many[ "<< tvolTwo.
volumeName() <<
" @ " << faceTwo <<
" ]" );
784 createBoundaryLayers,
785 replaceBoundaryFace);
786 }
else if (volTwoGlueVols <= 1 ) {
788 <<
" ]-to-one[ "<< glueVolTwo->volumeName() <<
" @ " << faceTwo <<
" ]" );
793 createBoundaryLayers,
794 replaceBoundaryFace);
798 <<
" ]-to-many[ "<< tvolTwo.
volumeName() <<
" @ " << faceTwo <<
" ]" );
803 createBoundaryLayers,
804 replaceBoundaryFace);
◆ initialize()
StatusCode Trk::CylinderVolumeCreator::initialize |
( |
| ) |
|
|
overridevirtual |
AlgTool initialize method.
Definition at line 58 of file CylinderVolumeCreator.cxx.
65 return StatusCode::FAILURE;
74 return StatusCode::FAILURE;
83 return StatusCode::FAILURE;
89 return StatusCode::SUCCESS;
◆ inputHandles()
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.
◆ interGlueTrackingVolume()
StatusCode Trk::CylinderVolumeCreator::interGlueTrackingVolume |
( |
Trk::TrackingVolume & |
tVolume, |
|
|
bool |
rBinned, |
|
|
bool |
buildBoundaryLayers, |
|
|
bool |
replaceBoundaryFace = false |
|
) |
| const |
|
private |
Private method - interglue all volumes contained by a TrackingVolume and set the outside glue volumes in the descriptor.
Definition at line 630 of file CylinderVolumeCreator.cxx.
645 auto tVolIter = volumes.begin();
646 auto tVolFirst = volumes.begin();
647 auto tVolLast = volumes.end(); --tVolLast;
648 auto tVolEnd = volumes.end();
651 std::vector<Trk::TrackingVolume*> glueVolumesInnerTube;
652 std::vector<Trk::TrackingVolume*> glueVolumesOuterTube;
653 std::vector<Trk::TrackingVolume*> glueVolumesNegativeFace;
654 std::vector<Trk::TrackingVolume*> glueVolumesPositiveFace;
659 for ( ; tVolIter != tVolEnd; ) {
661 ATH_MSG_VERBOSE(
"r-binning: Processing volume '" << (*tVolIter)->volumeName() <<
"'.");
663 if (tVolIter == tVolFirst)
668 if (tVolIter == tVolLast) {
680 for ( ; tVolIter != tVolEnd; ) {
682 ATH_MSG_VERBOSE(
"z-binning: Processing volume '" << (*tVolIter)->volumeName() <<
"'.");
683 if (tVolIter == tVolFirst)
687 if (tVolIter == tVolLast) {
705 return StatusCode::SUCCESS;
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ outputHandles()
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.
◆ renounce()
◆ renounceArray()
◆ sysInitialize()
◆ sysStart()
Handle START transition.
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.
◆ updateVHKA()
◆ m_detStore
◆ m_evtStore
◆ m_layerArrayCreator
◆ m_passiveLayerPhiBins
int Trk::CylinderVolumeCreator::m_passiveLayerPhiBins |
|
private |
◆ m_passiveLayerRzBins
int Trk::CylinderVolumeCreator::m_passiveLayerRzBins |
|
private |
◆ m_passiveLayerThickness
double Trk::CylinderVolumeCreator::m_passiveLayerThickness |
|
private |
◆ m_trackingVolumeArrayCreator
◆ m_trackingVolumeHelper
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
GlueVolumesDescriptor & glueVolumesDescriptor()
void addFaceVolumes(TrackingVolume &tvol, Trk::BoundarySurfaceFace bsf, std::vector< Trk::TrackingVolume * > &vols) const
Private method - helper method not to duplicate code.
DiscLayer * createDiscLayer(double z, double rMin, double rMax, double thickness, int binsPhi, int binsR) const
Private method - helper method to save some code.
CylinderLayer * createCylinderLayer(double z, double r, double halflength, double thickness, int binsPhi, int binsZ) const
Private method - helper method to save some code.
@ z
global position (cartesian)
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
int m_passiveLayerPhiBins
bins in phi for the passive layer
#define ATH_MSG_VERBOSE(x)
ToolHandle< ITrackingVolumeArrayCreator > m_trackingVolumeArrayCreator
TrackingVolume helper.
StatusCode estimateAndCheckDimension(const std::vector< Layer * > &layers, Trk::CylinderVolumeBounds *&cylBounds, Amg::Transform3D *&translation, std::vector< CylinderLayer * > &cylLayers, std::vector< DiscLayer * > &discLayers, double &rMinClean, double &rMaxClean, double &zMinClean, double &zMaxClean, BinningType bType=arbitrary) const
Private method - it estimates the CylinderBounds and Translation of layers, if given,...
double rMax() const
This method returns outer radius.
virtual void setOwner(IDataHandleHolder *o)=0
void glueTrackingVolumes(TrackingVolume &volumeOne, BoundarySurfaceFace faceOne, TrackingVolume &volumeTwo, BoundarySurfaceFace faceTwo, bool buildBoundaryLayers, bool replaceBoundaryFace=false) const
Private method - glue volume to the other – use trackingVolume helper.
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
double rMin() const
This method returns inner radius.
std::string toString(const Translation3D &translation, int precision=4)
GeoPrimitvesToStringConverter.
void registerGlueVolumes(BoundarySurfaceFace, std::vector< TrackingVolume * > &)
register the volumes
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
Eigen::Affine3d Transform3D
Amg::Vector3D transform(Amg::Vector3D &v, Amg::Transform3D &tr)
Transform a point from a Trasformation3D.
double halflengthZ() const
This method returns the halflengthZ.
const Amg::Vector3D & center() const
returns the center of the volume
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
virtual std::span< T *const > arrayObjects()=0
Return all objects of the Array non-const we can still modify the T.
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Ensure that the ATLAS eigen extensions are properly loaded.
const std::string & volumeName() const
Returns the VolumeName - for debug reason, might be depreciated later.
virtual TrackingVolume * createGapTrackingVolume(Material &matprop, double rMin, double rMax, double zMin, double zMax, unsigned int materialLayers, bool cylinder=true, const std::string &volumeName="UndefinedVolume") const override final
Definition of ATLAS Math & Geometry primitives (Amg)
const std::vector< TrackingVolume * > & glueVolumes(BoundarySurfaceFace)
retrieve them again
double outerRadius() const
This method returns the outer radius.
ToolHandle< ITrackingVolumeHelper > m_trackingVolumeHelper
virtual TrackingVolume * createTrackingVolume(const std::vector< Layer * > &layers, Material &matprop, VolumeBounds *volBounds=0, Amg::Transform3D *transform=0, const std::string &volumeName="UndefinedVolume", BinningType btype=arbitrary) const override final
ToolHandle< ILayerArrayCreator > m_layerArrayCreator
< A Tool for coherent LayerArray creation
#define ATH_MSG_WARNING(x)
double innerRadius() const
This method returns the inner radius.
const TrackingVolumeArray * confinedVolumes() const
Return the subLayer array.
Eigen::Translation< double, 3 > Translation3D
const VolumeBounds & volumeBounds() const
returns the volumeBounds()
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
double m_passiveLayerThickness
thickness of passive layers
int m_passiveLayerRzBins
bins in r/z for the passive layer
StatusCode interGlueTrackingVolume(TrackingVolume &tVolume, bool rBinned, bool buildBoundaryLayers, bool replaceBoundaryFace=false) const
Private method - interglue all volumes contained by a TrackingVolume and set the outside glue volumes...
double halflengthZ() const
This method returns the halflengthZ.
virtual double r() const override final
This method returns the radius.