Project

General

Profile

What is in a file?

Using ROOT's TBrowser

In ART you can use ROOT's TBrowser to see what objects are in a file. Just start ROOT up in interactive mode and make a TBrowser, ie

$ root
root [0] TBrowser tb

Now just navigate to your ROOT file and click through the TTree branches to see what is there. Specifically, the "Events" branch has all the objects made and put into the event. The objects are named as

nmspcObject_modlabel_job

where nmspc is the namespace the object lives in, Object is the name of the object, modlabel is the name of the process of the module in the .fcl job file and job is the name of the job process in the .fcl file.

Using eventdump.fcl

The source:Utilities/eventdump.fcl file is a job control file that will output the contents of the Event folder for each event in a file. To run it do

$ nova -c eventdump.fcl filename.root

which will output a record like this for each event:

Begin processing the 1st record. run: 1 subRun: 0 event: 1 at 26-Apr-2011 15:51:17 CDT
PROCESS NAME.. | MODULE LABEL.. | PRODUCT INSTANCE NAME | DATA PRODUCT TYPE.............................. | SIZE
SingleParticle | geantgen...... | ..................... | art::Wrapper<std::vector<sim::ParticleList> >.. | ...1
SingleParticle | geantgen...... | ..................... | art::Wrapper<std::vector<sim::FLSHitList> >.... | ...1
SingleParticle | daq........... | ..................... | art::Wrapper<std::vector<rawdata::RawTrigger> > | ...1
SingleParticle | TriggerResults | ..................... | art::Wrapper<art::TriggerResults>.............. | ...-
SingleParticle | daq........... | ..................... | art::Wrapper<std::vector<rawdata::RawDigit> >.. | .177
SingleParticle | generator..... | ..................... | art::Wrapper<std::vector<simb::MCTruth> >...... | ...1
SingleParticle | photrans...... | ..................... | art::Wrapper<std::vector<sim::PhotonSignal> >.. | 6539

POT information

The data files with extension .reco.histo.root have 4 histograms within the 'cana/pottree/fPOTSum' folder:

totpot
totgoodpot
totspills
goodspills

totpot counts pots delivered. totspill counts number of spills seen in a file. Pots are recorded in units of 10^12. The histograms label with the word 'good' only get incremented if the beam was within specifications, e.g. cuts on spot size, beam position, and toroids reading out correctly. If one cuts on these variables spill by spill, then one should use goodpots to count pots. The following is a piece of code that will get the POT out of a:

data file

  art::Handle< sumdata::POTSum > p;
  sr.getByLabel("ifdbspillinfo",p);
  pot = p->totgoodpot;

MC file
  art::Handle< sumdata::POTSum > p;
  sr.getByLabel("generator",p);
  pot = p->totgoodpot;