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

Implement an algorithm for photon/pi0 discrimination based on input features and a trained model in ONNX format #85

Merged

Conversation

giovannimarchiori
Copy link
Contributor

@giovannimarchiori giovannimarchiori commented Jun 24, 2024

The code in this PR provides a Gaudi algorithm that

  • reads the list of input features from a JSON file and the trained BDT model from an ONNX file
  • for each cluster, reads the input features from the shapeParameters vector (if available), runs the inference, and saves the photon probability as an additional shape parameter of the new output cluster collection
    It works with ONNX files created with either XGBoost and LightGBM (tested with both).
    Could probably work also with different models based on features (DNN..)

Uses as inputs the shower shapes calculated in #79

@giovannimarchiori
Copy link
Contributor Author

Just rebased..

@giovannimarchiori
Copy link
Contributor Author

Hi @kjvbrt , I implemented the handling of exceptions in reading the JSON and rebased - is there anything left for me to do?

Thx, Giovanni

@kjvbrt
Copy link
Contributor

kjvbrt commented Jul 2, 2024

Hi @giovannimarchiori, nice :)
Merging...

@kjvbrt kjvbrt merged commit c3497de into HEP-FCC:main Jul 2, 2024
2 of 5 checks passed
@giovannimarchiori giovannimarchiori deleted the gmarchio-main-20240621-PhotonIDTool branch July 30, 2024 12:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants