The final part of the data processing and analysis chain is a program called VSDIAG [9]. This program summarizes the events from whole fills into histograms, and fills ntuples entries for each cassette. As the next chapter will point out, there is a lot of cuts and calibration constants that needs to be adjusted in order to purify the data as much as possible. These values are read into VSDIAG from a number of input files, of which most are self calibrating.
VSDIAG works with three levels of calibration information - groups, fills and runs. The data taking for all the year can normally be divided into 3-7 different groups with different properties of the beam and hardware setup. Specific information depending on these conditions have to be supplied to VSDIAG after some preliminary analysis of the data. Calibrations that is used commonly for each fill are maintained in specific files, which are automatically updated each time VSDIAG runs on the data. VSDIAG also extracts information for each cassette from the output ntuples(from last time the program processed the data) to calibrate the position and size of some cuts used.
The output from VSDIAG is used for many different purposes. The first time around the output is just used to calibrate the data and to manage input for the next run. Afterwards the data is good enough to be used for quality checking, and thus histograms and ntuples are supplied to THOR to produce quality checking plots. At this stage it is also possible to extract the information specific for the different groups and supply it to VSDIAG.
To achieve a good and stable data output sample, VSDIAG should be executed at least twice more before the data can be transported to the final analysis. This consists of three output channels - two photon physics, beam parameter monitoring and luminosity measurement. The two photon physics uses both an event by event file created by VSDIAG for DELPHI events and a cassette summary file specifying some parameters used for various cuts.
The output ntuples from VSDIAG are merged together group by group for the beam parameter and luminosity analysis. With the help of some other programs(see next section) these are normalized and compared to other DELPHI data. The VSAT information are then used for stability check and backup information.