SensitivityEstimator#
- class gammapy.estimators.SensitivityEstimator(spectral_model=None, n_sigma=5.0, gamma_min=10, bkg_syst_fraction=0.05)[source]#
Bases:
EstimatorEstimate sensitivity.
This class allows to determine for each reconstructed energy bin the flux associated to the number of gamma-ray events for which the significance is
n_sigma, and being larger thangamma_minandbkg_syspercent larger than the number of background events in the ON region.- Parameters:
- spectral_model
SpectralModel, optional Spectral model assumption. Default is power-law with spectral index of 2.
- n_sigmafloat, optional
Minimum significance. Default is 5.
- gamma_minfloat, optional
Minimum number of gamma-rays. Default is 10.
- bkg_syst_fractionfloat, optional
Fraction of background counts above which the number of gamma-rays is. Default is 0.05.
- spectral_model
Examples
For a usage example see Point source sensitivity tutorial.
Attributes Summary
Configuration parameters.
Methods Summary
copy()Copy estimator.
estimate_min_e2dnde(excess, dataset)Estimate dnde from a given minimum excess.
estimate_min_excess(dataset)Estimate minimum excess to reach the given significance.
run(dataset)Run the sensitivity estimation.
Attributes Documentation
- config_parameters#
Configuration parameters.
- selection_optional#
- tag = 'SensitivityEstimator'#
Methods Documentation
- copy()#
Copy estimator.
- estimate_min_e2dnde(excess, dataset)[source]#
Estimate dnde from a given minimum excess.
- Parameters:
- excess
RegionNDMap Minimal excess.
- dataset
SpectrumDataset Spectrum dataset.
- excess
- Returns:
- e2dnde
Quantity Minimal differential flux.
- e2dnde
- estimate_min_excess(dataset)[source]#
Estimate minimum excess to reach the given significance.
- Parameters:
- dataset
SpectrumDataset Spectrum dataset.
- dataset
- Returns:
- excess
RegionNDMap Minimal excess.
- excess