Loading [MathJax]/extensions/tex2jax.js
 |
ATLAS Offline Software
|
Go to the documentation of this file.
41 declareInterface<IDataRetriever>(
this);
48 "if true only write primary and secondary vertex, placeholder to be removed");
64 double diff1 = ( per1->parameters()[
Trk::d0] -
66 double diff2 = ( per1->parameters()[
Trk::z0] -
68 double diff3 = ( per1->parameters()[
Trk::phi0] -
70 double diff4 = ( per1->charge() -
72 double diff5 = ( per1->pT() -
75 matched = diff1+diff2+diff3+diff4+diff5 == 0.;
96 std::string searchStr =
"TrackParticle";
100 if (
found!=std::string::npos){
109 for(
const auto track : *tracks) {
124 for(
const auto track : *tracks) {
125 const Trk::Perigee* trackPerigee = track->perigeeParameters();
133 return StatusCode::SUCCESS;
152 return StatusCode::SUCCESS;
166 if (
msgLvl(MSG::WARNING))
msg(MSG::WARNING) <<
"Primary vertex container "
183 for ( ; vtxCollectionItr != vtxCollectionsEnd; ++vtxCollectionItr ) {
186 if ( (!
m_doWriteHLT) && ( vtxCollectionItr.
key().find(
"HLT") != std::string::npos)){
195 <<
" with " << NVtx <<
" entries");
198 x.reserve(
x.size()+NVtx);
199 y.reserve(
y.size()+NVtx);
200 z.reserve(
z.size()+NVtx);
201 primVxCand.reserve(primVxCand.size()+NVtx);
205 numTracks.reserve(numTracks.size()+NVtx);
209 if (!
sc.isFailure()) {
215 for ( ; vertexItr != vtxCollectionItr->end(); ++vertexItr) {
230 float this_chi2 = -1;
237 float this_x = (*vertexItr)->recVertex().position().x()/10.;
238 float this_y = (*vertexItr)->recVertex().position().y()/10.;
239 float this_z = (*vertexItr)->recVertex().position().z()/10.;
240 float R = std::hypot (this_x, this_y);
247 chi2.emplace_back( this_chi2 );
248 x.emplace_back( this_x );
249 y.emplace_back( this_y );
250 z.emplace_back( this_z );
255 ATH_MSG_DEBUG(
" collection " << vtxCollectionItr.
key() <<
": VertexType: " << vtx_type);
258 if ( &(*vtxCollectionItr) == primaryVtxCollection ){
259 if (
Trk::PriVtx == vtx_type ){ primVxCand.emplace_back( 1 );
260 }
else{ primVxCand.emplace_back( 0 ); }
261 }
else if ( &(*vtxCollectionItr) == secondaryVtxCollection ){
262 primVxCand.emplace_back( 2 );
264 primVxCand.emplace_back( 0 );
279 covMatrix.emplace_back(
"2 -.1 .5 -.01 0.002 .01");
289 const std::vector<Trk::VxTrackAtVertex*>* trklist = (*vertexItr)->vxTrackAtVertex();
293 numTracks.emplace_back( trklist->size() );
296 tracks.emplace_back( -1 );
305 dataMap[
"primVxCand"] = primVxCand;
308 dataMap[
"numTracks"] = numTracks;
313 if (!numTracks.empty()){
315 double NTracksPerVertex = tracks.size()*1./numTracks.size();
316 std::string
tag =
"tracks multiple=\"" +
DataType(NTracksPerVertex).toString()+
"\"";
std::vector< const Trk::Perigee * > m_perigeeVector
Const iterator class for DataVector/DataList.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
const std::string & key() const
Get the key string with which the current object was stored.
Dummy class used to allow special convertors to be called for surfaces owned by a detector element.
std::vector< DataType > DataVect
Defines a map with a key and a vector of DataType objects e.g.
bool msgLvl(const MSG::Level lvl) const
double doubleNumberDoF() const
returns the number of degrees of freedom of the overall track or vertex fit as double
std::map< std::string, DataVect > DataMap
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
VertexRetriever(const std::string &t, const std::string &n, const IInterface *p)
Standard constructor.
std::string m_conversionVertexKey
StoreGate key for conversion candidate collection.
float m_chi2Cut
Chi^2 over NumberOfDegreesOfFreedom cut.
::StatusCode StatusCode
StatusCode definition for legacy code.
virtual std::string dataTypeName() const
Return the name of the data type.
double chi2(TH1 *h0, TH1 *h1)
Class to represent and store fit qualities from track reconstruction in terms of and number of degre...
virtual bool isValid() override final
Can the handle be successfully dereferenced?
void manualPerigeeMatch(const Trk::Perigee *per1, const Trk::Perigee *per2, bool &matched)
Manually match measured perigee d0,z0,phi0 of Trk::Track and Rec::TrackParticle, some problem with di...
This header is shared inbetween the C-style server thread and the C++ Athena ServerSvc.
std::string m_trackCollection
StoreGate key for track collection for association.
FitQualityOnSurface fitQuality(const MultiComponentState &, const MeasurementBase &)
Method for determining the chi2 of the multi-component state and the number of degrees of freedom.
#define ATH_MSG_WARNING(x)
std::string m_primaryVertexKey
StoreGate key for primary vertex candidate collection.
virtual StatusCode retrieve(ToolHandle< IFormatTool > &FormatTool)
Retrieve all the data.
virtual StatusCode fillPerigeeList()
Retrieve measured perigee, automatically switch between Trk::Track and Rec::TrackParticle depending o...
std::string m_secondaryVertexKey
StoreGate key for secondary vertex candidate collection.
bool m_doWriteHLT
wether to write HLTAutoKey objects
BASE::size_type size_type
size_type size() const noexcept
Returns the number of elements in the collection.
double chiSquared() const
returns the of the overall track fit
bool m_doWritePrimAndSecVertexOnly
write primary and secondary vertizes only - placeholder, to be removed