Skip to content

[ML] Fix BatchLoader::CreateTrainingBatches resetting wrong secondary buffer#21496

Open
siliataider wants to merge 1 commit intoroot-project:v6-38-00-patchesfrom
siliataider:v6-38-00-patches-my-bp
Open

[ML] Fix BatchLoader::CreateTrainingBatches resetting wrong secondary buffer#21496
siliataider wants to merge 1 commit intoroot-project:v6-38-00-patchesfrom
siliataider:v6-38-00-patches-my-bp

Conversation

@siliataider
Copy link
Contributor

This Pull request:

Changes or fixes:

test14_big_data in rbatchgenerator_completeness was sporadically failing across multiple platforms with different errors depending on which random parameters were drawn (for entries_in_rdf, chunk_size and batch_size):

  • wrong batch shape at the remainder batch
  • missing entries

Both failures are caused by a small bug in RBatchLoader::CreateTrainingBatches, which, if we had a overflow in fPrimaryLeftoverTrainingBatch, was correctly promoting fSecondaryLeftoverTrainingBatch to primary but incorrectly resetting fSecondaryLeftoverValidationBatch afterwards (instead of fSecondaryLeftoverTrainingBatch), meaning that the training secondary leftover buffer was never cleared and with certain random combinations of parameters would cause issues.

We don't see this in master because the RBatchLoader was refactored in #20998

Checklist:

  • tested changes locally

@siliataider siliataider requested a review from lmoneta as a code owner March 4, 2026 16:34
@siliataider siliataider requested review from dpiparo, guitargeek and vepadulano and removed request for lmoneta March 4, 2026 16:34
@siliataider siliataider self-assigned this Mar 4, 2026
@siliataider siliataider added the in:ML Everything under ROOT/ML label Mar 4, 2026
@github-actions
Copy link

github-actions bot commented Mar 4, 2026

Test Results

    19 files      19 suites   2d 20h 25m 54s ⏱️
 3 713 tests  3 713 ✅ 0 💤 0 ❌
68 832 runs  68 832 ✅ 0 💤 0 ❌

Results for commit 2a239f0.

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

Labels

in:ML Everything under ROOT/ML

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants