A LArSoft service is a class, with a single instance managed by the framework, that performs an operation. A service is used by LArSoft algorithms and art modules. Source*

Most of LArSoft services are factorized into two parts:

  1. service provider actually providing services that can be used stand-alone (without art framework) ⇒ e.g. for a minimalist test environment
  2. art service interfacing the provider with the art framework

This factorization model allows service providers to be tested without pulling in the art framework, and to be used in art-unaware environments.

By using service providers, most of the user code should interact only with the provider interface.

  1. Obtain the service provider such as geometry, detector-properties, timing, etc.
  2. Use it, move it around, pass it to algorithms.


This is a simple scheme of LArSoft services in factorization model:

  • the service creates and owns an instance of the provider
  • the provider is a free class that knows only about its own job


LArSoft Services

Services are provided in the areas of geometry, physical properties, physics simulation and miscellaneous.

Geometry services provide a description of the physical and readout aspects of the detector such as:

  1. TPC structure  – physical characteristics of cryostats, TPCs, wire planes and wires and their relations
  2. optical detector structure
  3. readout channel mappings
    • TPCs (e.g. readout channels to physical wires)
    • optical readout channels with photodetectors
  4. auxiliary detectors

Physical properties services such as:

  1. Detector Properties
    • pertaining mostly to readout sampling rates and readout window size
    • conversion between readout ticks and times
    • drift velocity, dQ/dx → dE/dx
    • electron lifetime

  2. LArProperties about the liquid argon environment
    • radiation length, argon temperature, etc.

Physics simulation services such as:

  1. Voxel Calculator helps with computations in the virtual grid. GEANT splits the detector volume into voxels hence the name.
  2. G4 Parameters stores the parameters GEANT is configured with.
  3. Photon Visibility describes the simulation of the transportation of photons to the optical detectors.
  4. Space Charge describes the effect of distortions of TPC’s electric field.

Miscellaneous services such as:

  1. Detector conditions fetching information about DAQ channel status, pedestals, possibly from databases
  2. Detector Clocks provides a coherent view of times in the event related to the beam trigger.
  3. FFT facilitates the application of Fourier transform in simulation of TPC signals and their calibration (e.g. noise reduction).

For more information, please see the source for this material: