Difference: TargetStudy (1 vs. 8)

Revision 82015-11-27 - LucaPescatore

Line: 1 to 1
 
META TOPICPARENT name="GeometryActivationExamples"
-- SajanEaso - 21 Jan 2014
Changed:
<
<

Options for Target study

>
>

Target tool to study hadronic cross secitons in blocks of material in Gauss

 
Changed:
<
<
The tool fires particles into blocks of material and returns information on probability of hadronic interaction and multiplicity and composition of daughters.
To run the tool ensure that you have the latest versions of Sim/GaussTools and Gen/LbPGuns
>
>
The tool fires particles into blocks of material and returns information on the probability of hadronic interaction and multiplicity and composition of daughters.
 
Changed:
<
<
getpack Sim/SimChecks
cd scripts/Target
>
>
The tool is documented in LHCb-INT-2013-026.

How to run

 
Changed:
<
<
Remember to setup Gauss "SetupProject Gauss (your version)"
>
>
To run the Target package you first need to setup the desired Gauss version (SetupProject Gauss (version)). If the SimChecks package is present in its latest version youwill have the variables $SIMCHECKSROOT and $TARGETOPTS defined. In case they are not defined, you need to getpack the SimChecks package:
 
Changed:
<
<

Single Target

>
>
SetupProject --build-env Gauss (version) 
getpack Sim/SimChecks 
cd Sim/SimChecks/cmt 
cmt make 
SetupProject Gauss (version)
 
Changed:
<
<
This options can be used to obtain rootfiles for one specific combination of initial particle ID and energy and target material and thickness.
In the next secttion an option to run many combinations at once is described.
To run the tool setup Gauss and then:
>
>
Now the package is setup. To produce plots you can use the options defined in $TARGETOPTS. For example the option file MakeEvents _1mm_Al_AllPGun.py will produce events for all available particle guns, using a target of 1 mm Aluminium.
 
Changed:
<
<
cd SingleTarget
>
>
To run this script:
python $TARGETOPTS/MakeEvents_1mm_Al_AllPGun.py
 
Changed:
<
<
gaudirun.py Gauss-LHCb-Target-2013.py Gauss-Job-SingleTarget.py
>
>
You may also copy the option in a local folder if you wish.
 
Changed:
<
<
Inside Gauss-Job-SingleTarget.py you can instead choose number of events generate and name of output files.
>
>
At the top of the option file several parameters can be set:
 
Changed:
<
<
Target properties:

Inside Gauss-LHCb-Target-2013.py you can change the target properties by changing the line

target = 'Target_(thickness)mm(material)'

Available targets are 1, 5, 10 mm and availble maretials are 'Al' 'Be' 'Si'. (e.g. target = 'Target_1mmAl')

Incoming particle properties:

You can copy the file $LBPGUNSROOT/options/TargetMaterialGun.py. This contains the definition of the particle gun.
In particular the following two lines modify ID and energy of the particle.

ParticleGun.MaterialEval.PdgCode = 2212 (proton)

ParticleGun.MaterialEval.ModP = 3 * GeV

Before running change the following line in "Gauss-Job-SingleTarget.py" to pick up your pgun option file.

importOptions ("$LBPGUNSROOT/options/TargetMaterialGun.py")

Hadronic interaction model:

You can choose the hadronic interaction model to test by changing the following line in replacint QGSP_BERT with one of the models available in you Gauss version. (es. FTFP_BERT, LHEP)

Gauss.PhysicsList = {"Em":'NoCuts', "Hadron":'QGSP_BERT', "GeneralPhys":True, "LHCbPhys":True}

Multiple Target

This options file allow to run the tool at once for many patricle types and energies, for many target materials and thicknesses and many hadronic interaction models.

cd MultiTarget

In the file Targer_CreateEvents.py you'll find the following lines which you can modify to run with your choice of energies, materials, etc.

models=['QGSP_BERT','FTFP_BERT','LHEP'] #any present in the version of Gauss you are using
energies=['1', '5', '10', '50', '100'] #any
materialsTodo=['Al'] # 'Al' 'Be' 'Si'
thicks=['1'] #in mm 1, 5, 10
particlesTodo=['p', 'pbar', 'Piminus', 'Piplus', 'Kminus', 'Kplus'] # Available: 'Piminus' 'Piplus' 'Kminus' 'Kplus' 'p' 'pbar'

Finally to run the tool: python Target_CreateEvents.py

This creates a "TargetOutput.root" file containing a tree with information about multiplicity and cross-section for all targets and pguns.

To get histograms you can look at the script "TargetPlot.py". This works in a similar way as Targer_CreateEvents.py and you need to set the same options and then run

python TargetPlots.py

In the MultiTarget folder there is a subfolder "options" containing some option files for specific options combinations. E.g. MakeEvents_1mm_Al_AllPguns.py will genetare all needed data for all pguns but onlu with the 1mm Al target. And will also produce plots in the end. Options beginning with "MakeEvents" make events and automatically make plots out of them. Instead the options beginning with "Plot" will perform plots on already existing data.

>
>
  • The output folder: path=os.environ[?HOME?]. I suggest to use a folder with at least 10GB of free space
  • Models to use: models=[?FTFP_BERT?,?QGSP_BERT?] or all other models available in you selected Gauss version
  • Incoming particle energy: energies=[1,2,5,10,50,100] or any other number, in GeV.
  • Target thicknesses: thicks=[1,10], only 1, 5 and 10 mm available.
  • Target materials: materials=[?Al?], only Al, Be and Si available.
  • The IDs of the incoming particles: pguns=["p","pbar"]. Available particles: p, pbar, Kminus, Kplus, Piminus, Piplus. If you add both a particle and its antiparticle in a row ratio plots will be produced too.
The scripts output several plots and .txt files with summary tables. Furthermore, two root files are produced:
 
Added:
>
>
  • TargetOutput.root: this is the direct output of the event production. It contains all information about each projectile and its daughters,
  • TargetsPlots.root: this file contains instead summary information extrated from the first (e.g. cross sections and multiplicities) file for easier readability.
 
Added:
>
>
</verbatim>

Revision 72014-11-12 - LucaPescatore

Line: 1 to 1
 
META TOPICPARENT name="GeometryActivationExamples"
-- SajanEaso - 21 Jan 2014

Options for Target study

Line: 49 to 49
  This options file allow to run the tool at once for many patricle types and energies, for many target materials and thicknesses and many hadronic interaction models.
Changed:
<
<
cd MultiTarget
>
>
cd MultiTarget
 
Changed:
<
<
In the file Targer_RunAll.py you'll find the following lines which you can modify to run with your choice of energies, materials, etc.
>
>
In the file Targer_CreateEvents.py you'll find the following lines which you can modify to run with your choice of energies, materials, etc.
  models=['QGSP_BERT','FTFP_BERT','LHEP'] #any present in the version of Gauss you are using
energies=['1', '5', '10', '50', '100'] #any
materialsTodo=['Al'] # 'Al' 'Be' 'Si'
thicks=['1'] #in mm 1, 5, 10
particlesTodo=['p', 'pbar', 'Piminus', 'Piplus', 'Kminus', 'Kplus'] # Available: 'Piminus' 'Piplus' 'Kminus' 'Kplus' 'p' 'pbar'
Changed:
<
<
Finally to run the tool: python Target_RunAll.py
>
>
Finally to run the tool: python Target_CreateEvents.py
 
Changed:
<
<
This creates the histograms in the TargetOutput subdirectory in this area. Inside this a folder structure is created organizing the root files.
A log allows you to visualize the running status of the tool while it runs. You may change the location of the output by changing the variable "path".
Finally, an "option.txt" file is created with a summary of the generated rootfiles properties.
>
>
This creates a "TargetOutput.root" file containing a tree with information about multiplicity and cross-section for all targets and pguns.
 
Changed:
<
<
Analyse rootfiles:
>
>
To get histograms you can look at the script "TargetPlot.py". This works in a similar way as Targer_CreateEvents.py and you need to set the same options and then run
 
Changed:
<
<
Some code to analyse the root files produced by the tool and obtain plots (e.g. cross section for different particles in different materials as a function of energy on a single plot).
At the moment this is not included in Gauss and can be found at /afs/cern.ch/work/p/pluca/public/TargetAnalysis
You can use directly the executable TargetAnalysis.o but cpp code is also provided together with a Makefile.
In order to use it you give as argument the path of the "options.txt" file created by Target_RunAll.py.
>
>
python TargetPlots.py

In the MultiTarget folder there is a subfolder "options" containing some option files for specific options combinations. E.g. MakeEvents_1mm_Al_AllPguns.py will genetare all needed data for all pguns but onlu with the 1mm Al target. And will also produce plots in the end. Options beginning with "MakeEvents" make events and automatically make plots out of them. Instead the options beginning with "Plot" will perform plots on already existing data.

 
Deleted:
<
<
TargetAnalysis.out <path>/options.txt
 
Deleted:
<
<
You may modify option.txt in order to personalyse the output plots. Options available are explained inside "option.txt" itself.

Revision 62014-01-24 - LucaPescatore

Line: 1 to 1
 
META TOPICPARENT name="GeometryActivationExamples"
-- SajanEaso - 21 Jan 2014

Options for Target study

Line: 25 to 25
  target = 'Target_(thickness)mm(material)'
Changed:
<
<
Available targets are 1, 5, 10 mm and availble maretials are 'Al' 'Be' 'Si'. (es. target = 'Target_1mmAl')
>
>
Available targets are 1, 5, 10 mm and availble maretials are 'Al' 'Be' 'Si'. (e.g. target = 'Target_1mmAl')
  Incoming particle properties:

You can copy the file $LBPGUNSROOT/options/TargetMaterialGun.py. This contains the definition of the particle gun.
In particular the following two lines modify ID and energy of the particle.

Changed:
<
<
PdgCode = 2212 (proton)
>
>
ParticleGun.MaterialEval.PdgCode = 2212 (proton)
 
Changed:
<
<
ModP = 3 * GeV
>
>
ParticleGun.MaterialEval.ModP = 3 * GeV
  Before running change the following line in "Gauss-Job-SingleTarget.py" to pick up your pgun option file.
Line: 43 to 43
  You can choose the hadronic interaction model to test by changing the following line in replacint QGSP_BERT with one of the models available in you Gauss version. (es. FTFP_BERT, LHEP)
Changed:
<
<
PhysicsList = {"Em":'NoCuts', "Hadron":'QGSP_BERT', "GeneralPhys":True, "LHCbPhys":True}
>
>
Gauss.PhysicsList = {"Em":'NoCuts', "Hadron":'QGSP_BERT', "GeneralPhys":True, "LHCbPhys":True}
 

Multiple Target

Line: 57 to 57
  Finally to run the tool: python Target_RunAll.py
Changed:
<
<
This creates the histograms in the TargetOutput subdirectory in this area. Inside this a folder structure is created organizing the root files.
A log allows you to visualize the running status of the tool while it runs. You may change the location of the output by changing the variable "path".
>
>
This creates the histograms in the TargetOutput subdirectory in this area. Inside this a folder structure is created organizing the root files.
A log allows you to visualize the running status of the tool while it runs. You may change the location of the output by changing the variable "path".
Finally, an "option.txt" file is created with a summary of the generated rootfiles properties.

Analyse rootfiles:

Some code to analyse the root files produced by the tool and obtain plots (e.g. cross section for different particles in different materials as a function of energy on a single plot).
At the moment this is not included in Gauss and can be found at /afs/cern.ch/work/p/pluca/public/TargetAnalysis
You can use directly the executable TargetAnalysis.o but cpp code is also provided together with a Makefile.
In order to use it you give as argument the path of the "options.txt" file created by Target_RunAll.py.

TargetAnalysis.out <path>/options.txt

You may modify option.txt in order to personalyse the output plots. Options available are explained inside "option.txt" itself.

Revision 52014-01-22 - LucaPescatore

Line: 1 to 1
 
META TOPICPARENT name="GeometryActivationExamples"
-- SajanEaso - 21 Jan 2014

Options for Target study

Changed:
<
<
Ensure that you have the latest versions of Sim/GaussTools and Gen/LbPGuns
>
>
The tool fires particles into blocks of material and returns information on probability of hadronic interaction and multiplicity and composition of daughters.
To run the tool ensure that you have the latest versions of Sim/GaussTools and Gen/LbPGuns
  getpack Sim/SimChecks
cd scripts/Target
Line: 11 to 11
 

Single Target

Added:
>
>
This options can be used to obtain rootfiles for one specific combination of initial particle ID and energy and target material and thickness.
In the next secttion an option to run many combinations at once is described.
To run the tool setup Gauss and then:
 cd SingleTarget

gaudirun.py Gauss-LHCb-Target-2013.py Gauss-Job-SingleTarget.py

Changed:
<
<
This creates the histogram files in this area which one can read using root.
>
>
Inside Gauss-Job-SingleTarget.py you can instead choose number of events generate and name of output files.

Target properties:

Inside Gauss-LHCb-Target-2013.py you can change the target properties by changing the line

target = 'Target_(thickness)mm(material)'

Available targets are 1, 5, 10 mm and availble maretials are 'Al' 'Be' 'Si'. (es. target = 'Target_1mmAl')

Incoming particle properties:

You can copy the file $LBPGUNSROOT/options/TargetMaterialGun.py. This contains the definition of the particle gun.
In particular the following two lines modify ID and energy of the particle.

PdgCode = 2212 (proton)

ModP = 3 * GeV

Before running change the following line in "Gauss-Job-SingleTarget.py" to pick up your pgun option file.

importOptions ("$LBPGUNSROOT/options/TargetMaterialGun.py")

Hadronic interaction model:

You can choose the hadronic interaction model to test by changing the following line in replacint QGSP_BERT with one of the models available in you Gauss version. (es. FTFP_BERT, LHEP)

PhysicsList = {"Em":'NoCuts', "Hadron":'QGSP_BERT', "GeneralPhys":True, "LHCbPhys":True}

 

Multiple Target

Changed:
<
<
This options file allow to run the tool at once for many patricle types and energies and for many target materials and thicknesses.
>
>
This options file allow to run the tool at once for many patricle types and energies, for many target materials and thicknesses and many hadronic interaction models.
  cd MultiTarget

In the file Targer_RunAll.py you'll find the following lines which you can modify to run with your choice of energies, materials, etc.

Changed:
<
<
models=['QGSP_BERT','FTFP_BERT','LHEP'] #any present in the version of Gauss you are using
energies=['1']#, '5', '10', '50', '100'] #any
materialsTodo=['Al'] # 'Al' 'Be' 'Si' thicks=['1'] #in mm 1, 5, 10
particlesTodo=['p', 'pbar', 'Piminus', 'Piplus', 'Kminus', 'Kplus'] # Available: 'Piminus' 'Piplus' 'Kminus' 'Kplus' 'p' 'pbar'
>
>
models=['QGSP_BERT','FTFP_BERT','LHEP'] #any present in the version of Gauss you are using
energies=['1', '5', '10', '50', '100'] #any
materialsTodo=['Al'] # 'Al' 'Be' 'Si'
thicks=['1'] #in mm 1, 5, 10
particlesTodo=['p', 'pbar', 'Piminus', 'Piplus', 'Kminus', 'Kplus'] # Available: 'Piminus' 'Piplus' 'Kminus' 'Kplus' 'p' 'pbar'
  Finally to run the tool: python Target_RunAll.py
Changed:
<
<
This creates the histograms in the TargetOutput subdirectory in this area. Inside this a folder structure is created organizing the root files.
A log allows you to visualize the running status of the tool while is runs. You may change the location of the output by changing the variable "path".
>
>
This creates the histograms in the TargetOutput subdirectory in this area. Inside this a folder structure is created organizing the root files.
A log allows you to visualize the running status of the tool while it runs. You may change the location of the output by changing the variable "path".

Revision 42014-01-22 - LucaPescatore

Line: 1 to 1
 
META TOPICPARENT name="GeometryActivationExamples"
-- SajanEaso - 21 Jan 2014

Options for Target study

Changed:
<
<
Ensure that you have the latest versions of Sim/GaussTools and Gen/LbPGuns
getpack Sim/SimChecks
cd scripts/Target
>
>
Ensure that you have the latest versions of Sim/GaussTools and Gen/LbPGuns

getpack Sim/SimChecks
cd scripts/Target

Remember to setup Gauss "SetupProject Gauss (your version)"

 

Single Target

cd SingleTarget

Line: 16 to 21
  This options file allow to run the tool at once for many patricle types and energies and for many target materials and thicknesses.
Changed:
<
<
cd ../MultiTarget
>
>
cd MultiTarget
  In the file Targer_RunAll.py you'll find the following lines which you can modify to run with your choice of energies, materials, etc.
Line: 24 to 29
  Finally to run the tool: python Target_RunAll.py
Changed:
<
<
This creates the histograms in the targetOutput subdirectory in this area. Inside this a folder structure is created organizing the root files.
A log allows you to visualize the running status of the tool while is runs.
>
>
This creates the histograms in the TargetOutput subdirectory in this area. Inside this a folder structure is created organizing the root files.
A log allows you to visualize the running status of the tool while is runs. You may change the location of the output by changing the variable "path".

Revision 32014-01-22 - LucaPescatore

Line: 1 to 1
 
META TOPICPARENT name="GeometryActivationExamples"
-- SajanEaso - 21 Jan 2014

Options for Target study

Changed:
<
<
Ensure that you have the latest versions of Sim/GaussTools and Gen/LbPGuns
getpack Sim/SimChecks
cd scripts/Target
>
>
Ensure that you have the latest versions of Sim/GaussTools and Gen/LbPGuns
getpack Sim/SimChecks
cd scripts/Target
 

Single Target

Changed:
<
<
cd SingleTarget
>
>
cd SingleTarget
 
Changed:
<
<
gaudirun.py Gauss-LHCb-Target-2013.py Gauss-Job-SingleTarget.py
>
>
gaudirun.py Gauss-LHCb-Target-2013.py Gauss-Job-SingleTarget.py
  This creates the histogram files in this area which one can read using root.

Line: 14 to 12
  This creates the histogram files in this area which one can read using root.

Deleted:
<
<
 

Multiple Target

Changed:
<
<
cd ../MultiTarget
python Target_RunAll.py
>
>
This options file allow to run the tool at once for many patricle types and energies and for many target materials and thicknesses.

cd ../MultiTarget

In the file Targer_RunAll.py you'll find the following lines which you can modify to run with your choice of energies, materials, etc.

 
Changed:
<
<
This creates the histograms in the targetOutput subdirectory in this area.
>
>
models=['QGSP_BERT','FTFP_BERT','LHEP'] #any present in the version of Gauss you are using
energies=['1']#, '5', '10', '50', '100'] #any
materialsTodo=['Al'] # 'Al' 'Be' 'Si' thicks=['1'] #in mm 1, 5, 10
particlesTodo=['p', 'pbar', 'Piminus', 'Piplus', 'Kminus', 'Kplus'] # Available: 'Piminus' 'Piplus' 'Kminus' 'Kplus' 'p' 'pbar'
 
Added:
>
>
Finally to run the tool: python Target_RunAll.py
 
Added:
>
>
This creates the histograms in the targetOutput subdirectory in this area. Inside this a folder structure is created organizing the root files.
A log allows you to visualize the running status of the tool while is runs.

Revision 22014-01-21 - SajanEaso

Line: 1 to 1
 
META TOPICPARENT name="GeometryActivationExamples"
Deleted:
<
<
 -- SajanEaso - 21 Jan 2014

Options for Target study

Line: 4 to 3
 -- SajanEaso - 21 Jan 2014

Options for Target study

Added:
>
>
Ensure that you have the latest versions of Sim/GaussTools and Gen/LbPGuns
getpack Sim/SimChecks
cd scripts/Target
 

Single Target

Added:
>
>
cd SingleTarget

gaudirun.py Gauss-LHCb-Target-2013.py Gauss-Job-SingleTarget.py

This creates the histogram files in this area which one can read using root.

 

Multiple Target

\ No newline at end of file
Added:
>
>
cd ../MultiTarget
python Target_RunAll.py

This creates the histograms in the targetOutput subdirectory in this area.

Revision 12014-01-21 - SajanEaso

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

-- SajanEaso - 21 Jan 2014

Options for Target study

Single Target

Multiple Target

 
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