TWiki> LHCb Web>LHCbTrigger>LHCbTriggerForUsers>L0App (revision 1)EditAttachPDF

L0App: a very simple configurable application for emulating L0

The "L0 Trigger" is a hardware and firmware based trigger, but it can be emulated to surprizing accuracy in software.

(the result of task #42380 )

....... keeping-it-simple-project-plan-from-point-a-to-point-b

What is it?

  • L0App() is a very simple configurable which has only one use, to emulate the L0 add write out a file with L0 Added to it.
  • It is able to do this to any number of MDF files, RAW files, or DSTs, and employs a combination of:
    • InputCopyStream
    • L0Conf
    • MDFWriter

How to use it?

  • Setup the project SetupProject Moore

  • Set up your input
    • any gaudi-card dataset will work, in Ganga, from the book-keeping, or from the TestFileDB... here is an example with a file stored in the TestFileDB
#imagine this is in a file called mydata.py
from GaudiConf import IOExtension
IOExtension().inputFiles(["root://eoslhcb.cern.ch//eos/lhcb/grid/prod/lhcb/swtest/lhcb/swtest/2011_smallfiles_EW/00010197_00000049_1.radiative.dst"])

#imagine this is in a file called L044.py
from Configurables import L0App
L0App().TCK='0x0044'
L0App().outputFile="radiative_plus_l044.dst"
L0App().RecreateL0Banks=True

  • e.g.: gaudirun.py mydata.py L044.py

Resources

Options and settings

  • L0App is about the simplest possible configurable application it's possible to write in LHCb software.
  • L0App has very few options, and all of them are very obvious...
class L0App(LHCbConfigurableUser):
    ## Possible used Configurables
    __used_configurables__ = [ LHCbApp
                             , L0Conf
                             , DecodeRawEvent ]
    
    __slots__ = {
          "EvtMax":            -1    # Maximum number of events to process
        , "SkipEvents":        0
        , "Simulation":        True # True implies use SimCond
        , "DataType":          '2012' # Data type, can be [ '2012','2011'... ]
        , "DDDBtag" :          'default' # default as set in DDDBConf for DataType
        , "CondDBtag" :        'default' # default as set in DDDBConf for DataType
        , "ReplaceL0Banks" : False # remove existing banks first?
        , 'TCK' : '' #"Can be a L0TCK or a full TCK, it doesn't matter"
        , "outputFile" :       '' # output filename
        , 'WriteFSR'    :  True #copy FSRs as required
          
        }

Input Requirements

  • DAQ/RawEvent:
    • just like Moore, L0App requires only one raw event location, and this should be DAQ/RawEvent
    • Use RawEventJuggler twiki to understand what you need to do here and why.
  • How to tell what my input file contains?
from Gaudi.Configuration import *
from Configurables import LHCbApp
from Configurables import RawEventDump
from Configurables import StoreExplorerAlg

StoreExplorerAlg().Load=True
RawEventDump().DumpData=False
LHCbApp().EvtMax=10

ApplicationMgr().TopAlg+=[StoreExplorerAlg(), RawEventDump()]

#add your input files..., example here from Eric
from GaudiConf import IOExtension
IOExtension().inputFiles(['root://castorlhcb.cern.ch//castor/cern.ch/user/e/evh/bwdivision/13774002-juggled.dst'],clear=True)

Feature discussion

  • Immutable: Any L0App version should be able to emulate any/all previous L0 TCKs
    • Each night this is tested, if there is any problem emulating our firmware into the future, the L0 team need to know immediately.
  • Simple: L0App is meant to be as simple as possible, and only to do one task.


-- RobLambert - 24 Mar 2014

Edit | Attach | Watch | Print version | History: r6 | r4 < r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions...
Topic revision: r1 - 2014-03-24 - RobLambert
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    LHCb All webs login

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