IFR Ambient Data Monitoring

Location of the web pages | Overview | Recipe for compiling and running | Running OdcNtupleMaker | makentuple script options | The AmbientNtupleAnalysis


All are linked from the main IFR page:



Several steps are necessary to get to the plots on the web pages:
  1. The ambient data monitoring the status of the detector are being constantly stored in the ambient database, which is an Objectivity database. The process filling this database is called archiver and is a central BABAR utility. Its setup contains information on what to write and how often.
  2. The application OdcNtupleMaker is used to extract data from the ambient database into ntuples. Several ntuples are produced to contain High Voltage CAEN data, dark currents from GMBs, temperature readings and single rates respectively.
  3. A Set of C++ applications read the ntuples produced by OdcNtupleMaker, perform some analysis on it, produce histograms or data in ASCII format for history plots.
  4. Several paw kumac read the output from the applications in 3) to produce plots.
  5. The plots are moved to the web area and the web pages are updated if necessary.
A daily cronjob (using trscrontab, a cron utility giving an afs token) runs a shellscript once daily which perfroms steps 2 through 5.


Get the archive file at: http://www.slac.stanford.edu/~vuko/work/ifrmon.tgz

(you'll need your BABAR HyperNews password)

and untar in some directory of your choice:
> cd 
> gtar xvzf ifrmon.tgz

Compile and link:

> mkdir -p .Linux/obj
> mkdir    .Linux/lib
> gmake

Create some directories for temporary output:

> mkdir .ntuples
> mkdir .psfiles
> mkdir .temp
> mkdir .dark 
> mkdir .single

At the beginning of the file makentuple (a shell script) edit the lines


(replace the brackets "<...>" with actual directory names)

And be brave and run! :)

> makentuple
That should do all steps from 2 to 5 in the overview.

Running OdcNtupleMaker

The OdcNtupleMaker can now be found in a standard offline release. It takes two arguments:

> OdcNtupleMaker [inputfile] [outputntuple]


makentuple script options

The makentuple script takes the following options:

> makentuple [mode] [Name] [year] [month] [date]

- [mode] can be:
   update       : the default, does monthly plots and updates the web pages
   quarterplots : does longer time interval plots (3 months for now)
   anything else: will do the monthly plots but without updating the web pages, mostly
                  for debugging purposes
- [Name] : give it the name of the time period (arbitrary string)
- The other parameters set the time interval to plot, where each can be
  either a single number or an interval in the form "i-j". So for instance

 makentuple noupdate Fall 2002 9-10 5-28

 will do plots for the period from Sept. 9th to October 28th 2002
 (without updating the web pages!).

Without arguments, makentuple will do plots for the interval:
- Up to the 6th day of the month: from the 1st of the
  previous month to the current date (up to a few hours before the 
  script is run)
- From the 7th day of the month: from the 1st of the current month
  to the current date.
and it will update the web pages with the new plots. When it starts
doing plots for the new month (from the 7th of each month) it should
also update the links.
 (it should be checked that this is not broken!).

AmbientNtuple Analysis

To perform analysis on the ntuples produced by OdcNtupleMaker, a set of C++ applications have been written. Class definitions (*.h files )are located in the include/ directory, while class implemenations (*.cc) and executables (*.C files, containing a main ) are located in the src/ directory. The important classes are:

Vuko Brigljevic