You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 8 Next »

How the geometry is defined

Each geometry is a subdirectory of hps-detectors/detectors, and must contain the following:

  • compact.xml: defines the geometry in terms of detector modules, each of which corresponds to classes in GeomConverter - used by GeomConverter and LCSim
  • detector.properties: other (non-geometry) detector parameters
  • SamplingFractions: sampling fractions for each calorimeter
  • LCDD file for the geometry: generated from the compact.xml - used by SLIC

Current "official" geometries

Conventions followed for all geometries unless noted otherwise:

  • Beam spot on target defines (0, 0, 0); Y is vertical, Z points down the magnet bore

HPS-Proposal2014-v4 (three versions with different B-fields)

Official geometry for 2014 run studies.

  • SVT rotated 30.52 mrad around target; single sensors for layers 1-3, double sensors with double readout (unganged) for layers 4-6
  • ECal flange is tesselated solid: face at z=1318 mm and photon hole aligned at 30.52 mrad from target
  • Front face of ECal crystals is z=1393 mm; ECal aligned so the photon beam intersects centerline of ECal at its front face

HPS-TestRun-v3

Official geometry for 2012 test run as-built.

  • Current best guess at alignment of SVT
  • Plate-and-pipe ECal flange
  • ECal as surveyed

Adding a new detector

  • make a subdirectory of hps-detectors/detectors; name of the subdirectory is the name of the detector
  • add name of the detector to detectors/taglist.txt
  • copy from another detector: compact.xml, detector.properties, SamplingFractions
  • in compact.xml: change name and comment in <info> block
  • in detector.properties: change name, change ConditionsReader if necessary (TestRunConditionsReader for 2012 test run, HpsConditionsReader for 2014 run) - both of these lines are required
  • use GeomConverter to make LCDD file: see below

Using GeomConverter to make detector descriptions

Detector conversion can be done using hps-detectors/Makefile, but you need to set the environment variable GEOMCONVERTER to point to the GeomConverter jar:

export GEOMCONVERTER=/nfs/slac/g/hps/meeg/GeomConverter/target/GeomConverter-2.5-SNAPSHOT-bin.jar

Run "make" in hps-detectors to get a full list of options, but usually you'll use this to convert a single detector (can ask for heprep, lcdd, gdml, vrml, etc.):

make DETECTOR=HPS-Proposal2014-v2 lcdd

Some of these options (not LCDD or HepRep, both of which are handled solely by GeomConverter) require SLIC to be installed (i.e. "slic" should be in your $PATH).

Viewing LCDD

The LCDD file can be viewed directly using SLIC:

slic -g mygeom.lcdd -n

This puts you in an interactive Geant4 session; here is a suggested series of commands (from How do I visualize with OpenGL):

/vis/scene/create
/vis/scene/add/volume
/vis/open OGLSX
/vis/viewer/refresh

There is a Python script that converts LCDD to GDML and views it in ROOT: DrawLCDD.py

  1. The script requires ROOT to be installed and in the path. It also requires ROOT to have the gdml module, but that is pretty standard by now.
  2. Invoke with -h for options. Main useful option would be to call with -N to only make the lcdd_cleaned.gdml file.
  3. It cannot show tessellated objects. These cause ROOT to crash, so tessellated stuff gets stripped.
  4. It pollutes your working directory with two files: lcdd_cleaned.gdml and lcdd_cleaned.C. The first is a pure gdml file, the second is a root script to render it.
  5. You can rotate and zoom in, make cutaway planes etc all using ROOT interactively. It is useful for checking your geometry.

Viewing GDML

ROOT can view GDML, but not tessellated volumes: How do I visualize with ROOT

Viewing HepRep

WIRED can view HepRep files and can be run as a JAS3 plugin.

  • No labels