Skip to content

Conversation

@Red-Portal
Copy link
Member

@Red-Portal Red-Portal commented Nov 14, 2025

The objectives used in variational inference are sometimes minimized or maximized, which can be confusing. For instance the KL divergence is supposed to minimized, but the ELBO is usually maximized. Allowing this to vary on an algorithm-to-algorithm basis doesn't make a lot of sense. Therefore, this PR enforces the convention that all objective values (that are only accessible by calling estimate_objective) are expected to be minimized. For instance, for ELBO maximization algorithms, estimate_objective will return the negative ELBO.

Red-Portal and others added 8 commits November 14, 2025 15:44
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@github-actions
Copy link
Contributor

AdvancedVI.jl documentation for PR #215 is available at:
https://TuringLang.github.io/AdvancedVI.jl/previews/PR215/

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Benchmark Results

Benchmark suite Current: b14bb9f Previous: 51a0b3f Ratio
normal/RepGradELBO + STL/meanfield/Zygote 3920438191 ns 4042091118.5 ns 0.97
normal/RepGradELBO + STL/meanfield/ReverseDiff 1137314480 ns 1148698006 ns 0.99
normal/RepGradELBO + STL/meanfield/Mooncake 1248798164 ns 1252557751 ns 1.00
normal/RepGradELBO + STL/fullrank/Zygote 3888598013 ns 3995457850.5 ns 0.97
normal/RepGradELBO + STL/fullrank/ReverseDiff 1660774838 ns 1679345707 ns 0.99
normal/RepGradELBO + STL/fullrank/Mooncake 1250085352 ns 1280789300.5 ns 0.98
normal/RepGradELBO/meanfield/Zygote 2775544305.5 ns 2838937181.5 ns 0.98
normal/RepGradELBO/meanfield/ReverseDiff 780909736 ns 793764611 ns 0.98
normal/RepGradELBO/meanfield/Mooncake 1086150808 ns 1119822194 ns 0.97
normal/RepGradELBO/fullrank/Zygote 2770044101 ns 2877874051 ns 0.96
normal/RepGradELBO/fullrank/ReverseDiff 973336667 ns 978741132 ns 0.99
normal/RepGradELBO/fullrank/Mooncake 1113137202 ns 1154813432 ns 0.96
normal + bijector/RepGradELBO + STL/meanfield/Zygote 5583939500 ns 5705945858 ns 0.98
normal + bijector/RepGradELBO + STL/meanfield/ReverseDiff 2408835091 ns 2387917982 ns 1.01
normal + bijector/RepGradELBO + STL/meanfield/Mooncake 4158213745.5 ns 4145579318 ns 1.00
normal + bijector/RepGradELBO + STL/fullrank/Zygote 5577515624 ns 5711272499 ns 0.98
normal + bijector/RepGradELBO + STL/fullrank/ReverseDiff 3063136975 ns 3111756066.5 ns 0.98
normal + bijector/RepGradELBO + STL/fullrank/Mooncake 4187254056 ns 4302876428 ns 0.97
normal + bijector/RepGradELBO/meanfield/Zygote 4312418628 ns 4394508316 ns 0.98
normal + bijector/RepGradELBO/meanfield/ReverseDiff 2049108141 ns 2027700486 ns 1.01
normal + bijector/RepGradELBO/meanfield/Mooncake 3927457037.5 ns 4040389415.5 ns 0.97
normal + bijector/RepGradELBO/fullrank/Zygote 4322323571 ns 4492494518.5 ns 0.96
normal + bijector/RepGradELBO/fullrank/ReverseDiff 2294744589 ns 2314373240 ns 0.99
normal + bijector/RepGradELBO/fullrank/Mooncake 4054198058 ns 4147670105 ns 0.98

This comment was automatically generated by workflow using github-action-benchmark.

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