Difference: Hlt2SharedParticles (2 vs. 3)

Revision 32009-04-29 - unknown

Line: 1 to 1
 
META TOPICPARENT name="HltLine"
Changed:
<
<

What is an Hlt2SharedParticle?

Hlt2SharedParticles are intermediate states which should be made once for all Hlt2 lines. Examples would be a K* or φ which could be reused between several different lines. Because of this, Hlt2SharedParticles are not Hlt2Lines. They are made "on-demand" when requested by an Hlt2Line, and if another line subsequently asks for the same Hlt2SharedParticle it is pointed to the same particles; hence all shared particles are made at most once per event. If no Hlt2Line requests a specific shared particle, it is never made.
>
>

What is an Hlt2SharedParticle?

Hlt2SharedParticles are intermediate states which should be made once for all Hlt2 lines. Examples would be a K* or φ which could be reused between several different lines. Because of this, Hlt2SharedParticles are not Hlt2Lines. They are made "on-demand" when requested by an Hlt2Line, and if another line subsequently asks for the same Hlt2SharedParticle it is pointed to the same particles; hence all shared particles are made at most once per event. If no Hlt2Line requests a specific shared particle, it is never made.
 
Changed:
<
<

Including Hlt2SharedParticles in a line

See Hlt2Lines for a full example but, since an Hlt2SharedParticle is just a configurable, they are imported through
from Hlt2SharedParticles.MyParticle import MyParticle2MyFinalState
There are two further required steps: declaring the shared particle in the input location of an Hlt2Member or CombineParticles/FilterDesktop instance, and declaring it in the Hlt2Line itself. First of all, in order to be able to use the Hlt2SharedParticle in the Hlt2Line, it must be added to the algos list of that line, for example:
>
>

Including Hlt2SharedParticles in a line

See Hlt2Lines for a full example but, since an Hlt2SharedParticle is just a configurable, they are imported through
from Hlt2SharedParticles.MyParticle import MyParticle2MyFinalState
There are two further required steps: declaring the shared particle in the input location of an Hlt2Member or CombineParticles/FilterDesktop instance, and declaring it in the Hlt2Line itself. First of all, in order to be able to use the Hlt2SharedParticle in the Hlt2Line, it must be added to the algos list of that line, for example:
 
myLine = Hlt2Line( "myLineName",
                             prescale,
Line: 14 to 14
  Finally, to actually use the shared particle:

Changed:
<
<
  • To use in an Hlt2Member
    inputLocations = [MyParticle2MyFinalState]
  • To use in a CombineParticles/FilterDesktop instance
    inputLocations = [MyParticle2MyFinalState.outputSelection()]
>
>
  • To use in an Hlt2Member
    inputLocations = [MyParticle2MyFinalState]
  • To use in a CombineParticles/FilterDesktop instance
    inputLocations = [MyParticle2MyFinalState.outputSelection()]
 
Changed:
<
<

Example of creating an Hlt2SharedParticle

>
>

Example of creating an Hlt2SharedParticle

 
from Gaudi.Configuration import * 
from Hlt2SharedParticles.GoodParticles import GoodPions, GoodKaons
Line: 41 to 41
 

Notes on the example

Changed:
<
<
  • In the code above,
    __all__
    is where you declare all of the shared states in that particular MySharedParticle.py file. If you look at the actual $HLT2SHAREDPARTICLES/python/Hlt2SharedParticles/D0.py file you will see several other final states for the D0 to decay into being declared, but the list was shortened for this example. Separate the shared states with commas:
    __all__ = ('Decay1','Decay2',...)
  • Since Hlt2SharedParticles are not Hlt2Lines, do not declare any Hlt2Members/Hlt2Lines here. Just CombineParticles/FilterDesktop instances.
  • Finally use bindMembers to create a concrete instance of your shared particle for use in an Hlt2Line. Make sure you include everything it depends on; in this case, the D02KPi shared particle depends on the GoodPions and GoodKaons (also shared particles) so you must say
     D02KPi = bindMembers( None, [ GoodKaons, GoodPions, Hlt2SharedD02KPi ] ) 
>
>
  • In the code above,
    __all__
    is where you declare all of the shared states in that particular MySharedParticle.py file. If you look at the actual $HLT2SHAREDPARTICLES/python/Hlt2SharedParticles/D0.py file you will see several other final states for the D0 to decay into being declared, but the list was shortened for this example. Separate the shared states with commas:
    __all__ = ('Decay1','Decay2',...)
  • Since Hlt2SharedParticles are not Hlt2Lines, do not declare any Hlt2Members/Hlt2Lines here. Just CombineParticles/FilterDesktop instances.
  • Finally use bindMembers to create a concrete instance of your shared particle for use in an Hlt2Line. Make sure you include everything it depends on; in this case, the D02KPi shared particle depends on the GoodPions and GoodKaons (also shared particles) so you must say
     D02KPi = bindMembers( None, [ GoodKaons, GoodPions, Hlt2SharedD02KPi ] ) 
  -- VladimirVavaGligorov - 12 Apr 2009
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback