Difference between revisions of "Aod ntuple"

From Atlas Wiki
Jump to navigation Jump to search
Line 14: Line 14:
 
</ol>
 
</ol>
  
 +
'''1.'''
 
The <code>isEM</code> flag uses both calorimeter and tracking information in addition to TRT
 
The <code>isEM</code> flag uses both calorimeter and tracking information in addition to TRT
 
information. The flag is a bit field which marks whether the candidate passed or not some safety checks.
 
information. The flag is a bit field which marks whether the candidate passed or not some safety checks.
Line 19: Line 20:
 
The bit field marks the following checks:
 
The bit field marks the following checks:
 
<code>
 
<code>
// Cluster based egamma
+
  Cluster based egamma
 
   ClusterEtaRange        =  0,
 
   ClusterEtaRange        =  0,
 
   ClusterHadronicLeakage =  1,
 
   ClusterHadronicLeakage =  1,
 
   ClusterMiddleSampling  =  2,
 
   ClusterMiddleSampling  =  2,
 
   ClusterFirstSampling  =  3,
 
   ClusterFirstSampling  =  3,
// Track based egamma
+
  Track based egamma
 
   TrackEtaRange          =  8,
 
   TrackEtaRange          =  8,
 
   TrackHitsA0            =  9,
 
   TrackHitsA0            =  9,
Line 31: Line 32:
 
</code>
 
</code>
  
In 9.0.4 there is a problem with TRT simulation so one has to
+
In 9.0.4 there is a problem with TRT simulation so one has to mask TRT bit to recover the lost efficiency.  
mask TRT bit to recover the lost efficiency. The variable which combine
+
 
everything is isEM and it is used as follow:
+
To get the flag in your AOD analysis you should use:
  
 
<code>
 
<code>
 
(*elec)->isEM()
 
(*elec)->isEM()
 
</code>
 
</code>
to mask TRT bit you should use: <code>(*elec)->isEM()%16==0</code>
 
  
if you use isEM then you will select electrons with an overall eff of about
+
To mask the TRT bits you should use: <code>(*elec)->isEM()&0x7FF==0</code>
80% in the barrel but much lower in the crack and endcup.
 
  
 +
If you use <code>isEM</code> then you will select electrons with an overall efficiency of about
 +
80% in the barrel but much lower in the crack and endcap.
  
-alg 2 use likelihood ratio and use the following variable:
+
'''2.'''
 +
The likelihood ratio is constructed using the following variables: energy in different calorimeter samplings, shower shapes in both eta and phi and E/P ration. No TRT information is used here.
 +
You need to access two variables called <code>emweight</code> and <code>pionweight</code> then you can construct the likelihood ratio, defined by: <code>emweight/(emweight+pionweight)</code>. Emweight is the product of pdf's
  
energy in different calorimeter sampling, shower shapes in both eta and phi
+
In AOD, you use the following code:
and E/P. No TRT information is used here. You need to access two variables
 
called emweight and pionweight then you can construct the likelihood ratio:
 
defined by: emweight/(emweight+pionweight). Emweight is the product of pdf's
 
for electrons and pionweight is the product of pdf's for pions. In AOD, you
 
use the following code:
 
  
 +
<code>
 
ElecEMWeight = elec*->parameter(ElectronParameters::emWeight);
 
ElecEMWeight = elec*->parameter(ElectronParameters::emWeight);
 
ElecPiWeight = elec*->parameter(ElectronParameters::pionWeight);
 
ElecPiWeight = elec*->parameter(ElectronParameters::pionWeight);
 +
</code>
  
 
Then form the variable:
 
Then form the variable:
X = ElecEMWeight/(ElecEMWeight+ElecPiWeight)
+
<code>
 +
X = ElecEMWeight/(ElecEMWeight+ElecPiWeight);
 +
</code>
  
Requiring X > 0.6 will give you more than 90% eff for electrons
+
Requiring X > 0.6 will give you more than 90% efficiency for electrons.
  
  
-alg 3 use the NeuralNet and use as inputs the same variables used for
+
'''3.'''
likelihood. To use it in AOD you should proceed as follow:
+
The NeuralNet variable uses as inputs the same variables used for likelihood. To use it in AOD you should proceed as follow:
  
 +
<code>
 
ElecepiNN = elec*->parameter(ElectronParameters::epiNN);
 
ElecepiNN = elec*->parameter(ElectronParameters::epiNN);
 +
</code>
  
 
Requiring ElecepiNN > 0.6 will give you about 90% eff for electrons.  
 
Requiring ElecepiNN > 0.6 will give you about 90% eff for electrons.  
  
However, you should be aware that the ANN was trained in full eta range
+
However, you should be aware that the NN was trained in full eta range while the likelihood was computed in 3 bins in eta: barrel, crack and endcap. So I would suggest to use likelihood for now.
while the likelihood was computed in 3 bins in eta: barrel, crack and
 
endcup. So I would suggest to use likelihood for now. I am working on
 
improving things but it will not be ready for Rome. For sure using
 
likelihood will give you 90% eff for electrons with a good jet rejection.
 
  
 
== Muon ==
 
== Muon ==

Revision as of 10:00, 19 May 2005

This page contains basic prescriptions to get physics objects from the AOD and the AOD-based Root ntuple.

Some comments on quality selection cuts will be added as work progresses.


Electron

There are 3 types of quality cuts you can perform on the electron candidates:

  1. Cuts based on the isEM flag
  2. Cuts based on likelihood
  3. Cuts based on NeuralNet output

1. The isEM flag uses both calorimeter and tracking information in addition to TRT information. The flag is a bit field which marks whether the candidate passed or not some safety checks.

The bit field marks the following checks:

  Cluster based egamma
  ClusterEtaRange        =  0,
  ClusterHadronicLeakage =  1,
  ClusterMiddleSampling  =  2,
  ClusterFirstSampling   =  3,
  Track based egamma
  TrackEtaRange          =  8,
  TrackHitsA0            =  9,
  TrackMatchAndEoP       = 10,
  TrackTRT               = 11

In 9.0.4 there is a problem with TRT simulation so one has to mask TRT bit to recover the lost efficiency.

To get the flag in your AOD analysis you should use:

(*elec)->isEM()

To mask the TRT bits you should use: (*elec)->isEM()&0x7FF==0

If you use isEM then you will select electrons with an overall efficiency of about 80% in the barrel but much lower in the crack and endcap.

2. The likelihood ratio is constructed using the following variables: energy in different calorimeter samplings, shower shapes in both eta and phi and E/P ration. No TRT information is used here. You need to access two variables called emweight and pionweight then you can construct the likelihood ratio, defined by: emweight/(emweight+pionweight). Emweight is the product of pdf's

In AOD, you use the following code:

ElecEMWeight = elec*->parameter(ElectronParameters::emWeight); ElecPiWeight = elec*->parameter(ElectronParameters::pionWeight);

Then form the variable: X = ElecEMWeight/(ElecEMWeight+ElecPiWeight);

Requiring X > 0.6 will give you more than 90% efficiency for electrons.


3. The NeuralNet variable uses as inputs the same variables used for likelihood. To use it in AOD you should proceed as follow:

ElecepiNN = elec*->parameter(ElectronParameters::epiNN);

Requiring ElecepiNN > 0.6 will give you about 90% eff for electrons.

However, you should be aware that the NN was trained in full eta range while the likelihood was computed in 3 bins in eta: barrel, crack and endcap. So I would suggest to use likelihood for now.

Muon

Tau

Jet

BJet

Missing Et

External References

Container/Object Names for AOD Particle Preselection Cuts