Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

org.lcsim Conditions Database

Table of Contents

Overview

The conditions database is designed to allow a running analysis or reconstruction module to access information about the run "conditions". In our current environment, conditions include the entire detector description.

...

No Format
void process(EventHeader header)
{
    // Give a position for the B-field measurement to be retrieved.
    double[] pos = {0,0,0};

    // Provide your own b array to be filled.
    double [] b = {0,0,0};

    // Get the FieldMap from the detector.
    FieldMap field = event.getDetector().getFieldMap();

    // Fill your array with the B field data.
    field.getField(pos, b);

    // Print B field data to screen.
    System.out.println("bfield (" + b[0] + "," + b[1] + "," + b[2] + ")");
}

Creating a New Detector

  1. Download an existing compact description. See Full Detector Simulation using SLIC for instructions. Alternately, you can start a new compact description from scratch.
  2. Change the name field to a unique identifier for your detector.
    No Format
    <info name="YOUR_NAME_HERE"/>
    It is very important to change this tag. Otherwise, the detector conditions system will not recognize your new detector model.
  3. Make all the changes required to this compact description.
  4. Regenerate the LCDD file for your detector. See Converting to LCDD or HepRep using GeomConverter for instructions.
  5. Generate LCIO events with this LCDD file using slic.
  6. Setup an alias to the new detector so JAS/lcsim can find it. (see above)