|
ATLAS Offline Software
|
Go to the documentation of this file.
10 #include <google/profiler.h>
18 #include "Identifier/Identifier.h"
23 #include "GaudiKernel/ITHistSvc.h"
71 std::string profile_file =
"cpu.prof";
73 ProfilerStart(profile_file.c_str());
76 return StatusCode::SUCCESS;
91 return StatusCode::SUCCESS;
101 return StatusCode::FAILURE;
108 return StatusCode::FAILURE;
118 ATH_MSG_DEBUG(
"This event has " << tracks->size() <<
" tracks." );
119 for (
const auto *
track : *tracks) {
139 <<
" theta = " << perigee->parameters()[
Trk::theta] <<
"\n"
140 <<
" qOverP = " << perigee->parameters()[
Trk::qOverP] );
149 ATH_MSG_DEBUG(
" This track has " << track_states->
size() <<
" track states on surface." );
151 ATH_MSG_ERROR(
" This track has null track states on surface." );
156 for (
const auto *trackState : *track_states) {
170 bool passed_track_preselection =
180 if (!passed_track_preselection) {
188 for (
const auto *trackState : *track_states ) {
216 ATH_MSG_ERROR(
"fill_hole_data returned an invalid det type: " << hole_det);
219 ATH_MSG_WARNING(
" hole finder returned a TrackStateOnSurface not of type Hole.");
231 return StatusCode::FAILURE;
247 return StatusCode::SUCCESS;
256 #ifdef ANP_CPU_PROFILER
261 return StatusCode::SUCCESS;
394 if (!track_parameters) {
455 std::unique_ptr<Trk::TrackParameters> unbiased_track_parameters =
461 m_hit_ub_locR.push_back(
det == 3 && unbiased_track_parameters ? unbiased_track_parameters->parameters()[
Trk::locR] : -1 );
462 m_hit_ub_x.push_back( unbiased_track_parameters ? unbiased_track_parameters->
position().x() : -1 );
463 m_hit_ub_y.push_back( unbiased_track_parameters ? unbiased_track_parameters->
position().y() : -1 );
464 m_hit_ub_z.push_back( unbiased_track_parameters ? unbiased_track_parameters->
position().z() : -1 );
467 int is_tube_hit = -1;
468 if (measurement && (
det == 3) ) {
473 m_hit_tube_hit.push_back( (
det == 3)&&(measurement !=
nullptr) ? is_tube_hit : -1);
485 if (!track_parameters) {
486 ATH_MSG_ERROR(
"fill_hole_data(hole): null track_parameters");
531 float locR_error = 0.0;
536 const AmgSymMatrix(5)* merr = track_parameters->covariance();
540 ATH_MSG_ERROR(
"Track parameters have no covariance attached.");
def retrieve(aClass, aKey=None)
bool is_pixel(Identifier id) const
const TrackParameters * trackParameters() const
return ptr to trackparameters const overload
PublicToolHandle< Trk::IUpdator > m_updator
FloatProperty m_max_abs_d0
std::vector< int > m_hole_pad
std::vector< float > m_hit_center_x
uint64_t eventNumber() const
The current event's event number.
std::vector< float > m_hit_ub_z
bool is_sct(Identifier id) const
const Amg::Vector3D & position() const
Access method for the position.
StringProperty m_tree_name
std::vector< int > m_hit_bec
virtual const Surface & associatedSurface() const override=0
Access to the Surface associated to the Parameters.
Dummy class used to allow special convertors to be called for surfaces owned by a detector element.
std::vector< float > m_hole_z
Identifier associatedDetectorElementIdentifier() const
return Identifier of the associated Detector Element
ServiceHandle< ITHistSvc > m_hist_svc
This is an Identifier helper class for the TRT subdetector. This class is a factory for creating comp...
std::vector< int > m_hit_phi
unsigned int m_num_preselected_tracks
std::vector< int > m_hit_layer
std::vector< int > m_hit_chip
unsigned int m_event_number
const MeasurementBase * measurementOnTrack() const
returns MeasurementBase const overload
bool highLevel() const
returns true if the high level threshold was passed
bool is_trt(Identifier id) const
const std::string & key() const
Return the StoreGate ID for the referenced object.
IntegerProperty m_min_pixel_hits
std::vector< int > m_hole_chip
const Amg::Vector3D & center() const
Returns the center position of the Surface.
PublicToolHandle< Trig::ITrigDecisionTool > m_trigDec
ServiceHandle< ITRT_StrawNeighbourSvc > m_TRTStrawNeighbourSvc
std::vector< int > m_hole_straw
#define AmgSymMatrix(dim)
uint32_t runNumber() const
The current event's run number.
std::vector< int > m_hole_det
std::vector< float > m_hole_locR
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
std::vector< float > m_hit_locR
std::vector< int > m_hit_HL
std::vector< float > m_hole_center_x
std::vector< float > m_hit_center_y
IntegerProperty m_min_trt_hits
SG::ReadHandleKey< xAOD::VertexContainer > m_vertexContainerKey
std::vector< float > m_hit_R
std::vector< int > m_hole_layer
std::vector< float > m_hole_center_y
int straw(const Identifier &id) const
std::vector< float > m_hole_y
std::vector< float > m_hit_ub_locR
StringProperty m_stream_name
@ Hole
A hole on the track - this is defined in the following way.
std::vector< int > m_hit_pad
ToolHandle< Trk::ITrackHoleSearchTool > m_trt_hole_finder
unsigned int m_num_tracks
::StatusCode StatusCode
StatusCode definition for legacy code.
std::vector< float > m_hit_center_z
std::vector< float > m_hit_x
std::vector< float > m_hole_x
SG::ReadHandleKey< xAOD::EventInfo > m_eventInfoKey
std::vector< int > m_hit_strawlayer
SG::ReadHandleKey< TrackCollection > m_tracksKey
FloatProperty m_max_abs_eta
#define ATH_MSG_ALWAYS(x)
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
int barrel_ec(const Identifier &id) const
Values of different levels (failure returns 0)
int straw_layer(const Identifier &id) const
int layer_or_wheel(const Identifier &id) const
uint32_t lumiBlock() const
The current event's luminosity block number.
virtual bool isValid() override final
Can the handle be successfully dereferenced?
int fill_hit_data(const Trk::TrackStateOnSurface &hit)
const Amg::MatrixX & localCovariance() const
Interface method to get the localError.
FloatProperty m_max_abs_z0
represents the track state (measurement, material, fit parameters and quality) at a surface.
std::vector< int > m_hit_tube_hit
double error(const Amg::MatrixX &mat, int index)
return diagonal error of the matrix caller should ensure the matrix is symmetric and the index is in ...
int fill_hole_data(const Trk::TrackStateOnSurface &hole)
std::vector< int > m_hole_phi
int phi_module(const Identifier &id) const
const LocalParameters & localParameters() const
Interface method to get the LocalParameters.
Abstract interface to information on straws electronic grouping.
unsigned int m_run_number
std::vector< int > m_hit_det
std::vector< float > m_hit_ub_x
#define ATH_MSG_WARNING(x)
StringProperty m_required_trigger
std::vector< float > m_hit_ub_y
std::vector< int > m_hole_bec
std::vector< float > m_hole_center_z
unsigned int m_lumi_block
std::vector< int > m_hole_strawlayer
TRTStrawEfficiency(const std::string &name, ISvcLocator *pSvcLocator)
unsigned int m_num_events
Handle class for reading from StoreGate.
std::vector< float > m_hole_locR_error
IntegerProperty m_min_sct_hits
size_type size() const noexcept
Returns the number of elements in the collection.
std::vector< float > m_hit_z
@ Measurement
This is a measurement, and will at least contain a Trk::MeasurementBase.
std::vector< int > m_hit_straw
std::vector< float > m_hit_y