Best track?
We all agree that there is no single "best track" algorithm as every reconstruction method can spit out it's own vector of tracks with no constraints on which one is the best track. More over, the single vector can hold different types of reconstruction algorithms by design.
Consider a track reconstruction which always(!) generates a best up-going and a best down-going track, in this particular order. In this case you should never take always the first, but check the first two and decide on additional parameters etc. on top of that, it might be that tracks from other reconstruction algorithms are present, so it's not straight forward.
So we decided to provide a single function with the signature e.g. best_track(tracks, strategy)
. Both are mandatory and strategy
is the algorithm selector.
A very first implementation is best_track(tracks, strategy="first")
which will take the first track in each event. This is currently almost always the best strategy.
The implementation is with the upcoming slicing magic something like this:
def best_track(tracks, strategy):
if strategy == "first":
return tracks[:, 0]
ping @pkalaczynski