SLIC

SLIC is the GEANT4 based full simulation software in the SiD software. It offers access to all default GEANT4 commands plus its own commands.

Installation

Precompiled Binaries

There are precompiled binaries available for selected architectures in the SLIC distribution directory. They have been tested and can be used with SLC4 and SLC5.

Installing from Scratch

Just follow the detailed instructions for Linux or Windows.

Preinstalled Versions on AFS

You can find several pre-installed versions on the CERN-LCD AFS space.
/afs/cern.ch/eng/clic/software/slic/
  • 2.5.4
  • 2.7.0
  • 2.7.2
  • 2.8.1
  • 2.8.3
  • 2.8.4
  • 2.9.8

Running Interactively

slic -n
starts an interactive session. Use GEANT4 commands or type help to get a description of all commands.

Running with a GEANT4 Macro

slic -m [mymacro]
runs slic with the commands given in mymacro.

Running on LXBATCH

Since bsub on lxplus does not take command line arguments together with the executable you have to write a small script that will execute slic with a macro. Then you have to send this script to the batch queue.
An automatic submission script written by ChristianGrefe is also available here.

Running on the Grid using ILCDIRAC

Example python script for ILCDIRAC:
from ILCDIRAC.Interfaces.API.DiracILC import DiracILC
from ILCDIRAC.Interfaces.API.NewInterface.UserJob import UserJob

dirac = DiracILC ( True , "repository.rep" )
job = UserJob ( )
slic = SLIC()
slic.setVersion("v2r8p4")
slic.setMacFile("myMacro.mac")
slic.setOutputFile("myOutput.slcio")
slic.setDetectorModel("myDetector")
slic.setNumberOfEvents(100)
res= job.append(slic)
if not res['OK']:
  print res['Message']
  exit(1)
job.setOutputSandbox ( [ "*.log", "*.mac" ] )
job.setOutputData ( "myOutput.slcio" )
job.setCPUTime( 100000 )
job.setSystemConfig ( 'x86_64-slc5-gcc43-opt' )
job.setName ( "mySlicJob" )
job.submit ( dirac )

Example Macros

Using an stdhep generator file as input:
/lcio/PDGFlag true
/physics/select QGSP_BERT
/lcdd/url myDetector.lcdd
/run/initialize
/generator/filename myInput.stdhep
/lcio/filename myOutput.slcio
/random/seed 1234
/run/beamOn 1000

Using the general particle source to generate particles:

/lcio/PDGFlag true
/physics/select QGSP_BERT
/lcdd/url myDetector.lcdd
/run/initialize
/generator/select gps
/gps/pos/type Point
/gps/pos/centre 0. 0. 0.
/gps/ang/type iso
/gps/ang/mintheta 179 deg
/gps/ang/maxtheta 181 deg
/gps/ang/minphi 0 deg
/gps/ang/maxphi 360 deg
/gps/ene/type Mono
/gps/ene/mono 10 GeV
/gps/particle pi+
/lcio/filename myOutput.slcio
/random/seed 1234
/run/beamOn 1000

SLIC Command Line Arguments

Argument Full Name Macro Command Description
-h --help /slic/usage Print SLIC usage.
-? --help /slic/usage Print SLIC usage.
-n --interactive /control/interactive Start a Geant4 interactive session.
-v --version /slic/version Print SLIC version.
-m --macro /control/execute Execute Geant4 commands from a file.
-g --lcdd-url /lcdd/url Set LCDD geometry file URL.
-i --event-file /generator/filename Set event input file full path.
-o --lcio-file /lcio/filename Set name of LCIO output file.
-p --lcio-path /lcio/path Set directory for LCIO output.
-O --autoname /lcio/autoname Automatically name the LCIO output file.
-x --lcio-delete /lcio/fileExists delete Delete an existing LCIO file.
-r --run-events /run/beamOn Run # of events.
-s --skip-events /generator/skipEvents Set number of events to skip.
-l --physics-list /physics/select Set Geant4 physics list.
-L --log-file /log/filename Set logfile name.
-d --seed /random/seed Set the random seed. (No argument seeds with time.)
-G --dump-gdml /lcdd/dumpGDML Dump geometry to GDML file.
-c --optical /physics/enableOptical Enable optical physics processes.
-P --pdg-file /physics/setPDGFile Set location of particle.tbl file.

FAQ

In which order should commands be executed?

/run/initialize is used to initialize the geometry and is mandatory.
The physics list (/physics/select) and detector geometry (/lcdd/url) have to be set before /run/initialize.
Most other commands, like particle source commands etc. have to be executed after /run/initialize.
/run/beamOn is usually the last command to executed.

How to set a crossing angle?

/generator/setLorentzTransformationAngle 7 mrad

What does particle ID X stand for?

List of particle IDs in GEANT4
Edit | Attach | Watch | Print version | History: r7 < r6 < r5 < r4 < r3 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r7 - 2013-02-08 - StephanePoss
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    CLIC All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2018 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback