21 return [](
const FE* p,
const Jet&) {
return p->pt();};
23 throw std::logic_error(
"Unknown sort function");
41 if (!link.isValid()) {
42 throw std::logic_error(
"invalid particle link");
46 throw std::runtime_error(
"FlowsLoader: Dynamic cast to FlowElement failed");
48 particles.push_back(flow);
61 std::vector<std::pair<double, const xAOD::FlowElement*>> particles;
65 std::sort(particles.begin(), particles.end(), std::greater<>());
66 std::vector<const xAOD::FlowElement*> only_particles;
67 for (
const auto& particle: particles) {
68 only_particles.push_back(particle.second);
70 return only_particles;
78 return std::make_tuple(
m_seqGetter.getFeats(
jet, sorted_flows), std::vector<const xAOD::IParticle *>{});
ElementLink implementation for ROOT usage.
const ConstituentsType & getType() const override
std::function< FEV(const Jet &)> m_associator
const FTagDataDependencyNames & getDependencies() const override
FlowElementsLoader(const ConstituentsInputConfig &cfg, const FTagOptions &options)
std::function< double(const xAOD::FlowElement *, const Jet &)> FlowElementSortVar
FlowElementSortVar m_flowElementSortVar
getter_utils::SeqGetter< xAOD::FlowElement > m_seqGetter
const std::set< std::string > & getUsedRemap() const override
const std::string & getName() const override
std::vector< const xAOD::FlowElement * > getFlowElementsFromJet(const xAOD::IParticle &jet) const
std::vector< const xAOD::FlowElement * > FEV
std::tuple< Inputs, std::vector< const xAOD::IParticle * > > getData(const xAOD::IParticle &jet) const override
std::vector< const xAOD::FlowElement * > FlowElements
FlowElementSortVar flowElementSortVar(ConstituentsSortOrder)
ConstituentsInputConfig m_config
std::set< std::string > m_used_remap
IConstituentsLoader(const ConstituentsInputConfig &cfg)
FTagDataDependencyNames m_deps
SG::ConstAccessor< T, ALLOC > ConstAccessor
Class providing the definition of the 4-vector interface.
This file contains "getter" functions used for accessing tagger inputs from the EDM.
void sort(typename DataModel_detail::iterator< DVL > beg, typename DataModel_detail::iterator< DVL > end)
Specialization of sort for DataVector/List.
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
FlowElement_v1 FlowElement
Definition of the current "pfo version".