Skip to content

Statistics in Final VI batch not updated #4719

@waelbenamara

Description

@waelbenamara

Describe the bug

When using LDA with --minibatch > 1, the final partial batch is processed for learning but not counted in the reported statistics, causing an incorrect "number of examples" count.
Root Cause:
The update_stats_lda() function only updates statistics when batch_buffer.size() == minibatch, excluding the final partial batch

How to reproduce

./vw --lda 20 -d dataset.vw --minibatch 256 --passes 1

Version

9.10.0

OS

linux

Language

C++

Additional context

I have a fix ready should I PR?

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugBug in learning semantics, critical by default

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions