Forráskód Böngészése

Fixes to june6 presentation

Caleb Fangmeier 5 éve
szülő
commit
0e26ef6219

BIN
docs/presentations/2018_06_20/figures/eff_table.png


BIN
docs/presentations/2018_06_20/main.pdf


+ 15 - 10
docs/presentations/2018_06_20/main.tex

@@ -227,25 +227,30 @@
 
 \begin{frame}{Overall Performance}
   \begin{center}
-    Integrating over all tracks with $p_T>20$GeV and $\eta<2.4$ yields the performance numbers below.
+    Integrating over all tracks with $p_T>20$GeV and $|\eta|<2.5$ yields the performance numbers below.
     \begin{figure}
       % Number of Electron Seeds Per Event
       \includegraphics[width=0.6\textwidth]{figures/eff_table.png}
     \end{figure}
-\begin{itemize}
-    \item The HLT default settings (\texttt{narrow}) of the new pixel matching
-      scheme yield non-trivially better purity at the loss of some efficiency
-      with respect to both the old seeding and the \texttt{wide} working point.
-    \item The \texttt{wide} working point of the new seeding matches the
-      \texttt{old-seeding} within errors except for purity is $\approx 2$\%
-      better in the $t\bar{t}$ sample
-\end{itemize}
+    \begin{itemize}
+      \item The HLT default settings (\texttt{new-default}) of the new pixel matching
+          scheme yield non-trivially better purity at the loss of some efficiency
+          with respect to both the old seeding and the \texttt{wide} working point.
+      \item The \texttt{wide} working point of the new seeding matches the
+          \texttt{old-seeding} within errors except for purity is $\approx 2$\%
+          better in the $t\bar{t}$ sample
+      \item Most likely better to choose the \texttt{wide} working point over the \texttt{default} one to get the gain in efficiency, and count on subsequent filters to compensate for the worse purity and fake rate.
+    \end{itemize}
   \end{center}
 \end{frame}
 
+% ask for conclusion to project and find out
+% - what changes need to be made
+% - who is going to implement them
+
 \begin{frame}{Conclusions \& Outlook}
   \begin{itemize}
-    \item The new seeding algorithm has been optimized to have better or comparable performance to the current Offline seeding method in all investigated metrics including
+    \item The new seeding algorithm has been optimized to have better or comparable performance to the current Offline seeding method(\texttt{old-default}) in all investigated metrics including
       \begin{itemize}
         \item GSF Tracking Efficiency
         \item GSF Tracking Purity

+ 27 - 21
plotting/eff_plots.py

@@ -281,21 +281,26 @@ def plot_roc_curve(pfx, ext=''):
         den = Hist1D(sample[f'{basename}_den'])
         return hist_integral_ratio(num, den)
     rows = []
-    for (proc, wp), sample in samples.items():
-        sample_name = f'{proc}-{wp}'
-        eff, eff_err = get_num_den(sample, f'{pfx}_eff_v_phi{ext}')
-        pur, pur_err = get_num_den(sample, f'{pfx}_pur_v_phi{ext}')
-        if show_fr:
-            fr, fr_err = get_num_den(sample, f'fake_rate_v_phi')
-
-            rows.append([wp,
-                         rf'${eff*100:0.2f}\pm{eff_err*100:0.2f}\%$',
-                         rf'${pur*100:0.2f}\pm{pur_err*100:0.2f}\%$',
-                         rf'${fr*100:0.2f}\pm{fr_err*100:0.2f}\%$'])
-
-        plt.errorbar([pur], [eff], xerr=[pur_err], yerr=[eff_err],
-                     label=sample_name, marker='o', color=color(proc, wp))
-    center_text(0.3, 0.3, r'$p_T>20$ and $|\eta|<2.4$')
+    row_labels = []
+    for proc in procs:
+        row_labels.append(procs[proc])
+        row_labels.extend(['']*(len(wps)-1))
+        for wp in wps:
+            sample = samples[(proc, wp)]
+            sample_name = f'{proc}-{wp}'
+            eff, eff_err = get_num_den(sample, f'{pfx}_eff_v_phi{ext}')
+            pur, pur_err = get_num_den(sample, f'{pfx}_pur_v_phi{ext}')
+            if show_fr:
+                fr, fr_err = get_num_den(sample, f'fake_rate_no_e_match_v_phi')
+
+                rows.append([wp,
+                             rf'${eff*100:0.2f}\pm{eff_err*100:0.2f}\%$',
+                             rf'${pur*100:0.2f}\pm{pur_err*100:0.2f}\%$',
+                             rf'${fr*100:0.2f}\pm{fr_err*100:0.2f}\%$'])
+
+            plt.errorbar([pur], [eff], xerr=[pur_err], yerr=[eff_err],
+                         label=sample_name, marker='o', color=color(proc, wp))
+    center_text(0.3, 0.3, r'$p_T>20$ and $|\eta|<2.5$')
     plt.axis('equal')
     plt.xlim((0.5, 1.02))
     plt.ylim((0.5, 1.02))
@@ -307,7 +312,6 @@ def plot_roc_curve(pfx, ext=''):
     col_labels = ['Sample', 'Working Point', 'Efficiency', 'Purity']
     if show_fr:
         col_labels.append("Fake Rate")
-    row_labels = [r'$Z \rightarrow ee$', '', '', r'$t\bar{t}$', '', '']
     return to_html_table(rows, col_labels, row_labels, 'table-condensed')
 
 
@@ -360,12 +364,13 @@ def plot_kinematic_eff(pref, ext='', ylim=(None, None), norm=None, label_pfx='',
     plt.xlim(xlim_eta)
 
     plt.sca(ax_phi)
-    if not incl_sel: center_text(0.5, 0.15, r'$p_T>20$ and $|\eta|<2.4$')
+    if not incl_sel: center_text(0.5, 0.15, r'$p_T>20$ and $|\eta|<2.5$')
     plt.xlabel(fr"{label_pfx} $\phi$")
     plt.ylim(ylim)
     plt.xlim(xlim_phi)
     plt.tight_layout()
-    plt.legend(loc='upper left', bbox_to_anchor=(0.6, 0.45), bbox_transform=plt.gcf().transFigure)
+    plt.legend(loc='upper left', bbox_to_anchor=(0.6, 0.45), bbox_transform=plt.gcf().transFigure,
+               prop={'size': 20})
 
 
 @mpb.decl_fig
@@ -539,6 +544,7 @@ def all_cut_plots(refresh=True, publish=False):
                             dict(norm=1, ylim=(0, None), xlim_pt=(0, 5), bins_eta=30, bins_phi=30)),
     }
 
+
     def add_num_den(key, func, args, kwargs):
         base_ext = kwargs.get('ext', '')
         bins_pt_ = [0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100, 150, 200, 300]
@@ -574,7 +580,7 @@ def all_cut_plots(refresh=True, publish=False):
     add_num_den('partial_fake_rate_incl', plot_kinematic_eff, ('partial_fake_rate_incl',), {})
     add_num_den('full_fake_rate_incl', plot_kinematic_eff, ('full_fake_rate_incl',), {})
     add_num_den('clean_fake_rate_incl', plot_kinematic_eff, ('clean_fake_rate_incl',), {})
-    #
+
     add_num_den('fake_rate', plot_kinematic_eff, ('fake_rate',), dict(incl_sel=False))
     add_num_den('fake_rate_no_e_match', plot_kinematic_eff, ('fake_rate_no_e_match',), dict(incl_sel=False))
     add_num_den('partial_fake_rate', plot_kinematic_eff, ('partial_fake_rate',), dict(incl_sel=False))
@@ -641,7 +647,7 @@ if __name__ == '__main__':
                   publish_url="eg.fangmeier.tech/",
                   )
     procs = {
-        'zee': r'$Z\rightarrow e^+e_-}$',
+        'zee': r'$Z\rightarrow e^+e^-$',
         'tt': r'$t\bar{t}$'
     }
     wps = {
@@ -649,4 +655,4 @@ if __name__ == '__main__':
         'new-wide': 'Wide Settings',
         'old-default': 'Old Seeding',
     }
-    all_cut_plots(refresh=True, publish=True)
+    all_cut_plots(refresh=True, publish=False)