Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Alternative image parametrization based on gaussian fitting #2270

Open
clara-escanuela opened this issue Mar 1, 2023 · 6 comments · May be fixed by #2275
Open

Alternative image parametrization based on gaussian fitting #2270

clara-escanuela opened this issue Mar 1, 2023 · 6 comments · May be fixed by #2275

Comments

@clara-escanuela
Copy link
Contributor

The goal of this implementation would be to improve the angular resolution by introducing a image-fitting algorithm. An alternative image parametrization method is presented.

Using a chi-squared minimization, we want to fit a 2D function to the image with the Hillas parameters as seeds. The function could be a 2D Gaussian, a 2D skewed Gaussian (to model the shower tail) or a skewed Gaussian in the longitudinal direction and a Cauchy function in the transverse direction.

Image-fitting algorithms have been proven to be successful before (https://arxiv.org/pdf/1211.0254.pdf). Nevertheless, I am unsure on how to proceed with the implementation. Some advice is welcome.

@clara-escanuela
Copy link
Contributor Author

I would say that as a first step, I could create a new py file in ctapipe.image which takes the hillas parameters and do the fit.

@maxnoe
Copy link
Member

maxnoe commented Mar 1, 2023

Hi @clara-escanuela,

I think this is a valuable method to have in ctapipe itself, if only to evaluate how it might improve analysis of truncated showers etc.

You can take a look at how e.g. the MuonIntensityFitter is implemented.

I think the best solution would be to:

This might need some improvements to the toymodels, e.g. a method that actually directly corresponds to a iminuit loss function.

I'd add a new Component that has the API __call__(self, event: ArrayEventContainer)
that gets the hillas parameters from the event, maybe with a QualityQuery.

That could e.g. be used to only run this on showers with non-zero leakage to increase performance.

@kosack
Copy link
Contributor

kosack commented Mar 1, 2023

Also , you might check with the group in Marseille (CPPM), as I think they implemented exactly this already (they showed sensitivity curves produced with protopipe at multiple ASWG meetings, so the implementation must be ctapipe-compatible). Maybe the code was not in a clean enough state to commit it though?

@clara-escanuela
Copy link
Contributor Author

Who, in that group, should I talk to? Could you give me a name?

@HealthyPear
Copy link
Member

@clara-escanuela the person you want to talk with is @gaia-verna .

@gaia-verna
Copy link

Also , you might check with the group in Marseille (CPPM), as I think they implemented exactly this already (they showed sensitivity curves produced with protopipe at multiple ASWG meetings, so the implementation must be ctapipe-compatible). Maybe the code was not in a clean enough state to commit it though?

Yes, the code was not clean and not general enough to be added in ctapipe.

Compared to the @clara-escanuela implementation there were the following main differences, I used:

  • chisquare
  • a simple 2D symmetric Gaussian model
    and the fit was applied just to "truncated" images in protopipe (namely, with cog beyond 80% of the camera radius).

I can add some comments and suggestions on the pull request anyhow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants