Repository navigation
Drop Turing/DynamicPPL support - #75
Merged
Merged
Conversation
DynamicPPL models only run on the CPU, which is the case ParallelMCMC is least suited for, and keeping the extension working is more maintenance than it is worth right now. Releases up to 0.2 keep it. Removes DynamicPPLExt and its tests, strips the Turing model from the logistic-regression DEER tests, and adds tests for LogDensityProblemsExt, which were previously only exercised through DynamicPPL. Closes #74
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## v3.0 #75 +/- ##
=======================================
Coverage ? 87.32%
=======================================
Files ? 7
Lines ? 1294
Branches ? 0
=======================================
Hits ? 1130
Misses ? 164
Partials ? 0 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
wsmoses
reviewed
Oct 13, 2026
| These wrappers are a workaround pending upstream Enzyme support for GPU matmul rules. Once that lands, plain `A * B` on `CuArray`s will work and the wrappers will be deprecated. | ||
|
|
||
| ### 3. Some Enzyme GPU gradients hit a `gc-transition` abort. Staging them as single ops is a workaround | ||
| ### 2. Some Enzyme GPU gradients hit a `gc-transition` abort. Staging them as single ops is a workaround |
wsmoses
reviewed
Oct 13, 2026
| To run on GPU, hand-write `logdensity` / `grad_logdensity` (and the batched variants) directly over `CuArray`s and pass them to `DensityModel`. This is shown in the example below. | ||
|
|
||
| ### 2. Enzyme on GPU currently needs `pmcmc_matmul` / `pmcmc_dot` / `pmcmc_dotsum` | ||
| ### 1. Enzyme on GPU currently needs `pmcmc_matmul` / `pmcmc_dot` / `pmcmc_dotsum` |
Owner
Author
There was a problem hiding this comment.
Yes--I'm behind on docs stuff. These comments will be removed in #71
- Reword the comment on the LogDensityProblems wrapper structs; their remaining dispatch use is the Reactant HVP check. Drop a comment that only restated code. - A plain backend in `hvp` works when `logdensity_and_gradient` is differentiable by it. Say that instead of calling plain backends unsupported, and keep `SecondOrder` as the fallback. - Put a runnable LogDensityProblems example in Getting Started and link it from the reference page. - Test that the batched slots pass through the LogDensityProblems constructor, that the default parameter name is `x`, and tighten the variance tolerance.
rsenne
added a commit
that referenced
this pull request
Oct 13, 2026
Turing support was removed in #75. Move the runnable LogDensityProblems example and HVP note into the models page.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #74.
DynamicPPL models only run on the CPU, so the extension doesn't fit what this package is for, and it's maintenance I can't keep up with. Releases up to 0.2 keep Turing support.
DynamicPPLExt, theDensityModel(::DynamicPPL.Model)constructor, and theDynamicPPLweak dep and compat entry.test-Turing-Integration.jlis gone.test-DEER-Turing-Logistic.jlbecomestest-DEER-Logistic.jland keeps the hand-written CPU/GPU checks.test-LogDensityProblems.jl.LogDensityProblemsExtwas previously only tested through DynamicPPL; it now runs against a hand-written target (constructor, posterior recovery,SecondOrderHVP withParallelMALASampler).LogDensityProblemsExtdocstring no longer mention Turing. The GPU limitations list drops its first entry and is renumbered.Distributionsfrom the test env, since only the Turing models used it.