30 { KeyValue{
"MCTracksLocation",
"/Event/MCTracks" }, KeyValue{
"TracksLocation",
"/Event/Tracks" } } ) {}
33 for (
auto const& track : tracks ) {
35 selection.reserve( 10 );
36 std::copy_if( mcTracks.begin(), mcTracks.end(), std::back_inserter( selection ),
37 [track,
this](
MCTrack mcTrack ) { return almostEqual( track.theta, mcTrack.theta ); } );
38 if ( selection.size() == 0 ) {
44 for (
auto const& mcTrack : mcTracks ) {
46 selection.reserve( 10 );
47 std::copy_if( tracks.begin(), tracks.end(), std::back_inserter( selection ),
48 [mcTrack,
this](
Track track ) { return almostEqual( track.theta, mcTrack.theta ); } );
49 if ( selection.size() == 0 ) {
51 }
else if ( selection.size() > 1 ) {
61 "(Relative) maximum delta theta to consider 2 tracks as identical" };
#define DECLARE_COMPONENT(type)
void operator()(MCTracks const &mcTracks, Tracks const &tracks) const override
CheckerAlg(const std::string &name, ISvcLocator *pSvcLocator)
Gaudi::Accumulators::Counter n_duplicatedTracks
bool almostEqual(float a, float b) const
Gaudi::Accumulators::Counter n_lostTracks
Gaudi::Accumulators::Counter n_foundTracks
Gaudi::Accumulators::Counter n_ghostTracks
Gaudi::Property< float > m_maxDeltaTheta
Implementation of property with value of concrete type.
The ISvcLocator is the interface implemented by the Service Factory in the Application Manager to loc...
std::vector< MCTrack > MCTracks
std::vector< Track > Tracks
details::Consumer< Signature, Traits_, details::isLegacy< Traits_ > > Consumer
Gaudi::ParticleID abs(const Gaudi::ParticleID &p)
Return the absolute value for a PID.
A basic integral counter;.
most simple MC Track ever : in 2D space, starting from the origin and thus fully defined by an angle ...
most simple Track ever : in 2D space, starting from the origin and thus fully defined by an angle the...