ATLAS Offline Software
Loading...
Searching...
No Matches
TauolappConfig.py
Go to the documentation of this file.
1# Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
2
3from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
4from AthenaConfiguration.ComponentFactory import CompFactory
5from GeneratorConfig.Sequences import EvgenSequence, EvgenSequenceFactory
6
7# Get logger
8from AthenaCommon.Logging import logging
9log = logging.getLogger("TauolappConfig")
10
11
12def TauolappCfg(flags, name="TauolaPP_i", **kwargs):
13 """
14 The main Tauola configuration fragment that sets up the
15 algorithm and returns a CA instance.
16 """
17
18 # Set default config
19 kwargs.setdefault("decay_mode_same", 0)
20 kwargs.setdefault("decay_mode_opposite", 0)
21 kwargs.setdefault("decay_particle", 15)
22 kwargs.setdefault("tau_mass", 1.77684)
23 kwargs.setdefault("spin_correlation", True)
24 kwargs.setdefault("setRadiation", True)
25 kwargs.setdefault("setRadiationCutOff", 0.01)
26
27 # Create CA object
28 ca = ComponentAccumulator(EvgenSequenceFactory(EvgenSequence.Generator))
29 ca.addEventAlgo(
30 CompFactory.TauolaPP(name, **kwargs)
31 )
32
33 # Announce generator to service
34 from GeneratorConfig.GeneratorInfoSvcConfig import GeneratorInfoSvcCfg
35 ca.merge(GeneratorInfoSvcCfg(flags, Generators=["TauolaPP"]), sequenceName=EvgenSequence.Generator.value)
36
37 return ca
TauolappCfg(flags, name="TauolaPP_i", **kwargs)