cp3-llbb / HHAnalysis

HH analysis for CP3 llbb framework
0 stars 7 forks source link

Revisit the definition of leptons #18

Closed BrieucF closed 9 years ago

BrieucF commented 9 years ago
OlivierBondu commented 9 years ago

@blinkseb : to address the second point, is there a way around with the structs stored from PR #22 ? Or do we need to store these manually ?

we can request hh_leptons.isID_L, or check @hh_leptons.size(), but I could not find a way to get @hh_leptons.isID_L.size()

blinkseb commented 9 years ago

A shot in the dark here. Does hh_leptons.@isID_L.size() work ? Le 8 oct. 2015 19:03, "Olivier" notifications@github.com a écrit :

@blinkseb https://github.com/blinkseb : to address the second point, is there a way around with the structs stored from PR #22 https://github.com/cp3-llbb/HHAnalysis/pull/22 ? Or do we need to store these manually ?

we can request hh_leptons.isID_L, or check @hh_leptons.size(), but I could not find a way to get @hh_leptons.isID_L.size()

— Reply to this email directly or view it on GitHub https://github.com/cp3-llbb/HHAnalysis/issues/18#issuecomment-146624749.

OlivierBondu commented 9 years ago

It does :smile: !

blinkseb commented 9 years ago

\o/

2015-10-09 9:27 GMT+02:00 Olivier notifications@github.com:

It does [image: :smile:] !

— Reply to this email directly or view it on GitHub https://github.com/cp3-llbb/HHAnalysis/issues/18#issuecomment-146778588.

Sébastien Brochet

swertz commented 9 years ago

So, you have a vector of structures, and this gives you the length of the vector which have isID_L to true?

OlivierBondu commented 9 years ago

yep, aka nLeptonLoose in this case

blinkseb commented 9 years ago

I don't think it's true. hh_leptons.@isID_L.size() should returns the size of the isID_L vector, what ever it's inside.

OlivierBondu commented 9 years ago

correct, did not look correctly at the content, yes, hh_leptons.@isID_L.size() works, but return the same as hh_leptons.isID_L:

so we need to store these multiplicities independently. Is my understanding correct ?

blinkseb commented 9 years ago

Ok that's weird here, I'll do some test, but my understanding so far was:

If you need to access the number of entries with hh_leptons.isID_L == true I don't think there's an easy way to do that in ROOT at Draw time, but maybe there's. Time to restudy the doc :fearful:

OlivierBondu commented 9 years ago

after discussing with @swertz : maybe the easiest and cleanest way would be, in addition to storing hh_leptons.isID_L, to store another vector hh_leptons_L, containing the indices of the loose leptons.

This way we would both have an easy access to multiplicities, and an easy looping access over loose leptons only (not the most optimal for the size, but not the worst either)