Babar logo
HEPIC E,S & H Databases PDG HEP preprints
Organization Detector Computing Physics Documentation
Personnel Glossary Sitemap Search Hypernews
Unwrap page!
Det. Search
Who's who?
Intern. region
Vertex Tracker
Drift chamber
Run Coordination
Contact Experts
Shift Takers Info
Operations Manual
Electronic Logbook
Ops Hypernews
Shift Signup
Check this page for HTML 4.01 Transitional compliance with the
W3C Validator
(More checks...)

How to make a L1 trigger analysis ntuple with your all time favourite package: L1TNTuple

Andreas Meyer updated 11/23/99
Anders W. Borgland updated 02/22/01

L1TNtuple allows the access to the full trigger information, as well as reconstructed DCH and EMC quantities and MC truth information, allowing detailed studies of the trigger performance for both L1 and L3. There are two different executables you can run.

L1TNtupleXtcApp is used to run on XTC-Files (data only). The raw information is accessible in XTC format for any run by staging in the corresponding tapes. The procedure of tape staging and job submission is automated in the script You can edit this file to put your ntuples and output files anywhere you want.

The ntuple can also be produced from RAW data in the Objectivity database using the executable L1TNtupleDbApp and the script Since for most runs the RAW information is not available in the database on disk the natural application of this executable is to run on MC events.

By default the most DETAILED information is NOT being filled in the ntuple. This includes doEMT, doTrigger, doMCTruth, doDchHits ..... The filling of this information must be activated by the USER through tcl-parameter switches in L1TNtupleDbApp.tcl and L1TNtupleXtcApp.tcl; for example 'doDchHits set true' for detailed DCH information and 'doMCTruth set true' for MC truth information.

A complete list of the L1TNtuple variables can be found here.
In case of problems, just send me a mail.

Two options are available: building the executables yourself or run the prebuilt ones (I try to make one once in a while ....). General instructions for both options follow below. In case you want to built your own executables this will put them in your local scratch area (they are rather large) i.e. they will need to be rebuilt regularely.

  • General setup (use any release you want):
      newrel -s $BFROOT/work/'first_letter_in_username'/$USER -t 9.2.0 L1-9.2.0
      cd L1-9.2.0
      addpkg workdir
      addpkg L1TNtuple
      gmake installdirs
      directory for tcl-files: mkdir workdir/steer
      scratch disk directory for ntuple storage: mkdir $BFROOT/work/'first_letter_in_username'/$USER
      cd workdir
      gmake setup
      ln -s ../L1TNtuple/
      ln -s ../L1TNtuple/
  • If you only will run off some other database like ambientboot/recoboot/analboot2/.... and don't need your own private database do (more info in: 'addpkg -h HOWTO', look at HOWTO/HOWTO-database-importing):
    1. GetFDID
      echo FD_NUMBER=<FDID number> > .bbobjy
      gmake database.import BYPASS_LOAD=1

  • Import a database federation if you run MC (more info in: 'addpkg -h HOWTO', look at HOWTO/HOWTO-database-importing):
    1. GetFDID
      echo FD_NUMBER=<FDID number> > .bbobjy
      gmake database.import BYPASS_CONDITIONS_LOAD=yes BYPASS_CONFIG_LOAD=yes
      BdbDmnImport /nfs/objyserv3/objy/databases/snapshots/sp3/latest/Conditions.tdf
      BdbDmnImport /nfs/objyserv3/objy/databases/snapshots/sp3/latest/Configuration.tdf

      For newer releases you will have to do:
      gmake database.import
      gmake database.load SNAPSHOT_DIR=/nfs/objyserv3/objy/databases/snapshots/sp3/latest
  • Build the two executables (but see the last point about prebuilt ones):
    1. bsub -q bldrecoq -o all.log gmake L1TNtuple.all
      bjobs -l <run number>

  • Change Directory to workdir and use the script to run the executable L1TNtupleXtcApp on XTC-data (real data):
    1. edit
      change the run number in foreach run ( <run number> )
      change the run range in foreach evts ( <range> )
      make the indicated changes for the running mode: work, development or interactive
      srtpath <release version> $BFARCH (if necessary)
      setboot (if necessary)
      submit jobs by typing:
      check the jobs typing bjobs
  • Alternatively, use the script to run the executable L1TNtupleDbApp on RAW data in an Objectivity Database Federation:
    1. Edit as necessary. The input collection can be selected using the environment variable L1TInputCollection i.e. 'setenv L1TInputCollection my_collection'. Default CollectionName is 'events'.
  • Hbook files:
      The .hbook files are by default placed in /nfs/farm/babar/trg/$USER/, but they can be placed anywhere by editing the line 'histFileName set /nfs/farm/babar/trg/$USER/babar-$run-$evts-$BFCURRENT.hbook' in l1(db)
  • Prebuilt executables: Version V00-03-36[35] of L1TNuple for releases 8.8.0i and 9.10.3a have been installed on the trigger disk in /nfs/farm/babar/trg/L1TNtuple/L1-8.8.0i[9.10.3a]. Just edit l1(db) so it points to the release you want to run.