Skip to content

Learning improvements / testing.#53

Draft
GernotMaier wants to merge 18 commits intomainfrom
residuals-overlearning
Draft

Learning improvements / testing.#53
GernotMaier wants to merge 18 commits intomainfrom
residuals-overlearning

Conversation

@GernotMaier
Copy link
Member

No description provided.

@GernotMaier GernotMaier self-assigned this Feb 20, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request implements residual learning for stereo reconstruction models and adds training evaluation capabilities. The core change shifts from predicting absolute direction/energy values to predicting residuals relative to DispBDT baseline predictions. This approach allows the XGBoost model to learn corrections to an existing baseline method rather than learning from scratch.

Changes:

  • Implements residual learning architecture: models now predict corrections to DispBDT predictions rather than absolute values
  • Adds target standardization during training to balance the contribution of direction (Xoff, Yoff) and energy features in multi-target learning
  • Adds plot_training_evaluation.py script to visualize training curves and assess model convergence
  • Updates hyperparameters: reduces learning rate, increases n_estimators, adds regularization, enables early stopping
  • Filters training data to remove events with invalid energy reconstruction (ErecS <= 0)

Reviewed changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated 10 comments.

Show a summary per file
File Description
src/eventdisplay_ml/scripts/train_xgb_stereo.py Updated docstring to explain residual learning approach
src/eventdisplay_ml/scripts/plot_training_evaluation.py New script to plot training/validation curves from saved models
src/eventdisplay_ml/models.py Implements residual learning, target standardization, inverse transformation in inference, adds eval_set to regression training, removes eval_set from classification training
src/eventdisplay_ml/hyper_parameters.py Updates hyperparameters for better regularization and early stopping
src/eventdisplay_ml/features.py Changes targets from absolute values to residuals
src/eventdisplay_ml/evaluate.py Updates evaluation to work with residual predictions and reconstruct absolute values
src/eventdisplay_ml/data_processing.py Adds residual computation logic, filters invalid energy events
pyproject.toml Adds new script entry point for training evaluation plotting
docs/changes/53.feature.md Documents the new features
.github/copilot-instructions.md Updates documentation to reflect residual learning architecture

GernotMaier and others added 2 commits February 20, 2026 14:40
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 11 out of 11 changed files in this pull request and generated 3 comments.

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