Hoi Alessio,
it makes me a bit uneasy to live with sequential ordering. We'd have
to be careful not to mess up. Furthermore, this restricts somewhat the
options of breaking the data set into smaller chunks for faster
recoilNtp processing times.
There are at least two alternatives:
- STL set (where we need to find the optimal way to represent a ts,
be that string, TString, char[], struct ts{int upper, int lower};
or something else. STL Maps might also work, I don't know how they
compare as far as performance is concerned.
- TMap (http://www.slac.stanford.edu/comp/unix/package/cernroot/30106/TMap.html)
- Sorted vector, where we'd have to define a < operator for a to be
defined ts class. This has been done in babar s/w already (and is
quite easy anyway, because one just needs to compare upper and
lower of two ts).
The idea with these proposals is to put all 'bad' ts into the set or
map, and then for each event ask whether its ts is contained in the
set/map. The ordered vector might have good look-up times, that needs
to be investigated.
There are probably other methods as well. It would be good to have a
rough estimate of whether we can slurp in the bad ts for all the data
and still achieve good lookup times.
Cheers,
--U.
|