Streamline FunctionalFlavourTagging algorithm implementations
- amalgamate component header files into their source files
- drop unnecessary header includes
- drop commented out and duplicated code
- pick up algorithm interface from LHCb::Algorithm instead of Gaudi::Functional
- prefer Particle::Range over Particles
- make constants
static constexpr - declare CloneStatus as a 'strong' enum
- prefer multiplication over division
- replace
if (value) return true ; else return falsebyreturn value; - move
cloneCategoryfrom TaggingHelperTool to TaggingHelper as it does not access any members of TaggingHelperTool - move
bestPVUnbiasedfromTaggingHelpertoFunctionalSSPionTaggeras it is the only place where it is used - prefer
std::accumulateover raw for loops - optimize computation of dPhi (avoid multiple trigonometric functions and some divisions)
- avoid use of
essentiallyEqualin comparison used for sorting as it can give unexpected (and wrong) results (see https://godbolt.org/z/sv8oWEvYe for a demonstration) -- given that it violates one of the axiomssortrelies on, this is formally 'undefined behaviour' and could even result insortending up going out-of-bounds and crashing (very unlikely in practice though)
Edited by Gerhard Raven