Set right values to reproduce tests
@@ -109,7 +109,7 @@ def config_analysis_data():
frozen: false
name: amplitude
unit: cm-2 s-1 TeV-1
- value: 5.0e-11
+ value: 1.0e-11
- factor: 1.0
frozen: true
name: reference
@@ -130,27 +130,13 @@ def config_analysis_data():
- 22.014 deg
frame: icrs
radius: 0.11 deg
- containment_correction: true
+ containment_correction: false
data_reducer: 1d
- geometry:
- axes:
- e_reco:
- lo_bnd: 0.01
- hi_bnd: 100
- nbin: 73
- unit: TeV
- interp: log
- e_true:
- lo_bnd: 0.01
- hi_bnd: 315
- nbin: 109
- unit: TeV
- interp: log
flux:
fp_binning:
lo_bnd: 1
- hi_bnd: 10
- nbin: 11
+ hi_bnd: 50
+ nbin: 4
unit: TeV
interp: log
"""
@@ -166,12 +152,12 @@ def test_analysis(config_analysis_data):
analysis.fit()
analysis.get_flux_points()
assert len(analysis.extraction.spectrum_observations) == 2
- assert_allclose(analysis.fit_result.total_stat, 74.4244, rtol=1e-2)
- assert len(analysis.flux_points_dataset.data.table) == 11
+ assert_allclose(analysis.fit_result.total_stat, 79.8849, rtol=1e-2)
+ assert len(analysis.flux_points_dataset.data.table) == 4
dnde = analysis.flux_points_dataset.data.table["dnde"].quantity
assert dnde.unit == "cm-2 s-1 TeV-1"
- assert_allclose(dnde[0].value, 2.0443e-11, rtol=1e-2)
- assert_allclose(dnde[-1].value, 5.4386e-14, rtol=1e-2)
+ assert_allclose(dnde[0].value, 6.601518e-12, rtol=1e-2)
+ assert_allclose(dnde[-1].value, 1.295918e-15, rtol=1e-2)
def test_validate_astropy_quantities():
