|
| 1 | +================================================================ |
| 2 | +Geant4 simulation for SuperNEMO demonstrator |
| 3 | +================================================================ |
| 4 | + |
| 5 | +:Authors: François Mauger, Yves Lemière |
| 6 | +:Date: 2018-01-19 |
| 7 | + |
| 8 | +.. contents:: |
| 9 | + :depth: 3 |
| 10 | +.. |
| 11 | +
|
| 12 | +Presentation |
| 13 | +============ |
| 14 | + |
| 15 | +This directory contains the files needed to run Geant4 simulation |
| 16 | +for the SuperNEMO demonstrator simulation. |
| 17 | + |
| 18 | +* Version is : ``2.2`` |
| 19 | + |
| 20 | +This setup reuses a large part of the ``2.1`` setup depends on: |
| 21 | + |
| 22 | +* the SuperNEMO demonstrator's geometry layout (``4.0``) and its variants. |
| 23 | +* the SuperNEMO vertex generation (``4.1``) and its variants. |
| 24 | +* the SuperNEMO primary event generation (``1.3``) and its variants. |
| 25 | + |
| 26 | +Files |
| 27 | +===== |
| 28 | + |
| 29 | + * ``README.rst`` : This file. |
| 30 | + * ``manager.conf`` : The main configuration file for the |
| 31 | + Bayeux/mctools Geant4 simulation engine. |
| 32 | + * ``variants/`` : This directory contains configuration files |
| 33 | + for variant support. |
| 34 | + |
| 35 | +Check the configuration |
| 36 | +======================= |
| 37 | + |
| 38 | +First make sure the Bayeux and Falaise softwares are installed and setup |
| 39 | +from a (Cadfael)brew shell: |
| 40 | + |
| 41 | +.. code:: sh |
| 42 | +
|
| 43 | + brewsh> which bxvariant_inspector |
| 44 | + ... |
| 45 | + brewsh> which bxg4_production |
| 46 | + ... |
| 47 | +.. |
| 48 | +
|
| 49 | +Browse and edit primary event generation variant parameters and options |
| 50 | +=============================================================================== |
| 51 | + |
| 52 | +1. From the build directory, generate documentation about variants: |
| 53 | + |
| 54 | +.. code:: sh |
| 55 | +
|
| 56 | + brewsh> bxvariant_inspector \ |
| 57 | + --datatools::resource-path="falaise@$(pwd)/BuildProducts/share/Falaise-3.0.0/resources" \ |
| 58 | + --variant-config "@falaise:config/snemo/demonstrator/simulation/geant4_control/2.2/variants/repository.conf" \ |
| 59 | + --action doc > flg4ctrl.rst |
| 60 | + brewsh> flg4ctrl.rst > flg4ctrl.html |
| 61 | + brewsh> xdg-open flg4ctrl.html & |
| 62 | + brewsh> rst2pdf flg4ctrl.rst |
| 63 | + brewsh> xdg-open flg4ctrl.pdf & |
| 64 | +.. |
| 65 | +or: |
| 66 | + |
| 67 | +.. code:: sh |
| 68 | +
|
| 69 | + brewsh> pandoc -t latex flg4ctrl.rst -o flg4ctrl.pdf |
| 70 | +.. |
| 71 | +
|
| 72 | +2. From the build directory, browse/edit the primary event generation variant and generate a variant profile:: |
| 73 | + |
| 74 | +.. code:: sh |
| 75 | +
|
| 76 | + brewsh> bxvariant_inspector \ |
| 77 | + --datatools::resource-path="falaise@$(pwd)/BuildProducts/share/Falaise-3.0.0/resources" \ |
| 78 | + --variant-config "@falaise:config/snemo/demonstrator/simulation/geant4_control/2.2/variants/repository.conf" \ |
| 79 | + --variant-gui \ |
| 80 | + --variant-store "myprofile.conf" |
| 81 | +.. |
| 82 | +
|
| 83 | +Run Geant4 |
| 84 | +---------------------------------------------------------------------- |
| 85 | + |
| 86 | +Run from the Falaise build directory. Here we **don't** use the variant |
| 87 | +support but manually set vertex and particle generators associated to |
| 88 | +the default geometry: |
| 89 | + |
| 90 | +.. raw:: sh |
| 91 | +
|
| 92 | + brewsh> LD_LIBRARY_PATH="$(pwd)/BuildProducts/lib:${LD_LIBRARY_PATH}" \ |
| 93 | + bxg4_production \ |
| 94 | + --datatools::logging "warning" \ |
| 95 | + --datatools::resource-path "falaise@$(pwd)/BuildProducts/share/Falaise-3.0.0/resources" \ |
| 96 | + --logging-priority "debug" \ |
| 97 | + --load-dll Falaise \ |
| 98 | + --config @falaise:config/snemo/demonstrator/simulation/geant4_control/2.2/manager.conf \ |
| 99 | + --vertex-generator-name "source_pads_bulk" \ |
| 100 | + --vertex-generator-seed 0 \ |
| 101 | + --event-generator-name "Tl208" \ |
| 102 | + --event-generator-seed 0 \ |
| 103 | + --g4-manager-seed 0 \ |
| 104 | + --shpf-seed 0 \ |
| 105 | + --output-prng-seeds-file mc_g4_production.seeds \ |
| 106 | + --output-prng-states-file mc_g4_production.states \ |
| 107 | + --batch \ |
| 108 | + --using-time-statistics \ |
| 109 | + --number-of-events 10 \ |
| 110 | + --number-of-events-modulo 2 \ |
| 111 | + --output-data-format "bank" \ |
| 112 | + --output-data-bank "SD" \ |
| 113 | + --output-data-file "cfg1-Tl208-source.xml" |
| 114 | +.. |
| 115 | +
|
| 116 | +Run from the Falaise build directory. Here we **do** use the variant |
| 117 | +support to set the vertex and particle generators associated to some |
| 118 | +variant geometry layout: |
| 119 | + |
| 120 | +.. raw:: sh |
| 121 | +
|
| 122 | + brewsh> LD_LIBRARY_PATH="$(pwd)/BuildProducts/lib:${LD_LIBRARY_PATH}" \ |
| 123 | + bxg4_production \ |
| 124 | + --datatools::logging "warning" \ |
| 125 | + --datatools::resource-path "falaise@$(pwd)/BuildProducts/share/Falaise-3.X.X/resources" \ |
| 126 | + --logging-priority "debug" \ |
| 127 | + --load-dll Falaise \ |
| 128 | + --variant-config "@falaise:config/snemo/demonstrator/simulation/geant4_control/2.2/variants/repository.conf" \ |
| 129 | + --variant-gui \ |
| 130 | + --variant-store "cfg1.conf" \ |
| 131 | + --config @falaise:config/snemo/demonstrator/simulation/geant4_control/2.2/manager.conf \ |
| 132 | + --vertex-generator-seed 0 \ |
| 133 | + --event-generator-seed 0 \ |
| 134 | + --g4-manager-seed 0 \ |
| 135 | + --shpf-seed 0 \ |
| 136 | + --output-prng-seeds-file mc_g4_production.seeds \ |
| 137 | + --output-prng-states-file mc_g4_production.states \ |
| 138 | + --using-time-statistics \ |
| 139 | + --number-of-events 100 \ |
| 140 | + --number-of-events-modulo 10 \ |
| 141 | + --output-data-format "bank" \ |
| 142 | + --output-data-bank "SD" \ |
| 143 | + --output-data-file "cfg1-out.xml" |
| 144 | +.. |
| 145 | +
|
| 146 | +Run in interactive mode: |
| 147 | + |
| 148 | +.. raw:: sh |
| 149 | +
|
| 150 | + brewsh> LD_LIBRARY_PATH="$(pwd)/BuildProducts/lib:${LD_LIBRARY_PATH}" \ |
| 151 | + bxg4_production \ |
| 152 | + --datatools::logging "warning" \ |
| 153 | + --datatools::resource-path "falaise@$(pwd)/BuildProducts/share/Falaise-3.X.X/resources" \ |
| 154 | + --logging-priority "debug" \ |
| 155 | + --load-dll Falaise \ |
| 156 | + --variant-config "@falaise:config/snemo/demonstrator/simulation/geant4_control/2.2/variants/repository.conf" \ |
| 157 | + --variant-gui \ |
| 158 | + --variant-store "cfg1.conf" \ |
| 159 | + --config @falaise:config/snemo/demonstrator/simulation/geant4_control/2.2/manager.conf \ |
| 160 | + --vertex-generator-seed 0 \ |
| 161 | + --event-generator-seed 0 \ |
| 162 | + --g4-manager-seed 0 \ |
| 163 | + --shpf-seed 0 \ |
| 164 | + --output-prng-seeds-file mc_g4_production.seeds \ |
| 165 | + --output-prng-states-file mc_g4_production.states \ |
| 166 | + --using-time-statistics \ |
| 167 | + --number-of-events 100 \ |
| 168 | + --number-of-events-modulo 10 \ |
| 169 | + --output-data-format "bank" \ |
| 170 | + --output-data-bank "SD" \ |
| 171 | + --output-data-file "cfg1-source.xml" \ |
| 172 | + --interactive \ |
| 173 | + --g4-visu \ |
| 174 | + --g4-macro "@falaise:config/snemo/demonstrator/simulation/geant4_control/2.2/visu/visu_0.mac" |
| 175 | +.. |
| 176 | +
|
| 177 | + |
| 178 | +.. end |
0 commit comments