CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Eras.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 class Eras (object):
4  """
5  Dummy container for all the cms.Modifier instances that config fragments
6  can use to selectively configure depending on what scenario is active.
7  """
8  def __init__(self):
9  # These eras should not be set directly by the user.
10  self.run2_common = cms.Modifier()
11  self.run2_25ns_specific = cms.Modifier()
12  self.run2_50ns_specific = cms.Modifier()
13  self.run2_HI_specific = cms.Modifier()
14  self.stage1L1Trigger = cms.Modifier()
15  self.stage2L1Trigger = cms.Modifier()
16  self.phase1Pixel = cms.Modifier()
17  # Implementation note: When this was first started, stage1L1Trigger wasn't in all
18  # of the eras. Now that it is, it could in theory be dropped if all changes are
19  # converted to run2_common (i.e. a search and replace of "stage1L1Trigger" to
20  # "run2_common" over the whole python tree). In practice, I don't think it's worth
21  # it, and this also gives the flexibilty to take it out easily.
22 
23  # Phase 2 sub-eras for stable features
24  self.phase2_common = cms.Modifier()
25  self.phase2_tracker = cms.Modifier()
26  self.phase2_hgc = cms.Modifier()
27  self.phase2_muon = cms.Modifier()
28  # Phase 2 sub-eras for in-development features
29  self.phase2dev_common = cms.Modifier()
30  self.phase2dev_tracker = cms.Modifier()
31  self.phase2dev_hgc = cms.Modifier()
32  self.phase2dev_muon = cms.Modifier()
33 
34  # This era should not be set by the user with the "--era" command, it's
35  # activated automatically if the "--fast" command is used.
36  self.fastSim = cms.Modifier()
37 
38  #
39  # These are the eras that the user should specify
40  #
41  # Run1 currently does nothing. It's useful to use as a no-operation era commands when scripting,
42  # but also retains the flexibility to add Run1 specific commands at a later date.
43  self.Run1 = cms.Modifier()
44  # The various Run2 scenarios for 2015 startup.
45  self.Run2_25ns = cms.ModifierChain( self.run2_common, self.run2_25ns_specific, self.stage1L1Trigger )
46  self.Run2_50ns = cms.ModifierChain( self.run2_common, self.run2_50ns_specific, self.stage1L1Trigger )
47  self.Run2_HI = cms.ModifierChain( self.run2_common, self.run2_HI_specific, self.stage1L1Trigger )
48  # Future Run 2 scenarios.
49  self.Run2_2016 = cms.ModifierChain( self.run2_common, self.run2_25ns_specific, self.stage2L1Trigger )
50  self.Run2_2017 = cms.ModifierChain( self.Run2_2016, self.phase1Pixel )
51  # Scenarios further afield.
52  # Phase2 is everything for the 2023 (2026?) detector that works so far in this release.
53  self.Phase2 = cms.ModifierChain( self.phase2_common, self.phase2_tracker, self.phase2_hgc, self.phase2_muon )
54  # Phase2dev is everything for the 2023 (2026?) detector that is still in development.
55  self.Phase2dev = cms.ModifierChain( self.Phase2, self.phase2dev_common, self.phase2dev_tracker, self.phase2dev_hgc, self.phase2dev_muon )
56 
57  # The only thing this collection is used for is for cmsDriver to
58  # warn the user if they specify an era that is discouraged from being
59  # set directly. It also stops these eras being printed in the error
60  # message of available values when an invalid era is specified.
63  self.stage1L1Trigger, self.fastSim,
64  self.phase2_common, self.phase2_tracker,
65  self.phase2_hgc, self.phase2_muon,
67  self.phase2dev_hgc, self.phase2dev_muon
68  ]
69 
70 eras=Eras()
phase2_common
Definition: Eras.py:24
Run2_50ns
Definition: Eras.py:46
phase2_muon
Definition: Eras.py:27
run2_25ns_specific
Definition: Eras.py:11
phase1Pixel
Definition: Eras.py:16
phase2dev_common
Definition: Eras.py:29
run2_50ns_specific
Definition: Eras.py:12
run2_HI_specific
Definition: Eras.py:13
Run2_HI
Definition: Eras.py:47
phase2dev_muon
Definition: Eras.py:32
stage1L1Trigger
Definition: Eras.py:14
stage2L1Trigger
Definition: Eras.py:15
internalUseEras
Definition: Eras.py:61
Definition: Eras.py:3
run2_common
Definition: Eras.py:10
phase2dev_tracker
Definition: Eras.py:30
Run2_2017
Definition: Eras.py:50
phase2_hgc
Definition: Eras.py:26
phase2dev_hgc
Definition: Eras.py:31
Run1
Definition: Eras.py:43
fastSim
Definition: Eras.py:36
def __init__
Definition: Eras.py:8
Phase2
Definition: Eras.py:53
Run2_2016
Definition: Eras.py:49
phase2_tracker
Definition: Eras.py:25
Run2_25ns
Definition: Eras.py:45
Phase2dev
Definition: Eras.py:55