Belle II Software  release-08-01-10
MCSideTrackingValidationModule Class Reference
Inheritance diagram for MCSideTrackingValidationModule:
Collaboration diagram for MCSideTrackingValidationModule:

Public Member Functions

def __init__ (self, name, contact, output_file_name=None, reco_tracks_name='RecoTracks', mc_reco_tracks_name='MCRecoTracks', expert_level=None)
 
def initialize (self)
 
def prepare (self)
 
def pick (self, mc_reco_track)
 
def peel (self, mc_reco_track)
 
def peel_mc_to_pr_match_info (self, mc_reco_track)
 
def peel_hit_efficiencies_in_all_pr_tracks (self, mc_reco_track)
 

Public Attributes

 reco_tracks_name
 Name of the StoreArray of the tracks from pattern recognition.
 
 mc_reco_tracks_name
 Name of the StoreArray of the ideal mc tracks.
 
 track_match_look_up
 Reference to the track match lookup object reading the relation information constructed by the MCMatcherTracksModule.
 
 found_det_hit_ids
 Set of all detector and hits ids contained in any pr track. More...
 
 matched_det_hit_ids
 Set of all detector and hits ids contained in matched pr tracks. More...
 
 clone_det_hit_ids
 Set of all detector and hits ids contained in clone pr tracks. More...
 
 fake_det_hit_ids
 Set of all detector and hits ids contained in background and ghost pr tracks. More...
 

Static Public Attributes

int default_expert_level = 10
 the threshold value for the expert level
 
 save_tree
 Save a tree of all collected variables in a sub folder. More...
 
 save_tree_basic
 Save a basic tree. More...
 
 save_overview_figures_of_merit
 Generate the average finding efficiencies and hit efficiencies. More...
 
 save_hit_efficiency_histogram
 Save a histogram of the hit efficiency. More...
 
dictionary renaming_select_for_finding_efficiency_profiles
 Rename the efficiency-profile quantities so that they display nicely in ROOT TLatex. More...
 
 save_finding_efficiency_profiles
 Make profile of finding efficiency. More...
 
 save_finding_efficiency_by_tan_lamba_profiles
 Make profile of finding efficiency versus tan(lambda) More...
 
 save_finding_efficiency_by_tan_lamba_in_pt_groups_profiles
 Make profiles of finding efficiency versus tan(lambda) grouped by transverse momentum. More...
 
dictionary renaming_select_for_hit_efficiency_profiles
 Rename the hit-profile quantities so that they display nicely in ROOT TLatex. More...
 
 save_hit_efficiency_profiles
 Make profile of hit efficiency. More...
 
 save_hit_efficiency_by_tan_lambda_profiles
 Make profile of finding efficiency versus tan(lambda) More...
 
 save_finding_efficiency_by_pt_profiles_groupbyCharge
 Charge dependent histograms Make profile of finding efficiency versus pt, tan(lambda) More...
 
 save_finding_efficiency_by_tan_lambda_profiles_groupbyCharge
 Charge dependent histograms Make profile of finding efficiency versus pt, tan(lambda) More...
 
 save_hit_efficiency_by_pt_profiles_groupbyCharge
 Charge dependent histograms Make profile of finding efficiency versus pt, tan(lambda) More...
 
 save_hit_efficiency_by_tan_lambda_profiles_groupbyCharge
 Charge dependent histograms Make profile of finding efficiency versus pt, tan(lambda) More...
 
 save_hit_efficiency_in_all_found_hist
 This creates a histogram for all MC track displaying the ratio of hits contained in any PR track Hence this is distinctly larger than the hit efficiency to the matched PR track Usefulness under discussion. More...
 
 save_missing_mc_tracks_hit_efficiency_in_all_found_hist
 This creates a histogram for each missing MC track displaying the ratio of hits contained in any PR tracks High values in this hit efficiencies means that the MC track is consumed by other PR tracks but no proper match could be established. More...
 

Detailed Description

Module to collect matching information about the found particles and to generate
   validation plots and figures of merit on the performance of track finding.
 Expert level behavior:
    expert_level = default_expert_level: all figures and plots from this module except tree entries
    expert_level > default_expert_level: everything including tree entries
    expert_level <= default_expert_level//2: only basic figures
    default_expert_level//2 < expert_level < default_expert_level: basic figures and basic tree entries

Definition at line 22 of file mc_side_module.py.

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self,
  name,
  contact,
  output_file_name = None,
  reco_tracks_name = 'RecoTracks',
  mc_reco_tracks_name = 'MCRecoTracks',
  expert_level = None 
)
Constructor

Definition at line 35 of file mc_side_module.py.

42  expert_level=None):
43  """Constructor"""
44 
45  output_file_name = output_file_name or name + 'TrackingValidation.root'
46 
47  super().__init__(foreach=mc_reco_tracks_name,
48  name=name,
49  output_file_name=output_file_name,
50  contact=contact,
51  expert_level=expert_level)
52 
53 
54  self.reco_tracks_name = reco_tracks_name
55 
56 
57  self.mc_reco_tracks_name = mc_reco_tracks_name
58 
59 
60  self.track_match_look_up = None
61 
62  if self.expert_level >= self.default_expert_level:
63 
64  self.found_det_hit_ids = set()
65 
66 
67  self.matched_det_hit_ids = set()
68 
69 
70  self.clone_det_hit_ids = set()
71 
72 
73  self.fake_det_hit_ids = set()
74 

Member Function Documentation

◆ initialize()

def initialize (   self)
Initialization signal at the start of the event processing

Definition at line 75 of file mc_side_module.py.

◆ peel()

def peel (   self,
  mc_reco_track 
)
Looks at the individual Monte Carlo tracks and store information about them

Definition at line 119 of file mc_side_module.py.

◆ peel_hit_efficiencies_in_all_pr_tracks()

def peel_hit_efficiencies_in_all_pr_tracks (   self,
  mc_reco_track 
)
Extracts hit efficiencies

Definition at line 195 of file mc_side_module.py.

◆ peel_mc_to_pr_match_info()

def peel_mc_to_pr_match_info (   self,
  mc_reco_track 
)
Extracts track-match information from the MCMatcherTracksModule results

Definition at line 181 of file mc_side_module.py.

◆ pick()

def pick (   self,
  mc_reco_track 
)
Pick every MCRecoTrack

Definition at line 115 of file mc_side_module.py.

◆ prepare()

def prepare (   self)
Collect some statistics about the pattern recognition tracks used for comparision to the MC tracks

Executed once at the start of each event.

Definition at line 80 of file mc_side_module.py.

Member Data Documentation

◆ clone_det_hit_ids

clone_det_hit_ids

Set of all detector and hits ids contained in clone pr tracks.

Updated each event.

Definition at line 70 of file mc_side_module.py.

◆ fake_det_hit_ids

fake_det_hit_ids

Set of all detector and hits ids contained in background and ghost pr tracks.

Updated each event.

Definition at line 73 of file mc_side_module.py.

◆ found_det_hit_ids

found_det_hit_ids

Set of all detector and hits ids contained in any pr track.

Updated each event.

Definition at line 64 of file mc_side_module.py.

◆ matched_det_hit_ids

matched_det_hit_ids

Set of all detector and hits ids contained in matched pr tracks.

Updated each event.

Definition at line 67 of file mc_side_module.py.

◆ renaming_select_for_finding_efficiency_profiles

dictionary renaming_select_for_finding_efficiency_profiles
static
Initial value:
= {
'is_matched': 'finding efficiency',
'd0_truth': 'd_{0}',
'pt_truth': 'p_{t}',
'multiplicity': 'multiplicity',
'phi0_truth': '#phi',
}

Rename the efficiency-profile quantities so that they display nicely in ROOT TLatex.

Definition at line 268 of file mc_side_module.py.

◆ renaming_select_for_hit_efficiency_profiles

dictionary renaming_select_for_hit_efficiency_profiles
static
Initial value:
= {
'hit_efficiency': 'hit efficiency',
'd0_truth': 'd_{0}',
'pt_truth': 'p_{t}',
'multiplicity': 'multiplicity',
'phi0_truth': '#phi',
}

Rename the hit-profile quantities so that they display nicely in ROOT TLatex.

Definition at line 323 of file mc_side_module.py.

◆ save_finding_efficiency_by_pt_profiles_groupbyCharge

save_finding_efficiency_by_pt_profiles_groupbyCharge
static
Initial value:
= refiners.save_profiles(
)

Charge dependent histograms Make profile of finding efficiency versus pt, tan(lambda)

Definition at line 361 of file mc_side_module.py.

◆ save_finding_efficiency_by_tan_lamba_in_pt_groups_profiles

save_finding_efficiency_by_tan_lamba_in_pt_groups_profiles
static
Initial value:
= refiners.save_profiles(
)

Make profiles of finding efficiency versus tan(lambda) grouped by transverse momentum.

Definition at line 305 of file mc_side_module.py.

◆ save_finding_efficiency_by_tan_lamba_profiles

save_finding_efficiency_by_tan_lamba_profiles
static
Initial value:
= refiners.save_profiles(
)

Make profile of finding efficiency versus tan(lambda)

Definition at line 289 of file mc_side_module.py.

◆ save_finding_efficiency_by_tan_lambda_profiles_groupbyCharge

save_finding_efficiency_by_tan_lambda_profiles_groupbyCharge
static
Initial value:
= refiners.save_profiles(
)

Charge dependent histograms Make profile of finding efficiency versus pt, tan(lambda)

Definition at line 378 of file mc_side_module.py.

◆ save_finding_efficiency_profiles

save_finding_efficiency_profiles
static
Initial value:
= refiners.save_profiles(
)

Make profile of finding efficiency.

Definition at line 277 of file mc_side_module.py.

◆ save_hit_efficiency_by_pt_profiles_groupbyCharge

save_hit_efficiency_by_pt_profiles_groupbyCharge
static
Initial value:
= refiners.save_profiles(
)

Charge dependent histograms Make profile of finding efficiency versus pt, tan(lambda)

Definition at line 396 of file mc_side_module.py.

◆ save_hit_efficiency_by_tan_lambda_profiles

save_hit_efficiency_by_tan_lambda_profiles
static
Initial value:
= refiners.save_profiles(
)

Make profile of finding efficiency versus tan(lambda)

Definition at line 344 of file mc_side_module.py.

◆ save_hit_efficiency_by_tan_lambda_profiles_groupbyCharge

save_hit_efficiency_by_tan_lambda_profiles_groupbyCharge
static
Initial value:
= refiners.save_profiles(
)

Charge dependent histograms Make profile of finding efficiency versus pt, tan(lambda)

Definition at line 413 of file mc_side_module.py.

◆ save_hit_efficiency_histogram

save_hit_efficiency_histogram
static
Initial value:
= refiners.save_histograms(
)

Save a histogram of the hit efficiency.

Definition at line 259 of file mc_side_module.py.

◆ save_hit_efficiency_in_all_found_hist

save_hit_efficiency_in_all_found_hist
static
Initial value:
= refiners.save_histograms(
)

This creates a histogram for all MC track displaying the ratio of hits contained in any PR track Hence this is distinctly larger than the hit efficiency to the matched PR track Usefulness under discussion.

Definition at line 432 of file mc_side_module.py.

◆ save_hit_efficiency_profiles

save_hit_efficiency_profiles
static
Initial value:
= refiners.save_profiles(
)

Make profile of hit efficiency.

Definition at line 332 of file mc_side_module.py.

◆ save_missing_mc_tracks_hit_efficiency_in_all_found_hist

save_missing_mc_tracks_hit_efficiency_in_all_found_hist
static
Initial value:
= refiners.save_histograms(
)

This creates a histogram for each missing MC track displaying the ratio of hits contained in any PR tracks High values in this hit efficiencies means that the MC track is consumed by other PR tracks but no proper match could be established.

Definition at line 442 of file mc_side_module.py.

◆ save_overview_figures_of_merit

save_overview_figures_of_merit
static
Initial value:
= refiners.save_fom(
)

Generate the average finding efficiencies and hit efficiencies.

Definition at line 241 of file mc_side_module.py.

◆ save_tree

save_tree
static
Initial value:
= refiners.save_tree(
# using cond to suppress false doxygen warnings
)

Save a tree of all collected variables in a sub folder.

Definition at line 222 of file mc_side_module.py.

◆ save_tree_basic

save_tree_basic
static
Initial value:
= refiners.save_tree(
# using cond to suppress false doxygen warnings
)

Save a basic tree.

Definition at line 231 of file mc_side_module.py.


The documentation for this class was generated from the following file: