ATLAS Offline Software
Loading...
Searching...
No Matches
AsgViewFromSelectionAlg.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
6
7
8
9#ifndef ASG_ANALYSIS_ALGORITHMS__ASG_VIEW_FROM_SELECTION_ALG_H
10#define ASG_ANALYSIS_ALGORITHMS__ASG_VIEW_FROM_SELECTION_ALG_H
11
19#include <limits>
20
21namespace CP
22{
30
32 {
34 public:
36 StatusCode initialize () override;
37 StatusCode execute () override;
38
39
41 private:
43
45 private:
47 this, "input", "", "the input collection to run on"};
48
50 private:
52 this, "output", "", "the output view container to produce"};
53
56 private:
57 Gaudi::Property<std::vector<std::string>> m_selection {this, "selection", {}, "the list of selection decorations"};
58
59 private:
60 Gaudi::Property<std::vector<SelectionType>> m_ignore {this, "ignore", {}, "the list of cuts to *ignore* for each selection"};
61
63 private:
64 Gaudi::Property<bool> m_sortPt {this, "sortPt", false, "whether to sort objects in pt"};
65
67 private:
68 Gaudi::Property<bool> m_allowMissing {this, "allowMissing", false, "Allow the input container to be missing"};
69
71 private:
72 Gaudi::Property<bool> m_deepCopy {this, "deepCopy", false, "perform a deep copy"};
73
74 private:
75 Gaudi::Property<std::size_t> m_sizeLimit {this, "sizeLimit", std::numeric_limits<std::size_t>::max(), "the limit on the size of the output container"};
76
78 private:
79 std::vector<std::pair<std::unique_ptr<ISelectionReadAccessor>,SelectionType> > m_accessors;
80
82 private:
83 template<typename Type> StatusCode
85
87 private:
88 StatusCode executeFindType (const CP::SystematicSet& sys);
89
91 private:
92 StatusCode executeMissing (const CP::SystematicSet& sys);
93
94 private:
96 };
97}
98
99#endif
create a view container based on selection decorations
Gaudi::Property< std::vector< std::string > > m_selection
StatusCode executeTemplate(const CP::SystematicSet &sys)
the templated version of execute for a single systematic
Gaudi::Property< bool > m_sortPt
Sort the output (view) container by pT.
Gaudi::Property< std::size_t > m_sizeLimit
StatusCode(AsgViewFromSelectionAlg::* m_function)(const CP::SystematicSet &sys)
SysReadHandle< xAOD::IParticleContainer > m_inputHandle
the input collection we run on
Gaudi::Property< bool > m_allowMissing
Allow the input container to be missing.
StatusCode executeMissing(const CP::SystematicSet &sys)
The version of execute for missing input containers.
SysWriteHandle< xAOD::IParticleContainer > m_outputHandle
the output view container we produce
StatusCode executeFindType(const CP::SystematicSet &sys)
the version of execute to find the type
Gaudi::Property< std::vector< SelectionType > > m_ignore
Gaudi::Property< bool > m_deepCopy
Perform a deep copy for creating the output container.
std::vector< std::pair< std::unique_ptr< ISelectionReadAccessor >, SelectionType > > m_accessors
the list of accessors and cut ignore list
SysListHandle m_systematicsList
the systematics list we run
a class managing the property to configure the list of systematics to process
a data handle for reading systematics varied input data
a data handle for writing systematics varied input data
Class to wrap a set of SystematicVariations.
the (new) base class for EventLoop algorithms
AnaAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
constructor with parameters
Select isolated Photons, Electrons and Muons.
uint32_t SelectionType
the type for selection decorations that are meant to hold a asg::AcceptData