Preparing for a new experiment¶
Setting up offline analysis for a new experiment typically involves the following steps:
- Determine the experimental configuration (spectrometers, detectors, beamline) to be analyzed and identify the corresponding analysis modules.
- Create a database for the new experiment, using the start date of the data taking as the time-stamp for new new entries see database overview. At the minimum the database should contain up-to-date detector map entries for every detector and rough starting values for the spectrometer reconstruction matrix elements and VDC timing offsets. Often this information can be carried over from a previous experiment with only minor modifications. Also, enter any other calibrations and geometry data that are available, even if approximate.
- In the database, create initial run database values. These are typically the starting beam energy and spectrometer momentum and angle settings. If the experiment is already completed, extract the history of these settings from logs and enter them into the database. These values affect the kinematics calculations; they are not important for detector checkout.
- Determine which physics calculations are needed for the offline analysis and identify corresponding Physics Modules.
- Identify desired output histograms and tree variables. Create an output definition file. The file
$ANALYZER/examples/output_example.defcontains most of the necessary documentation.
- If desired, create a definition file for logicals. An example generating detailed VDC statistics is given in
- Write a ROOT script that sets up the configuration identified in Step 1 and the physics analysis decided on in Step 4. Often, a script from a previous experiment, or one of the examples in the directory
$ANALYZER/examples, can serve as a guide. The script usually also locates raw data files, creates one or more
THaRunobjects, configures various options of the event loop object
THaAnalyzer, and starts the replay. In particular, the names of the output file, the output definition file, and the logicals definition file must be given to
- Identify the plots that you wish to generate from the analysis results and write a script to create them. This may be part of the script created in the previous step. Note that there is no need to quit the Analyzer and start a new session or another program after completion of the analysis; all of ROOT's visualization tools are available from within the Analyzer.
Updated by Ole Hansen about 5 years ago · 1 revisions