perf

Introduction

The DL2-to-DL3 step of the protopipe pipeline is now based on the pyirf library.

The protopipe.perf module contains utility tools used to interface with this library, mainly to translate the DL2 data in the internal nomenclature used by pyirf to produce the DL3 file.

In general this step takes care of

  • handling the determination of the best-cutoffs to separate gamma and the background (protons + electrons),

  • estimating the sensitivity from the optimized cuts,

  • producing the instrument response functions (IRFs).

Provided that a performance script makes used of protopipe.perf.utils.read_DL2_pyirf, protopipe supports the addition and testing of multiple scripts based on pyirf.

Note

Some functions are discontinued or will be with the next release and they will be removed.

The current approach is based on the EventDisplay historical pipeline for which the following main points apply,

  • minimum telescope multiplicity cut set to 3 (for 30’ and 100’’ exposures) and 4 (for 5h and 50h exposures),

  • maximum signal efficiency set to 80%,

  • optimisation cuts are performed following these steps, - applying a global cut of 40% signal efficiency, - energy-bin-wise 68% containment angular cuts optimization - energy-bin-wise optimisation of gamma/hadron separation cut for best sensitivity

For more details on the specific API and benchmarks, please check pyirf’s documentation.

Reference/API

protopipe.perf Package

Functions

angular_resolution(events, energy_bins[, …])

Calculate the angular resolution.

energy_bias_resolution(events, energy_bins)

Calculate bias and energy resolution.

load_obj(name)

Load object in binary

percentiles(values, bin_values, bin_edges, …)

plot_hist(ax, data, edges[, norm, yerr, …])

Utility function to plot histogram

read_DL2_pyirf(infile, run_header)

Read a DL2 HDF5 protopipe file and adapt them to pyirf format.

save_obj(obj, name)

Save object in binary

Variables

norm

A normal continuous random variable.