Replace indices in CHILD functor with decay selector
Opened this issue · 4 comments
As part of the LoKi functors lesson, the CHILD
functor is taught with indices to select the child. As this depends on the ordering of the decay descriptor, it is discouraged. Perhaps the indices could be replaced with with decay selectors?
This brings its own complications, as (some minimal version of the) the grammar would have to be explained. At the same time, this is already part of the DTT lesson. Perhaps the lessons can be reordered to have the DTT lesson first up to the HybridTupleTool part, then the LoKi functors lesson, and then return to the DTT with the newly gained insights.
This might have the advantage that some "magic" particular to GaudiPython, e.g. explicit creation of the LoKi::DistanceCalculator
can be avoided.
I like the idea of re-ordering the lessons a lot 👍
Having just taught this lesson, I think we have to reorder these lessons a bit. I wholeheartedly agree :-)
At the same time, this ordering of children appears not just in the CHILD
functor, but e.g. in the functors like M1
(mass of the first child) - used in the MotherCut
of our stripping line.
The usage in the stripping line is not so bad because you're very close to the definition of the ordering (the cut is a property of the same CombineParticles
instance in which the decay descriptor is given). But yes, it's still not ideal.