AsgLeptonTrackSelectionAlg.h 2.6 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
/*
  Copyright (C) 2002-2018 CERN for the benefit of the ATLAS collaboration
*/

/// @author Nils Krumnack



#ifndef ASG_ANALYSIS_ALGORITHMS__ASG_LEPTON_TRACK_SELECTION_ALG_H
#define ASG_ANALYSIS_ALGORITHMS__ASG_LEPTON_TRACK_SELECTION_ALG_H

#include <AnaAlgorithm/AnaAlgorithm.h>
#include <PATCore/IAsgSelectionTool.h>
#include <SelectionHelpers/ISelectionAccessor.h>
#include <SelectionHelpers/SelectionReadHandle.h>
#include <SystematicsHandles/SysListHandle.h>
17
18
#include <SystematicsHandles/SysReadHandle.h>
#include <xAODBase/IParticleContainer.h>
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72

namespace CP
{
  /// \brief an algorithm for performing track-vertex selection on
  /// leptons
  ///
  /// Originally I meant to implement this as an \ref
  /// IAsgSelectionTool, but since this needs other objects besides
  /// the lepton itself, I made it into an algorithm.  Technically
  /// this could also be addressed by retrieving those extra objects
  /// in the seleciton tool, but this seemed like potential overkill,
  /// given that the selection tools may be called very frequently and
  /// are not really doing any form of heavy lifting at all.  Still,
  /// at some point we may decide to change this into a selection tool
  /// instead (06 Aug 18).

  class AsgLeptonTrackSelectionAlg final : public EL::AnaAlgorithm
  {
    /// \brief the standard constructor
  public:
    AsgLeptonTrackSelectionAlg (const std::string& name, 
                                   ISvcLocator* pSvcLocator);


  public:
    StatusCode initialize () override;

  public:
    StatusCode execute () override;


    /// algorithm properties
    /// \{

  private:
    float m_maxD0Significance {0};
    float m_maxDeltaZ0SinTheta {0};
    int m_nMinPixelHits{-1};
    int m_nMaxPixelHits{-1};
    int m_nMinSCTHits{-1};
    int m_nMaxSCTHits{-1};
    std::string m_selectionDecoration {"trackSelection"};
    std::string m_eventInfo {"EventInfo"};
    std::string m_primaryVertices {"PrimaryVertices"};

    /// \}


    /// \brief the systematics list we run
  private:
    SysListHandle m_systematicsList {this};

    /// \brief the particle continer we run on
  private:
73
    SysReadHandle<xAOD::IParticleContainer> m_particlesHandle {
74
75
76
77
78
79
80
81
82
83
84
85
      this, "particles", "", "the asg collection to run on"};

    /// \brief the preselection we apply to our input
  private:
    SelectionReadHandle m_preselection {
      this, "preselection", "", "the preselection to apply"};

    /// \brief the accessor for \ref m_selectionDecoration
  private:
    std::unique_ptr<ISelectionAccessor> m_selectionAccessor;


86
    /// \brief the \ref asg::AcceptInfo we are using
87
  private:
88
    asg::AcceptInfo m_accept;
89
90
91
92
  };
}

#endif