cositools / cosipy

The COSI high-level data analysis tools
Apache License 2.0
4 stars 19 forks source link

The issue in the circular test #244

Open Yong2Sheng opened 1 month ago

Yong2Sheng commented 1 month ago

This is a reminder about the current issue with the spectral fitting.

  1. The fitting to the simulated Crab can't recover the input spectrum for simulation (see the tutorial notebook of the Crab spectral fitting).
  2. The circular test, fitting the injected Crab, also can't completely recover the spectrum used in source injection (see the graph below). image

    So, our current summary is that the response we used in DC2 is not smooth enough. The data binned in Em, Phi and PsiChi suffers from low statistics.

Maybe this can be verified when we have a more populated response.

Yong2Sheng commented 1 month ago

We also added a very small number 1e-12 to the likelihood to avoid expectation_bin == 0 while data_bin != 0, which might distort the total likelihood.

eneights commented 1 month ago

When this is solved, we will need to update the spectral fit unit test, which fits data generated by the source injector