Difference: AllPix (1 vs. 29)

Revision 292017-03-21 - MathieuB

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 475 to 475
 An example of how to read and cluster the tree produced by the command using pyROOT can be found in share/SimpleClusteredAllpixRootFile.py
Added:
>
>

LCIO file Output for EUTelescope Controls

 
Added:
>
>
To generate a LCIO file containing the simulated data, a set of commands are available , as shown in this example :

####################################################################
# Write LCIO File
/allpix/eutelescope/write 1
/allpix/eutelescope/setFolderPath /myDataFolder/FEI4Alone/run2
/allpix/eutelescope/WriteEventID 0

The first command toggle the writing of the files by allpix (one per sensor). The second line specify the folder where the files are to be written, The third line toggles the writing of a fourth field for each sensor in the slcio file. This is needed for compatibility with certain setups.

 
Added:
>
>
Allpix must be compiled with LCIO support for this to work. Mimosa26 data are written as zsdata_m26 collection while the other DUT are written as collection such as Det401, where 401 is the allpix detector Id.
 

Revision 282016-01-18 - MathieuB

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 16 to 16
 

Getting Started with AllPix: Installation

Latest Version

Changed:
<
<
To install the latest version of AllPix:
  1. SSH to lxplus ( not lxplus5)
  2. In the location you wish to install, do:
    svn co http://svn.cern.ch/guest/allpix
  3. Next make a g4 directory with:
    mkdir <somewhere>/g4workdir
  4. Edit
    setup_allpix.sh
    with the location of the g4workdir defined in step 3.
  5. In the allpix directory:
    source setup_allpix.sh
  6. gmake clean
  7. gmake -j8
(might have to repeat gmake steps for some reason)
>
>
Allpix is migrating to github and a new repository has been created there to hold the future versions of Allpix. The current version is compatible with ROOT6 and GEANT4.10

To install the latest version of AllPix: follow the instructions from the file README.md at the following link : https://github.com/ALLPix/allpix

 

Previous Releases

Line: 460 to 458
  This will create on ASCII file per frame in the specified folder, which contains all the digitised hits for each simulated sensor planes.
Added:
>
>

Simple ROOT file Output Controls

To generate simple ROOT file containing a tree with the simulated data, a set of commands are available , as shown in this example :

####################################################################
# Write ROOT File
/allpix/WriteROOTFiles/write 1
/allpix/WriteROOTFiles/setFolderPath /myDataFolder/FEI4Alone/run2

The first command toggle the writing of the files by allpix (one per sensor). The second line specifiy the folder where the files are to be written,

An example of how to read and cluster the tree produced by the command using pyROOT can be found in share/SimpleClusteredAllpixRootFile.py

 

Beam Definition and Simulation scenario Controls

Revision 272015-05-01 - JohnIdarraga

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 37 to 37
 

Dependencies

Changed:
<
<
The tricky dependency is OpenInventor (Optional). There is a number of ways in which you can install OpenInventor in your system. One (the most portable) is through the Coin3D project.
>
>
The tricky dependency is OpenInventor (Optional). There is a number of ways in which you can install OpenInventor in your system. One (the most portable) is through the Coin3D project. Head version of Coin3D is not compiling. This revision works just fine

hg clone -r 11361 https://bitbucket.org/Coin3D/coin
  Download and compile Coin and SoXt. ATTENTION soxt-config and coin-config programs should be in your path after installation. Basically libCoin replaces libInventor and libSoXt replaces libInventorXt. Later on, at running time, you have to produce the proper symbolic links in your system

Revision 262014-08-19 - JohnIdarraga

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 52 to 52
 ln -s SOURCE TARGET
Changed:
<
<
Compile geant4 (later than 4.9.5, earlier than 4.10) compatible with allpix (xerces-c, openGL (optional), OpenInventor (optional)) Geant4 home page. WARNING make sure you have cmake >= 2.8.x. Make sure to add Coin/bin and SoXt/bin folders to your path, if compiling with Open Inventor. Cmake will look for the executables 'coin-config' and 'soxt-config' to setup the openInventor driver. Here's the cmake line that will prepare a Geant4 build compatible with allpix:
>
>
The recommended version is geant4.10.00.p02 or higher. You'll find here he cmake set of parameters which will produce a built of geant4 which fully supports allpix. For installation details visit Geant4 home page. Make sure you have cmake >= 2.8.x. Note that cmake will look for 'coin-config' and 'soxt-config' to setup the openInventor driver.
 
Changed:
<
<
cmake -DCMAKE_INSTALL_PREFIX=/home/idarraga/hep/geant4.9.5.p02-install -DGEANT4_USE_GDML=ON -DCMAKE_BUILD_TYPE=Debug -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_OPENGL_X11=ON -DGEANT4_USE_XM=ON -DGEANT4_USE_INVENTOR=ON -DGEANT4_USE_QT=ON /home/idarraga/hep/geant4.9.5.p02
>
>
cmake -DCMAKE_INSTALL_PREFIX=/home/idarraga/hep/geant4.10.00.p02-install -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_GDML=ON -DCMAKE_BUILD_TYPE=Debug -DGEANT4_USE_OPENGL_X11=ON -DGEANT4_USE_XM=ON -DGEANT4_USE_INVENTOR=ON -DGEANT4_USE_QT=ON -DGEANT4_BUILD_MULTITHREADED=ON -DGEANT4_USE_GDML=ON /home/idarraga/hep/geant4.10.00.p02
 
Deleted:
<
<
Remove Open Inventor and OpenGL flags is you compile without these options.
 if everything goes smooth with cmake, now compile geant4 (you probably want to use many cores with -jN flag, where N is the number of cores)

make

Revision 252014-06-18 - JohnIdarraga

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 138 to 138
 Solution 2: add more packages / the following recommendation was found at http://www.linuxquestions.org/questions/programming-9/undefined-reference-problem-819467/
 apt-get install libxerces-c2-dev libssl-dev libboost-dev swig 
Added:
>
>
[reported by J. Idarraga 18-06-2014]

If prebuilding with cmake. For unresolved dependencies use the VERBOSE mode when compiling For Geant >= 4.10

$ make VERBOSE=1  
For GEant <= 4.9
$ export CPPVERBOSE=1
$ make

If anything missing you can append the libraries in the CMakeLists.txt file by using the command (for instance for missing libXt -->

-lXt)
target_link_libraries (allpix Xt)

And then cmake and make.

 

Development in the AllPix Framework

Revision 242014-06-03 - JohnIdarraga

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 55 to 55
 Compile geant4 (later than 4.9.5, earlier than 4.10) compatible with allpix (xerces-c, openGL (optional), OpenInventor (optional)) Geant4 home page. WARNING make sure you have cmake >= 2.8.x. Make sure to add Coin/bin and SoXt/bin folders to your path, if compiling with Open Inventor. Cmake will look for the executables 'coin-config' and 'soxt-config' to setup the openInventor driver. Here's the cmake line that will prepare a Geant4 build compatible with allpix:
Changed:
<
<
cmake -DCMAKE_INSTALL_PREFIX=/home/idarraga/hep/geant4.9.5-install -DGEANT4_USE_GDML=ON -DCMAKE_BUILD_TYPE=Debug -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_OPENGL_X11=ON -DGEANT4_USE_XM=ON -DGEANT4_USE_INVENTOR=ON -DINVENTOR_INCLUDE_DIR=/usr/local/include/Inventor -DINVENTOR_LIBRARY_RELEASE=/usr/local/lib/libCoin.so -DINVENTOR_SOXT_LIBRARY=/usr/local/lib/libSoXt.so -DGEANT4_USE_QT=ON /home/idarraga/hep/geant4.9.5
>
>
cmake -DCMAKE_INSTALL_PREFIX=/home/idarraga/hep/geant4.9.5.p02-install -DGEANT4_USE_GDML=ON -DCMAKE_BUILD_TYPE=Debug -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_OPENGL_X11=ON -DGEANT4_USE_XM=ON -DGEANT4_USE_INVENTOR=ON -DGEANT4_USE_QT=ON /home/idarraga/hep/geant4.9.5.p02
 

Remove Open Inventor and OpenGL flags is you compile without these options.

Revision 232014-04-23 - SamirArfaoui

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 499 to 499
 For example, if you have simulated run number 999 with the telescope as well as your favourite three DUTs with sensor ID 410, 412, and 543, the commands will look like this:
Changed:
<
<
tar -czvf run000999.tar.gz ./run000999
>
>
tar -czvf run000999.tar.gz ./run000999/*
 python TelescopeConverter.py run000999.tar.gz run000999.slcio 410 412 543

Revision 222014-03-13 - NiloufarAlipourTehrani

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 308 to 305
 In the share folder, the script "WriteMacro.py" generates a macro by reading alignment values found by the test beam data and also the gear files used for the test beam analysis. This script uses the file "GeneralMacro.in" which contains a general structure for the macro file and sets the values for the position of the telescope planes. Use the following commands to run the script:
cd share 
source setup_pyLCIO.sh
Changed:
<
<
python WriteMacro.py MacroName OutFolder preAlign Align GearFile Energy FrameNb
>
>
python WriteMacro.py MacroName OutFolder preAlign Align DUTAlign GearFile Energy FrameNb
 
Changed:
<
<
where MacroName is the name given to the ouput macro, OutFolder is the folder where the AllPix outputs are saved, preAling and Align are the .slcio files obtained once the telescope is aligned (using EUTelescope analysis framework), GearFile is the xml file which contains the information about the position of the telescope planes and the DUT, Energy is the beam energy and FrameNb corresponds to the number of events.
>
>
where MacroName is the name given to the ouput macro, OutFolder is the folder where the AllPix outputs are saved, preAling and Align are the .slcio files obtained once the telescope is aligned (using EUTelescope analysis framework) and DUTAlign is the file containing the alignment for the DUT (the file should be in the form of: alpha beta gamma x y), GearFile is the xml file which contains the information about the position of the telescope planes and the DUT, Energy is the beam energy and FrameNb corresponds to the number of events.
 

Geometry Description

Revision 212014-03-12 - SamirArfaoui

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 434 to 434
 

Telescope Output Controls

Added:
>
>
To generate ASCII files that can be used in the EUTELESCOPE framework, use the following set of controls:
 
####################################################################
# Write Telescope files
Line: 443 to 445
 /allpix/timepixtelescope/write 1
Added:
>
>
This will create on ASCII file per frame in the specified folder, which contains all the digitised hits for each simulated sensor planes.
 

Beam Definition and Simulation scenario Controls

Line: 479 to 483
 

Analysis in the EUTELESCOPE Framework

Added:
>
>
In order to input your simulated data in EUTELESCOPE, you will need to convert the generated ASCII files into the LCIO format.

For this, use the TelescopeConverter.py python script located in the "share" folder.

The python script takes a tarball as input, so first run the following command to tar all your ASCII files:

tar -czvf <tarball-filename>.tar.gz <path-to-the-folder-containing-the-mpx-ascii-files>

You can now perform the conversion to the LCIO format:

python TelescopeConverter.py <input-tarball> <output-file-name>.slcio <list-of-DUT-sensorID>

For example, if you have simulated run number 999 with the telescope as well as your favourite three DUTs with sensor ID 410, 412, and 543, the commands will look like this:

tar -czvf run000999.tar.gz ./run000999
python TelescopeConverter.py run000999.tar.gz run000999.slcio 410 412 543

You now have a .slcio file, which has the exact same format as the one created in EUTELESCOPE by the converter when you have testbeam data.

You can inspect the contents by running the following command:

dumpevent run000999.slcio <event-number>
 -- MathieuB - 12 Feb 2014

META FILEATTACHMENT attachment="G4OpenGL_030.jpg" attr="" comment="allpix simulation of Timepix stack" date="1350688483" name="G4OpenGL_030.jpg" path="G4OpenGL_030.jpg" size="96855" user="idarraga" version="1"

Revision 202014-03-10 - NiloufarAlipourTehrani

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 15 to 15
 

Getting Started with AllPix: Installation

Latest Version

Added:
>
>
 To install the latest version of AllPix:
Changed:
<
<
  1. SSH to lxplus (not lxplus5)
  2. In the location you wish to install, do:
    svn co http://svn.cern.ch/guest/allpix
  3. Next make a g4 directory with:
    mkdir <somewhere>/g4workdir
  4. Edit
    setup_allpix.sh
    with the location of the g4workdir defined in step 3.
  5. In the allpix directory:
    source setup_allpix.sh
  6. gmake clean
  7. gmake -j8
>
>
  1. SSH to lxplus ( not lxplus5)
  2. In the location you wish to install, do:
    svn co http://svn.cern.ch/guest/allpix
  3. Next make a g4 directory with:
    mkdir <somewhere>/g4workdir
  4. Edit
    setup_allpix.sh
    with the location of the g4workdir defined in step 3.
  5. In the allpix directory:
    source setup_allpix.sh
  6. gmake clean
  7. gmake -j8
 (might have to repeat gmake steps for some reason)
Deleted:
<
<
 

Previous Releases

Added:
>
>
 Previous iterations of AllPix required more circuitous installation steps, outlined below. These are included as reference.

Line: 202 to 201
 
 <!-- Timepix -->
Changed:
<
<
# Unique identification number for the described device in the simulation, a unique id is needed for each instantiated devices
>
>
# Unique identification number for the described device in the simulation, a unique id is needed for each instantiated devices
 Timepix # Digitizer ID, digitizer to be used for this device

# Pixel matrix dimensions, pixel sizes are given in Half-Length ex: 55um pixel pitch -> pixsize_x = 27.5,

Line: 210 to 209
 256</npix x>\n 256</npix y>\n 0</npix z>\n
Changed:
<
<
27.5.</pixsize x> 27.5.</pixsize y> 150.</pixsize z>
>
>
27.5.</pixsize x> 27.5.</pixsize y> 150.</pixsize z>
 

# Sensor dimension, should be coherent with matrix dimensions, gr_excess define the size of the Guard Rings (Inactive Volumes) # around the active Matrix, sensor_pos describe the position of the sensor with regard to the PCB volume center (X,Y)

Changed:
<
<
7040</sensor hx> 7040</sensor hy> 150.0</sensor hz>

100.0</sensor gr excess htop> 100.0</sensor gr excess hbottom> 100.0</sensor gr excess hright> 100.0</sensor gr excess hleft>

0</sensor posx> 14080</sensor posy> 0.</sensor posz>

>
>
7040</sensor hx> 7040</sensor hy> 150.0</sensor hz>

100.0</sensor gr excess htop> 100.0</sensor gr excess hbottom> 100.0</sensor gr excess hright> 100.0</sensor gr excess hleft>

0</sensor posx> 14080</sensor posy> 0.</sensor posz>

 

# chip Geometry : Define the size of the Chip side of a Pixel detector # chip_offset describe the offset between the chip and sensor volume sensors, for example, if bonding pads are present

Changed:
<
<
7040</chip hx> 7040</chip hy> 75.0</chip hz>
>
>
7040</chip hx> 7040</chip hy> 75.0</chip hz>
 0. -1020. 0.
Line: 251 to 250
 

# PCB Geometry : Size and thickness of the PCB, Default material is G10

Changed:
<
<
17600.0</pcb hx> 28160</pcb hy> 0.80</pcb hz>
>
>
17600.0</pcb hx> 28160</pcb hy> 0.80</pcb hz>
 

# Digitizer specific parameters, these are set to 0 if not defined

Line: 261 to 260
  200 </MIP Tot> 24000.</MIP Charge> 11810 </Counter Depth>
Changed:
<
<
10e−9 </Clock Unit>
>
>
10e−9 </Clock Unit>
 120.</Chip Noise> 1520.</Chip Threshold> 0.0001</Cross Talk>
Line: 273 to 272
 The Printed Circuit Board (PCB) and the Chip+bumps can be deactivated from the model by setting respectively the pcb thickness (pcb_hz) and Chip thickness(chip_hz) to 0.The Following image show a pixel geometry as generated with this description/macro description/macro: :

  • Example for a 2x2 pixel detector in Allpix with bumps, pcb and chip
Changed:
<
<
pixelExample.png pixelExample_bumps.png
>
>
pixelExample.png pixelExample_bumps.png
 

Appliances and Test Structures

Line: 282 to 280
 In addition to the pixel detectors and associated volumes, AllPix provide methods to place other passive structures in the Simulation volume (ie, support structure, source casing etc...). The additional volume can be of two categories :
  • Test Structures : Test Structure are fixed volume in the simulation volume, they move independently of the Pixel Detectors (ex : Shielding, source casing, support structures)
  • Appliances : Appliances are bound to a Pixel Detector instance ie: Rotation and Translation of the Pixel Detector will also be propagated to the appliance (ex: Detector shielding, cabling, scintillators etc ..)
Deleted:
<
<
 Test Structure Geometry should be defined in the source code. The file named src/AllPixDetectorConstructionTestStructure.cc contains a function ,void AllPixDetectorConstruction::BuildTestStructure(int). This function is called when test structure is placed in the simulation macro. A case switch is implemented version, and each case represent a new test structure. When placing a test structure in the simulation macro, you can specify the id of the test structure you want to place. This id correspond to the values of the case switch.
Changed:
<
<
  • Timepix Detector with Lead brick (gray) and Am241 source holder( Cylinder) (test Structure) and Chip Board protector attached to Timepix PCB (Red, Appliance) Example_TestStruct_Appliance.png
>
>
  • Timepix Detector with Lead brick (gray) and Am241 source holder( Cylinder) (test Structure) and Chip Board protector attached to Timepix PCB (Red, Appliance) Example_TestStruct_Appliance.png
  Appliances are defined in the file named src/AllPixDetectorConstructionAppliances.cc. The code implementation is the same as for a test structure, however, the translation of the detector associated to the appliance and the pointer to the Wrapper volume associated to the appliance's pixel detector are provided in the code, to be applied to the volume placed in the appliance. By attaching the appliance to the mother volume and placing it at the same positioning coordinates, you obtain a structure that will be "attached" to the simulated pixel detector.
Deleted:
<
<

  Important When adding Appliances to your detector, make sure they are fully contained by the pixel detector mother volume (wrapper). By default, the wrapper is set to contain the PCB,Chip and Sensor. To extend the size of the wrapper box to contain your test structure, use the allpix command /allpix/extras/setWrapperEnhancement x y z. For the moment, wrapper can only be extended symmetrically along the x,y,z axis.
Line: 308 to 301
 
Deleted:
<
<
 Any of GEANT4 standard macro command can be used when defining an AllPix simulation macro. A detailed description of the commands can be found in GEANT4 documentation. Here is a brief overview of the commands commonly used in AllPix simulation macros.
Changed:
<
<
In the share folder, the script "WriteMacro.py" generates a macro by reading alignment values found by the test beam data and also the gear files used for the test beam analysis. This script uses the file "GeneralMacro.in" which contains a general structure for the macro file and sets the values for the position of the telescope planes. Use the following commands to run the script:
 
source share/setup_pyLCIO.sh
>
>
Generate a macro from the alignment files of the test beams

In the share folder, the script "WriteMacro.py" generates a macro by reading alignment values found by the test beam data and also the gear files used for the test beam analysis. This script uses the file "GeneralMacro.in" which contains a general structure for the macro file and sets the values for the position of the telescope planes. Use the following commands to run the script:

cd share 
source setup_pyLCIO.sh
 python WriteMacro.py MacroName OutFolder preAlign Align GearFile Energy FrameNb
Added:
>
>
where MacroName is the name given to the ouput macro, OutFolder is the folder where the AllPix outputs are saved, preAling and Align are the .slcio files obtained once the telescope is aligned (using EUTelescope analysis framework), GearFile is the xml file which contains the information about the position of the telescope planes and the DUT, Energy is the beam energy and FrameNb corresponds to the number of events.
 

Geometry Description

Revision 192014-03-10 - MathieuB

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 390 to 390
 

Verbosity Controls

Changed:
<
<
>
>
The verbose of the different aspect of the simulation can be modified with the following statements :
 
/run/verbose 0
/control/verbose 0
Line: 400 to 399
 /allpix/phys/verbose 0
Changed:
<
<
>
>
Verbosity level 0 is the most silent, and increasing this value will add more verbosity to the allpix output.
 

Vizualisation Controls

Added:
>
>
The following describe a typical statement for activating visualization in allpix. Uncomment one of the /vis/open statement to activate visualization. For more info on these commands, please refer to the GEANT4 documentation.
 
####################################################################
# Visualization

Revision 182014-03-10 - NiloufarAlipourTehrani

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 312 to 312
  Any of GEANT4 standard macro command can be used when defining an AllPix simulation macro. A detailed description of the commands can be found in GEANT4 documentation. Here is a brief overview of the commands commonly used in AllPix simulation macros.
Added:
>
>
In the share folder, the script "WriteMacro.py" generates a macro by reading alignment values found by the test beam data and also the gear files used for the test beam analysis. This script uses the file "GeneralMacro.in" which contains a general structure for the macro file and sets the values for the position of the telescope planes. Use the following commands to run the script:
 
source share/setup_pyLCIO.sh
python WriteMacro.py MacroName OutFolder preAlign Align GearFile Energy FrameNb
 

Geometry Description

Sensor positioning

Revision 172014-03-10 - MathieuB

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

Line: 297 to 297
 

Writing a Macro to drive your simulation

Changed:
<
<

General GEANT4 macro commands

>
>
The typical structure of an AllPix simulation script is as follow :

Any of GEANT4 standard macro command can be used when defining an AllPix simulation macro. A detailed description of the commands can be found in GEANT4 documentation. Here is a brief overview of the commands commonly used in AllPix simulation macros.

Geometry Description

Sensor positioning

The sensor that were described in last section can be placed in the simulation geometry using the following command :

 
/allpix/det/setId        300
/allpix/det/setPosition  -0.0 -0.0 0.0 mm
/allpix/det/setRotation  -0.0 180.0 180.0 deg

/allpix/det/setId refer to the id number associated to each detector described in the pixeldetector.xml file. /allpix/det/setPosition and /allpix/det/setRotation describe respectively the rotation and position of the sensitive detector in the global geometry of the simulation.

Test structures and appliances

Test structures can be placed in the global geometry with the following self explanatory commands :

/allpix/extras/setTestStructureType 8
/allpix/extras/setTestStructurePosition -0.492158130371 -0.17583204793 305.0 mm
/allpix/extras/setTestStructureRotation -0.0 -0.0 0.0032635 deg
/allpix/extras/setTestStructureDetLink 302

/allpix/extras/setTestStructureDetLink 302 is used to make sure that the volume occupied by the sensor 302 do not overlap with the test structure. The volume of detector with ID 302 is substracted from the test structure volume

To place an appliance (in the local coordinate of the sensors they associate), use the following commands :

/allpix/extras/setApplianceType 1
/allpix/extras/setAppliancePosition  0. 0. 0. mm
/allpix/extras/setWrapperEnhancement  0.0  0.0 50 mm

setApplianceType is used to select which appliance to use. SetWrapperEnhancement extend the wrapper volume around the detector to insure that it fully contains the appliance. The order the appliances are declared in the simulation macro will define the sensor to which they are associated, following the sensor declaration order.

Scintillator placement

If your simulation make use of the EUDET Telescope (with EUTELESCOPE environnement variable defined at compilation time), you will need to position the scintillator tiles used to trigger the telescope. If all scintillator tiles define detect the passage of a particle, the telescope data are recorded. You can place the scintillator with the following command :

/allpix/eudet/scint1Pos 0.0  0.0  -24.0 mm # offset of 18mm +/- 6mm with of scinti
/allpix/eudet/scint2Pos 0.0  0.0  -18.0 mm
/allpix/eudet/scint3Pos 0.0  0.0 690.8 mm
/allpix/eudet/scint4Pos 0.0  0.0 696.8 mm

Scintillator default dimensions are 22x10.8x6mm.

 

AllPix specific Macro commands

Added:
>
>
You can select your favorite physics list from the simulation macro using the following commands:
/allpix/phys/Physics LIVERMORE_FTFP_BERT

The available physics list are : emstandard_opt0, emstandard_opt1,emstandard_opt2,emstandard_opt3,FTFP_BERT_EMV, FTFP_BERT_EMY, FTFP_BERT_EMX,FTFP_BERT, FTF_BIC, LHEP,QBBC, QGSC_BERT, QGSP, QGSP_BERT, QGSP_FTFP_BERT, QGSP_BERT_EMV, QGSP_BERT_EMX, QGSP_BERT_HP, QGSP_BIC, QGSP_BIC_EMY, QGS_BIC, QGSP_BIC_HP, LIVERMORE_FTFP_BERT.

Initialization

/run/initialize
/allpix/det/update

This command is called to initialize the geometry and the physics models to be used during your simulation. All sensor, test structures and appliances must be defined before calling that statement. Physics list to be used and physics cuts to be applied must be defined before initializing the simulation framework with this command.

Verbosity Controls

/run/verbose 0
/control/verbose 0
/control/saveHistory
/tracking/verbose 0
/allpix/phys/verbose 0

Vizualisation Controls

####################################################################
# Visualization
/vis/scene/create
#/vis/scene/add/axes 0. 0. 0. 10. cm
/vis/scene/add/volume World -1 2
/vis/viewer/set/style s
#/vis/open OIX 1024x768-100+100
#/vis/open OGLIXm 1024x768-100+100
#/vis/open RayTracer
#/vis/open OGLIQt
#/vis/open OGLSQt
#/vis/open OIX
#/vis/open OGLIX 1024x768-100+100
#/vis/open OGLSXm
#/vis/open DAWNFILE
#/vis/open OGLSX
#/vis/open OGL 600x600-0+0
/vis/viewer/set/background 0.4 0.5 0.6
/vis/viewer/set/viewpointThetaPhi 20 50
/vis/viewer/zoom 2.0
/vis/viewer/flush

####################################################################
# Draw trajectories at end of event, showing trajectory points as
# markers of size 2 pixels
#/vis/scene/add/trajectories
#/vis/modeling/trajectories/create/drawByCharge
#/vis/modeling/trajectories/drawByCharge-0/default/setDrawStepPts false
#/vis/modeling/trajectories/drawByCharge-0/default/setStepPtsSize 2
#/vis/scene/endOfEventAction accumulate

Telescope Output Controls

####################################################################
# Write Telescope files
/allpix/timepixtelescope/setFolderPath /VertexScratch/workspace/mbenoit/test/Run000008
/allpix/timepixtelescope/setEventIDcolumn 0
/allpix/timepixtelescope/setSumTOT 1
/allpix/timepixtelescope/write 1

Beam Definition and Simulation scenario Controls

#########################
# gammas
#/gps/source/intensity 75.17
/gps/particle gamma
/gps/pos/type Plane
/gps/pos/shape Circle
/gps/pos/centre 0 0 22 mm
/gps/pos/radius 2.5 mm
/gps/direction  0 0 -1
/gps/ene/type User
/gps/hist/type energy
# spectra   
#/gps/hist/point  0.0139  37     
#/gps/hist/point  0.026345  2.27     
/gps/hist/point  0.059541  59.541     
/gps/ang/type iso
/gps/mintheta 0
/gps/maxtheta 1.8

####################################################################
# Shoot
/allpix/beam/frames 1
/allpix/beam/type const 50
/allpix/beam/on
 

Analysis of your Simulation results

Added:
>
>
 

Analysis in the Mafalda Framework

Added:
>
>
 

Analysis in the EUTELESCOPE Framework

Revision 162014-02-19 - CallieBertsche

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"
Changed:
<
<

The AllPix Simulation Framework

  • allpix simulation of Timepix stack:
    G4OpenGL_030.jpg
>
>

The AllPix Simulation Framework

 
Changed:
<
<
>
>
 
Added:
>
>
AllPix is a powerful tool for various simulation goals. The following pages provide instruction and description of using AllPix as it has developed so far;
 
Changed:
<
<

AllPix installation

>
>
please do not hesitate to provide feedback.

G4OpenGL_030.jpg

AllPix simulation of a Timepix stack

Getting Started with AllPix: Installation

Latest Version

To install the latest version of AllPix:
  1. SSH to lxplus (not lxplus5)
  2. In the location you wish to install, do:
    svn co http://svn.cern.ch/guest/allpix
  3. Next make a g4 directory with:
    mkdir <somewhere>/g4workdir
  4. Edit
    setup_allpix.sh
    with the location of the g4workdir defined in step 3.
  5. In the allpix directory:
    source setup_allpix.sh
  6. gmake clean
  7. gmake -j8
(might have to repeat gmake steps for some reason)

Previous Releases

Previous iterations of AllPix required more circuitous installation steps, outlined below. These are included as reference.
 
Line: 16 to 34
 
Deleted:
<
<
 
Changed:
<
<

Dependencies

>
>

Dependencies

 

The tricky dependency is OpenInventor (Optional). There is a number of ways in which you can install OpenInventor in your system. One (the most portable) is through the Coin3D project.

Line: 55 to 72
 

Changed:
<
<

Download compile and run allpix with standalone geant4 installation

>
>

Download compile and run allpix with standalone geant4 installation

  Allpix code is available in the svn at CERN :
Line: 88 to 105
 

Changed:
<
<

Installation on lxplus

>
>

Installation on lxplus

  A Standard GEANT4 (4.9.6.2) installation with SoXt and Coin3D support has been compiled and made available to lxplus (SLC6) users. To use this configuration , first check out the latest release of the AllPix Framework (currently 1.0)
Line: 111 to 128
 

Changed:
<
<

Known issues:

>
>

Known issues:

  [reported by I.Rubinskiy 21-03-2013]

Revision 152014-02-17 - MathieuB

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

  • allpix simulation of Timepix stack:
    G4OpenGL_030.jpg
Line: 255 to 255
  The Printed Circuit Board (PCB) and the Chip+bumps can be deactivated from the model by setting respectively the pcb thickness (pcb_hz) and Chip thickness(chip_hz) to 0.The Following image show a pixel geometry as generated with this description/macro description/macro: :
Added:
>
>
  • Example for a 2x2 pixel detector in Allpix with bumps, pcb and chip
 pixelExample.png pixelExample_bumps.png
Changed:
<
<
>
>
 

Appliances and Test Structures

Added:
>
>
In addition to the pixel detectors and associated volumes, AllPix provide methods to place other passive structures in the Simulation volume (ie, support structure, source casing etc...). The additional volume can be of two categories :
  • Test Structures : Test Structure are fixed volume in the simulation volume, they move independently of the Pixel Detectors (ex : Shielding, source casing, support structures)
  • Appliances : Appliances are bound to a Pixel Detector instance ie: Rotation and Translation of the Pixel Detector will also be propagated to the appliance (ex: Detector shielding, cabling, scintillators etc ..)

Test Structure Geometry should be defined in the source code. The file named src/AllPixDetectorConstructionTestStructure.cc contains a function ,void AllPixDetectorConstruction::BuildTestStructure(int). This function is called when test structure is placed in the simulation macro. A case switch is implemented version, and each case represent a new test structure. When placing a test structure in the simulation macro, you can specify the id of the test structure you want to place. This id correspond to the values of the case switch.

  • Timepix Detector with Lead brick (gray) and Am241 source holder( Cylinder) (test Structure) and Chip Board protector attached to Timepix PCB (Red, Appliance) Example_TestStruct_Appliance.png

Appliances are defined in the file named src/AllPixDetectorConstructionAppliances.cc. The code implementation is the same as for a test structure, however, the translation of the detector associated to the appliance and the pointer to the Wrapper volume associated to the appliance's pixel detector are provided in the code, to be applied to the volume placed in the appliance. By attaching the appliance to the mother volume and placing it at the same positioning coordinates, you obtain a structure that will be "attached" to the simulated pixel detector.

Important When adding Appliances to your detector, make sure they are fully contained by the pixel detector mother volume (wrapper). By default, the wrapper is set to contain the PCB,Chip and Sensor. To extend the size of the wrapper box to contain your test structure, use the allpix command /allpix/extras/setWrapperEnhancement x y z. For the moment, wrapper can only be extended symmetrically along the x,y,z axis.

 

Writing a Macro to drive your simulation

Line: 280 to 296
 
META FILEATTACHMENT attachment="pixelExample.png" attr="" comment="Pixel Geometry example, 2x2 pixels with Chip and Bump shift" date="1392630134" name="pixelExample.png" path="pixelExample.png" size="21251" user="mbenoit" version="1"
META FILEATTACHMENT attachment="pixelExample_bumps.png" attr="" comment="Pixel Geometry example, 2x2 pixels with Chip and Bump shift, zoom on bumps" date="1392630168" name="pixelExample_bumps.png" path="pixelExample_bumps.png" size="22769" user="mbenoit" version="1"
META FILEATTACHMENT attachment="Vis_example.txt" attr="" comment="" date="1392631049" name="Vis_example.txt" path="Vis_example.txt" size="3647" user="mbenoit" version="1"
Added:
>
>
META FILEATTACHMENT attachment="Example_TestStruct_Appliance.png" attr="" comment="" date="1392640628" name="Example_TestStruct_Appliance.png" path="Example_TestStruct_Appliance.png" size="45545" user="mbenoit" version="1"

Revision 142014-02-17 - MathieuB

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

  • allpix simulation of Timepix stack:
    G4OpenGL_030.jpg
Line: 175 to 175
 

Working with the AllPix Framework

Added:
>
>
AllPix is a Geant4-based simulation dedicated to solid state detector technology featuring pixel and strip detectors is presented. The program allows the user to create a particular experimental setup with an arbitrary number of detectors in any desired configuration. Additional complex structures can be easily included thanks to Geant4 services. Different digitization strategies are available. The program also serves as a Digitizer development work-bench.
 

Pixel detector geometry description

Added:
>
>
From the user stand point the simulation is driven from a regular Geant4 macro using standard GEANT4 macro commands where additional custom AllPix commands are available. The user may place as many detectors with as many geometries as needed. If the detectors overlap in space, AllPix will launch a warning at run time.

The first step to create an AllPix simulation is to add a entry in the AllPix Pixel Detector database for the detector geometry you need to simulate. The Pixel Detector database is located in the models folder and is a standard xml file named pixeldetector.xml. Each entries in the Pixel Detector database should be structured as follow :

 <!-- Timepix -->

<pixeldet id=800,801>  # Unique identification number for the described device in the simulation, a unique id is needed for each instantiated devices
<digitizer>Timepix</digitizer> # Digitizer ID, digitizer to be used for this device

# Pixel matrix dimensions, pixel sizes are given in Half-Length ex: 55um pixel pitch -> pixsize_x = 27.5, 
# pixsize_z should be set at the same half-thickness ass the sensor
<npix x>256</npix x>\n
<npix y>256</npix y>\n
<npix z>0</npix z>\n
<pixsize x units=um>27.5.</pixsize x>
<pixsize y units=um>27.5.</pixsize y>
<pixsize z units=um>150.</pixsize z>


# Sensor dimension, should be coherent with matrix dimensions, gr_excess define the size of the Guard Rings (Inactive Volumes) 
# around the active Matrix, sensor_pos describe the position of the sensor with regard to the PCB volume center (X,Y)
<sensor hx units=um>7040</sensor hx>
<sensor hy units=um>7040</sensor hy>
<sensor hz units=um>150.0</sensor hz>

<sensor gr excess htop units=um>100.0</sensor gr excess htop>
<sensor gr excess hbottom units=um>100.0</sensor gr excess hbottom>
<sensor gr excess hright units=um>100.0</sensor gr excess hright>
<sensor gr excess hleft units=um>100.0</sensor gr excess hleft>

<sensor posx units=mm>0</sensor posx>
<sensor posy units=um>14080</sensor posy>
<sensor posz units=mm>0.</sensor posz>


# chip Geometry : Define the size of the Chip side of a Pixel detector 
# chip_offset describe the offset between the chip and sensor volume sensors, for example, if bonding pads are present 
<chip hx units=um>7040</chip hx>
<chip hy units=um>7040</chip hy>
<chip hz units=um>75.0</chip hz>
<chip_offsetx units="um">0.</chip_offsetx>
<chip_offsety units="um">-1020.</chip_offsety>
<chip_offsetz units="um">0.</chip_offsetz>


# Bump-Bonding geometry : Bump bonds are modeled as the union of a 
# Cylinder(height ->bump_height, radius ->(bump_radius - bump_dr) ) and a Sphere(r->bump_radius). Offset is relative to the center of the pixel
<bump_radius units="um">9.0</bump_radius>
<bump_height units="um">20.0</bump_height>
<bump_offset_x units="um">0.0</bump_offset_x>
<bump_offset_y units="um">0.0</bump_offset_y>
<bump_dr units="um">2.0</bump_dr>


# PCB Geometry : Size and thickness of the PCB, Default material is G10
<pcb hx units=um comment=2.5&#8727; sensor hx>17600.0</pcb hx>
<pcb hy units=um comment=4&#8727;sensor hy>28160</pcb hy>
<pcb hz units=mm>0.80</pcb hz>


# Digitizer specific parameters, these are set to 0 if not defined
<sensor resistivity>10000.0</sensor resistivity>
<MIP Tot> 200 </MIP Tot>
<MIP Charge>24000.</MIP Charge>
<Counter Depth> 11810 </Counter Depth>
<Clock Unit> 10e&#8722;9 </Clock Unit>
<Chip Noise>120.</Chip Noise>
<Chip Threshold>1520.</Chip Threshold>
<Cross Talk>0.0001</Cross Talk>
<Saturation Energy>350.</Saturation Energy>
</pixeldet>

The Printed Circuit Board (PCB) and the Chip+bumps can be deactivated from the model by setting respectively the pcb thickness (pcb_hz) and Chip thickness(chip_hz) to 0.The Following image show a pixel geometry as generated with this description/macro description/macro: :

pixelExample.png pixelExample_bumps.png

 

Appliances and Test Structures

Added:
>
>
 

Writing a Macro to drive your simulation

Added:
>
>
 

General GEANT4 macro commands

Added:
>
>
 

AllPix specific Macro commands

Analysis of your Simulation results

Line: 191 to 275
  -- MathieuB - 12 Feb 2014
Added:
>
>
 
META FILEATTACHMENT attachment="G4OpenGL_030.jpg" attr="" comment="allpix simulation of Timepix stack" date="1350688483" name="G4OpenGL_030.jpg" path="G4OpenGL_030.jpg" size="96855" user="idarraga" version="1"
Added:
>
>
META FILEATTACHMENT attachment="pixelExample.png" attr="" comment="Pixel Geometry example, 2x2 pixels with Chip and Bump shift" date="1392630134" name="pixelExample.png" path="pixelExample.png" size="21251" user="mbenoit" version="1"
META FILEATTACHMENT attachment="pixelExample_bumps.png" attr="" comment="Pixel Geometry example, 2x2 pixels with Chip and Bump shift, zoom on bumps" date="1392630168" name="pixelExample_bumps.png" path="pixelExample_bumps.png" size="22769" user="mbenoit" version="1"
META FILEATTACHMENT attachment="Vis_example.txt" attr="" comment="" date="1392631049" name="Vis_example.txt" path="Vis_example.txt" size="3647" user="mbenoit" version="1"

Revision 132014-02-12 - MathieuB

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

The AllPix Simulation Framework

  • allpix simulation of Timepix stack:
    G4OpenGL_030.jpg
Line: 10 to 10
 

AllPix installation

Added:
>
>

 

Dependencies

Changed:
<
<
The tricky dependency is OpenInventor. There is a number of ways in which you can install OpenInventor in your system. One (the most portable) is through the Coin3D project.
>
>
The tricky dependency is OpenInventor (Optional). There is a number of ways in which you can install OpenInventor in your system. One (the most portable) is through the Coin3D project.
  Download and compile Coin and SoXt. ATTENTION soxt-config and coin-config programs should be in your path after installation. Basically libCoin replaces libInventor and libSoXt replaces libInventorXt. Later on, at running time, you have to produce the proper symbolic links in your system
Line: 22 to 30
 
libInventorXt.so -->
libSoXt.so
Changed:
<
<
Compile geant4 (later than 4.9.5, earlier than 4.10) compatible with allpix (including OpenInventor visualization) Geant4 home page. WARNING make sure you have cmake >= 2.8.x. Make sure to add Coin/bin and SoXt/bin folders to your path. Cmake will look for the executables 'coin-config' and 'soxt-config' to setup the openInventor driver. Here's the cmake line that will prepare a Geant4 build compatible with allpix:
>
>
The command to create that symbolic link (sudo might be needed depending where you install is located) is :

ln -s SOURCE TARGET

Compile geant4 (later than 4.9.5, earlier than 4.10) compatible with allpix (xerces-c, openGL (optional), OpenInventor (optional)) Geant4 home page. WARNING make sure you have cmake >= 2.8.x. Make sure to add Coin/bin and SoXt/bin folders to your path, if compiling with Open Inventor. Cmake will look for the executables 'coin-config' and 'soxt-config' to setup the openInventor driver. Here's the cmake line that will prepare a Geant4 build compatible with allpix:

 
cmake -DCMAKE_INSTALL_PREFIX=/home/idarraga/hep/geant4.9.5-install -DGEANT4_USE_GDML=ON -DCMAKE_BUILD_TYPE=Debug -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_OPENGL_X11=ON -DGEANT4_USE_XM=ON -DGEANT4_USE_INVENTOR=ON -DINVENTOR_INCLUDE_DIR=/usr/local/include/Inventor -DINVENTOR_LIBRARY_RELEASE=/usr/local/lib/libCoin.so -DINVENTOR_SOXT_LIBRARY=/usr/local/lib/libSoXt.so -DGEANT4_USE_QT=ON /home/idarraga/hep/geant4.9.5
Added:
>
>
Remove Open Inventor and OpenGL flags is you compile without these options.
 if everything goes smooth with cmake, now compile geant4 (you probably want to use many cores with -jN flag, where N is the number of cores)

make
Changed:
<
<
If you are compiling Makefile based projects, which is the case with allpix, you need to source this first
>
>
If you are compiling Makefile based projects, which is the case with allpix, you need to source this first (replace version with your current geant4 version)
 
source YOURPATH/geant4.9.5-install/share/Geant4-9.5.0/geant4make/geant4make.sh
Changed:
<
<

Download compile and run allpix

>
>

Download compile and run allpix with standalone geant4 installation

 
Changed:
<
<
Allpix code is available in the svn at CERN
>
>
Allpix code is available in the svn at CERN :
 
svn co http://svn.cern.ch/guest/allpix/tags/AllPix_v1.0
Changed:
<
<
before compiling don't forget to source your Geant4 setup
>
>
before compiling don't forget to source your Geant4 setup :
 
source YOURPATH/geant4.9.5-install/share/Geant4-9.5.0/geant4make/geant4make.sh
Changed:
<
<
Now compile
>
>
Now compile :
 
make
Changed:
<
<
If you are running the EUDET Telescope you need to setup the following env variable before "make"
>
>
If you are running the EUDET Telescope you need to setup the following env variable before "make" :
 
export EUTELESCOPE=1
Changed:
<
<
Run with vis
>
>
Run with visualization (Open Inventor) :
 
allpix macros/oneDetector_Inventor_vis.in
Added:
>
>
 

Installation on lxplus

A Standard GEANT4 (4.9.6.2) installation with SoXt and Coin3D support has been compiled and made available to lxplus (SLC6) users. To use this configuration , first check out the latest release of the AllPix Framework (currently 1.0)

Line: 92 to 110
 make
Added:
>
>
 

Known issues:

[reported by I.Rubinskiy 21-03-2013]

Revision 122014-02-12 - MathieuB

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"
Changed:
<
<
  • allpix simulation of Timepix stack:
    G4OpenGL_030.jpg
>
>

The AllPix Simulation Framework

  • allpix simulation of Timepix stack:
    G4OpenGL_030.jpg

AllPix installation

Dependencies

 
Deleted:
<
<

Dependencies

  The tricky dependency is OpenInventor. There is a number of ways in which you can install OpenInventor in your system. One (the most portable) is through the Coin3D project.

Download and compile Coin and SoXt. ATTENTION soxt-config and coin-config programs should be in your path after installation. Basically libCoin replaces libInventor and libSoXt replaces libInventorXt. Later on, at running time, you have to produce the proper symbolic links in your system

Changed:
<
<
>
>
 
libInventor.so -->
llibCoin.so libInventorXt.so --> libSoXt.so
Changed:
<
<
Compile >=geant4.9.5 compatible with allpix (including OpenInventor visualization) Geant4 home page. WARNING make sure you have cmake >= 2.8.x. Make sure to add Coin/bin and SoXt/bin folders to your path. Cmake will look for the executables 'coin-config' and 'soxt-config' to setup the openInventor driver. Here's the cmake line that will prepare a Geant4 build compatible with allpix:
>
>
Compile geant4 (later than 4.9.5, earlier than 4.10) compatible with allpix (including OpenInventor visualization) Geant4 home page. WARNING make sure you have cmake >= 2.8.x. Make sure to add Coin/bin and SoXt/bin folders to your path. Cmake will look for the executables 'coin-config' and 'soxt-config' to setup the openInventor driver. Here's the cmake line that will prepare a Geant4 build compatible with allpix:
 
Changed:
<
<
>
>
 cmake -DCMAKE_INSTALL_PREFIX=/home/idarraga/hep/geant4.9.5-install -DGEANT4_USE_GDML=ON -DCMAKE_BUILD_TYPE=Debug -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_OPENGL_X11=ON -DGEANT4_USE_XM=ON -DGEANT4_USE_INVENTOR=ON -DINVENTOR_INCLUDE_DIR=/usr/local/include/Inventor -DINVENTOR_LIBRARY_RELEASE=/usr/local/lib/libCoin.so -DINVENTOR_SOXT_LIBRARY=/usr/local/lib/libSoXt.so -DGEANT4_USE_QT=ON /home/idarraga/hep/geant4.9.5

if everything goes smooth with cmake, now compile geant4 (you probably want to use many cores with -jN flag, where N is the number of cores)

Changed:
<
<
make
>
>
make
  If you are compiling Makefile based projects, which is the case with allpix, you need to source this first
Changed:
<
<
>
>
 source YOURPATH/geant4.9.5-install/share/Geant4-9.5.0/geant4make/geant4make.sh
Changed:
<
<

Download compile and run allpix

>
>

Download compile and run allpix

  Allpix code is available in the svn at CERN
Changed:
<
<
svn co http://svn.cern.ch/guest/allpix
>
>
svn co http://svn.cern.ch/guest/allpix/tags/AllPix_v1.0
 

before compiling don't forget to source your Geant4 setup

Line: 62 to 70
 allpix macros/oneDetector_Inventor_vis.in
Changed:
<
<

Allpix Digitizers

>
>

Installation on lxplus

 
Changed:
<
<
Allpix comes with a set of some useful digitizers to emulate the behavior of well-known pixel detector front-end like medipix. Click on the name of the digitizer for a description of its functionalities (Work In Progress)
>
>
A Standard GEANT4 (4.9.6.2) installation with SoXt and Coin3D support has been compiled and made available to lxplus (SLC6) users. To use this configuration , first check out the latest release of the AllPix Framework (currently 1.0)
 
Changed:
<
<
AllpixTimepixDigitizer
>
>
svn co http://svn.cern.ch/guest/allpix/tags/AllPix_v1.0

In the downloaded folder, a bash script has been prepared to setup the GEANT4 and ROOT dependencies needed by allpix. The script (setup_allpix.sh) must be edited to provide geant4 with a folder to write down the temporary files and executables. Create a folder in your home or work directory (for example ~/Geant4_workdir). Edit the setup_allpix.sh file to point geant4 to this directory using the $G4WORKDIR environnement variable :

export G4WORKDIR=~/Geant4_workdir
 
Changed:
<
<
This digitizer can be used to simulate Timepix familly chips.
>
>
Once this modification made, source the script and compile AllPix :
 
Added:
>
>
source setup_allpix.sh
make clean
make
 
Changed:
<
<

Known issues:

>
>

Known issues:

  [reported by I.Rubinskiy 21-03-2013]

Ubuntu 12.04 64bit. Allpix fails to build the allpix executable complaining for missing xerces methods (as undefined).

Changed:
<
<
Solution 1: regress the compiler version to g++-4.4: CXX = g++-4.4 (in the Makefile)
>
>
Solution 1: regress the compiler version to g++-4.4: CXX = g++-4.4 (in the Makefile)
  Solution 2: add more packages / the following recommendation was found at http://www.linuxquestions.org/questions/programming-9/undefined-reference-problem-819467/
 apt-get install libxerces-c2-dev libssl-dev libboost-dev swig 
Added:
>
>

Development in the AllPix Framework

Users developing new digitizers and adding modifications to the AllPix framework are strongly recommended to use our SVN versioning system to keep trace of their modifications and allow for other users to benefit from the improvements added to the code. To gain authorization to commit code to the AllPix SVN, please email the current developer list to be added to the current developers e-group (allpix-dev@cernNOSPAMPLEASE.ch). To checkout a version for development, please use the secured version of the SVN repository :

svn checkout https://svn.cern.ch/reps/allpix/tags/AllPix_v1.0

or

svn checkout svn+ssh://svn.cern.ch/reps/allpix/tags/AllPix_v1.0

The second step is to create your own branch of the development code :

svn copy svn+ssh://svn.cern.ch/reps/allpix/tags/AllPix_v1.0  svn+ssh://svn.cern.ch/reps/allpix/branch/NAME_OF_BRANCH   -m "Creating a branch of project named NAME_OF_BRANCH"

Finally switch you current checkout to the newly created branch, from the checked-out folder containing AllPix :

svn switch svn+ssh://svn.cern.ch/reps/allpix/branch/NAME_OF_BRANCH

You can then develop your code and commit it to your branch to keep track of your development. When creating a new release, AllPix developers will then be able to merge your improvement into the released version.

Allpix Digitizers

Allpix comes with a set of some useful digitizers to emulate the behavior of well-known pixel detector front-end like medipix. Click on the name of the digitizer for a description of its functionalities (Work In Progress)

  • AllpixTimepixDigitizer : This digitizer can be used to simulate Timepix familly chips.
  • AllpixMCTruthDigitizer : This simple digitizer return only the hits energy for each pixel of the matrix. This is useful for debugging and developing new geometries or extracting dE/dX values.
  • AllPixMimosa26Digitizer : This digitizer is use to simulate the Mimosa26 monolithic detectors, this digitizer has been calibrated with Test Beam data and should be used for the simulation of the EUDET telescope tracking planes

An automated method to generate a new digitizer for your application is provided in the main folder of AllPix. To create a new digitizer, simply run the following command and answer the questions prompted by the code generation script :

source newdigitizer.sh

A new class will then be created with the name AllPixYOUDIGNAMEDigitizer will be created and the corresponding source code will be created in the src and include folder of AllPix. This is then the user's responsibility to develop a digitizer for his purposes. A few digitizer covering most common user cases are also provided (see above).

Bug tracking

A JIRA bug tracker has been deployed to keep track of current issues affecting the AllPix Framework. To submit a bug/Feature request, please visit the AllPix JIRA page at https://its.cern.ch/jira/browse/ALLPIX

Working with the AllPix Framework

Pixel detector geometry description

Appliances and Test Structures

Writing a Macro to drive your simulation

General GEANT4 macro commands

AllPix specific Macro commands

Analysis of your Simulation results

Analysis in the Mafalda Framework

Analysis in the EUTELESCOPE Framework

 
Changed:
<
<
-- JohnIdarraga - 29-Mar-2012
>
>
-- MathieuB - 12 Feb 2014
 
META FILEATTACHMENT attachment="G4OpenGL_030.jpg" attr="" comment="allpix simulation of Timepix stack" date="1350688483" name="G4OpenGL_030.jpg" path="G4OpenGL_030.jpg" size="96855" user="idarraga" version="1"

Revision 112013-10-30 - JohnIdarraga

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"
  • allpix simulation of Timepix stack:
    G4OpenGL_030.jpg
Line: 50 to 50
 make
Added:
>
>
If you are running the EUDET Telescope you need to setup the following env variable before "make"

export EUTELESCOPE=1
 Run with vis

Revision 102013-03-21 - IgorRubinskiy

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"
  • allpix simulation of Timepix stack:
    G4OpenGL_030.jpg
Line: 66 to 66
 

Known issues:

Deleted:
<
<
Ubuntu 12.04 64bit. Allpix fails to find manually installed xerces 3.1.1. Solution: actually it seems that there is a need for few more packages rather then just one xerces. the following recommendation was found at http://www.linuxquestions.org/questions/programming-9/undefined-reference-problem-819467/
 
Changed:
<
<
 apt-get install libxerces-c2-dev  libxerces-c3.1 libssl-dev libboost-dev swig 
>
>
[reported by I.Rubinskiy 21-03-2013]

Ubuntu 12.04 64bit. Allpix fails to build the allpix executable complaining for missing xerces methods (as undefined).

Solution 1: regress the compiler version to g++-4.4: CXX = g++-4.4 (in the Makefile)

Solution 2: add more packages / the following recommendation was found at http://www.linuxquestions.org/questions/programming-9/undefined-reference-problem-819467/

 apt-get install libxerces-c2-dev libssl-dev libboost-dev swig 
 
Deleted:
<
<
then, add the defautl instalaltion xercesroot path '/usr' to GEANT4 cmake file, recompile GEANT4 with GDML ON and pointing to corrected XERCES. check that XERCESROOT is correct in geant4make.sh after you have generated the make files with 'cmake .'. When GEANT4 has finished compiling proceed with allpix compilation.
  -- JohnIdarraga - 29-Mar-2012

Revision 92013-03-03 - IgorRubinskiy

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"
  • allpix simulation of Timepix stack:
    G4OpenGL_030.jpg
Line: 65 to 65
 This digitizer can be used to simulate Timepix familly chips.
Added:
>
>

Known issues:

Ubuntu 12.04 64bit. Allpix fails to find manually installed xerces 3.1.1. Solution: actually it seems that there is a need for few more packages rather then just one xerces. the following recommendation was found at http://www.linuxquestions.org/questions/programming-9/undefined-reference-problem-819467/
 
Added:
>
>
 apt-get install libxerces-c2-dev  libxerces-c3.1 libssl-dev libboost-dev swig 

then, add the defautl instalaltion xercesroot path '/usr' to GEANT4 cmake file, recompile GEANT4 with GDML ON and pointing to corrected XERCES. check that XERCESROOT is correct in geant4make.sh after you have generated the make files with 'cmake .'. When GEANT4 has finished compiling proceed with allpix compilation.

  -- JohnIdarraga - 29-Mar-2012

Revision 82012-10-20 - JohnIdarraga

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"
Added:
>
>
  • allpix simulation of Timepix stack:
    G4OpenGL_030.jpg
 

Dependencies

The tricky dependency is OpenInventor. There is a number of ways in which you can install OpenInventor in your system. One (the most portable) is through the Coin3D project.

Line: 65 to 68
 

-- JohnIdarraga - 29-Mar-2012 \ No newline at end of file

Added:
>
>
META FILEATTACHMENT attachment="G4OpenGL_030.jpg" attr="" comment="allpix simulation of Timepix stack" date="1350688483" name="G4OpenGL_030.jpg" path="G4OpenGL_030.jpg" size="96855" user="idarraga" version="1"

Revision 72012-05-17 - JohnIdarraga

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

Dependencies

Line: 32 to 32
 Allpix code is available in the svn at CERN
Changed:
<
<
svn co http://svnweb.cern.ch/guest/allpix
>
>
svn co http://svn.cern.ch/guest/allpix
 

before compiling don't forget to source your Geant4 setup

Revision 62012-05-07 - JohnIdarraga

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

Dependencies

Line: 11 to 11
 
libInventorXt.so -->
libSoXt.so
Changed:
<
<
configure geant4.9.5 compatible with allpix (including OpenInventor visualization). WARNING make sure you have cmake >= 2.8.x. Make sure to add Coin/bin and SoXt/bin folders to your path. Cmake will look for the executable coin-config and soxt-config to setup the openInventor driver.
>
>
Compile >=geant4.9.5 compatible with allpix (including OpenInventor visualization) Geant4 home page. WARNING make sure you have cmake >= 2.8.x. Make sure to add Coin/bin and SoXt/bin folders to your path. Cmake will look for the executables 'coin-config' and 'soxt-config' to setup the openInventor driver. Here's the cmake line that will prepare a Geant4 build compatible with allpix:
 
cmake -DCMAKE_INSTALL_PREFIX=/home/idarraga/hep/geant4.9.5-install -DGEANT4_USE_GDML=ON -DCMAKE_BUILD_TYPE=Debug -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_OPENGL_X11=ON -DGEANT4_USE_XM=ON -DGEANT4_USE_INVENTOR=ON -DINVENTOR_INCLUDE_DIR=/usr/local/include/Inventor -DINVENTOR_LIBRARY_RELEASE=/usr/local/lib/libCoin.so -DINVENTOR_SOXT_LIBRARY=/usr/local/lib/libSoXt.so -DGEANT4_USE_QT=ON /home/idarraga/hep/geant4.9.5
Changed:
<
<
compile (you probably want to use many cores with -jN flag, where N is the number of cores)
>
>
if everything goes smooth with cmake, now compile geant4 (you probably want to use many cores with -jN flag, where N is the number of cores)
 
make

Revision 52012-03-30 - JohnIdarraga

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

Dependencies

Changed:
<
<
The tricky dependency is OpenInventor. There is a number of ways in which you can install OpenInventor in your system. One (the most portable) is through the Coin3D project. Download and compile Coin and SoXt. Basically libCoin replaces libInventor and libSoXt replaces libInventorXt. Later on, at running time, you have to produce the proper symbolic links in your system
>
>
The tricky dependency is OpenInventor. There is a number of ways in which you can install OpenInventor in your system. One (the most portable) is through the Coin3D project.

Download and compile Coin and SoXt. ATTENTION soxt-config and coin-config programs should be in your path after installation. Basically libCoin replaces libInventor and libSoXt replaces libInventorXt. Later on, at running time, you have to produce the proper symbolic links in your system

 
libInventor.so --> llibCoin.so

Revision 42012-03-30 - MathieuB

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

Dependencies

Line: 9 to 9
 
libInventorXt.so -->
libSoXt.so
Changed:
<
<
configure geant4.9.5 compatible with allpix (including OpenInventor visualization). WARNING make sure you have cmake >= 2.8.x
>
>
configure geant4.9.5 compatible with allpix (including OpenInventor visualization). WARNING make sure you have cmake >= 2.8.x. Make sure to add Coin/bin and SoXt/bin folders to your path. Cmake will look for the executable coin-config and soxt-config to setup the openInventor driver.
 
cmake -DCMAKE_INSTALL_PREFIX=/home/idarraga/hep/geant4.9.5-install -DGEANT4_USE_GDML=ON -DCMAKE_BUILD_TYPE=Debug -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_OPENGL_X11=ON -DGEANT4_USE_XM=ON -DGEANT4_USE_INVENTOR=ON -DINVENTOR_INCLUDE_DIR=/usr/local/include/Inventor -DINVENTOR_LIBRARY_RELEASE=/usr/local/lib/libCoin.so -DINVENTOR_SOXT_LIBRARY=/usr/local/lib/libSoXt.so -DGEANT4_USE_QT=ON /home/idarraga/hep/geant4.9.5

Revision 32012-03-30 - JohnIdarraga

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

Dependencies

Line: 9 to 9
 
libInventorXt.so -->
libSoXt.so
Changed:
<
<
configure geant4.9.5 compatible with allpix (including OpenInventor visualization)
>
>
configure geant4.9.5 compatible with allpix (including OpenInventor visualization). WARNING make sure you have cmake >= 2.8.x
 
cmake -DCMAKE_INSTALL_PREFIX=/home/idarraga/hep/geant4.9.5-install -DGEANT4_USE_GDML=ON -DCMAKE_BUILD_TYPE=Debug -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_OPENGL_X11=ON -DGEANT4_USE_XM=ON -DGEANT4_USE_INVENTOR=ON -DINVENTOR_INCLUDE_DIR=/usr/local/include/Inventor -DINVENTOR_LIBRARY_RELEASE=/usr/local/lib/libCoin.so -DINVENTOR_SOXT_LIBRARY=/usr/local/lib/libSoXt.so -DGEANT4_USE_QT=ON /home/idarraga/hep/geant4.9.5

Revision 22012-03-30 - MathieuB

Line: 1 to 1
 
META TOPICPARENT name="JohnIdarraga"

Dependencies

Line: 51 to 51
 allpix macros/oneDetector_Inventor_vis.in
Added:
>
>

Allpix Digitizers

Allpix comes with a set of some useful digitizers to emulate the behavior of well-known pixel detector front-end like medipix. Click on the name of the digitizer for a description of its functionalities (Work In Progress)

AllpixTimepixDigitizer

This digitizer can be used to simulate Timepix familly chips.

 -- JohnIdarraga - 29-Mar-2012

Revision 12012-03-29 - JohnIdarraga

Line: 1 to 1
Added:
>
>
META TOPICPARENT name="JohnIdarraga"

Dependencies

The tricky dependency is OpenInventor. There is a number of ways in which you can install OpenInventor in your system. One (the most portable) is through the Coin3D project. Download and compile Coin and SoXt. Basically libCoin replaces libInventor and libSoXt replaces libInventorXt. Later on, at running time, you have to produce the proper symbolic links in your system

libInventor.so --> llibCoin.so
libInventorXt.so --> libSoXt.so

configure geant4.9.5 compatible with allpix (including OpenInventor visualization)

cmake -DCMAKE_INSTALL_PREFIX=/home/idarraga/hep/geant4.9.5-install -DGEANT4_USE_GDML=ON -DCMAKE_BUILD_TYPE=Debug -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_OPENGL_X11=ON -DGEANT4_USE_XM=ON -DGEANT4_USE_INVENTOR=ON -DINVENTOR_INCLUDE_DIR=/usr/local/include/Inventor -DINVENTOR_LIBRARY_RELEASE=/usr/local/lib/libCoin.so -DINVENTOR_SOXT_LIBRARY=/usr/local/lib/libSoXt.so -DGEANT4_USE_QT=ON /home/idarraga/hep/geant4.9.5

compile (you probably want to use many cores with -jN flag, where N is the number of cores)

make

If you are compiling Makefile based projects, which is the case with allpix, you need to source this first

source YOURPATH/geant4.9.5-install/share/Geant4-9.5.0/geant4make/geant4make.sh

Download compile and run allpix

Allpix code is available in the svn at CERN

svn co http://svnweb.cern.ch/guest/allpix

before compiling don't forget to source your Geant4 setup

source YOURPATH/geant4.9.5-install/share/Geant4-9.5.0/geant4make/geant4make.sh

Now compile

make

Run with vis

allpix macros/oneDetector_Inventor_vis.in

-- JohnIdarraga - 29-Mar-2012

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