Use the VI scalars #192
All Vouch review confidence checks passed
Residual risk 0.21 = Change Risk (0.39) × (1 − Review Confidence (0.47)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.39 · 263 lines diff across 3 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Shallow Review Depth
shallow_review_depth
0.344
Diff Size
diff_size
0.334
Real PR Conversation Timeline
1 comments
"Review active on #192"
general
weight: 0.35
kshyatt
OK this is a very rough attempt to see how much the VI
Scalarcan buy us. The short story is we cut the number of forced synchronizations a lot at the cost of more kernel launches (for things like-α). One option to fix that would be to add some VI functions forsub(!!).I also added some allocating spots to avoid synchronization for every single iteration of
(re)orthogonalize.Here's a summary of how this branch affects the sync counts and kernel launch counts:
eigsolveon CuArray linear operators, profiled with CUPTI (CUDA.@profile).CuMatrix(n = 1024, 4096) and a matrix-free stencil (n = 10⁴, 10⁵, 10⁶).krylovdim = 30,howmany = 4,maxiter = 4,tol = 1e-14. Lanczos targets:SR, Arnoldi:LR.- "Copies to host" is the number of
cuMemcpyDtoHcalls. It is the reliable metric.- "Syncs" counts
cuCtx/Stream/EventSynchronizecalls. It varies slightly between runs because CUDA.jl sometimes waits on the same event twice.- "Kernels" is the number of device kernel launches.
| Solver | Orth | Syncs main → branch | Copies to host main → branch | Change | Kernels main → branch |
|---|---|---|---|---|---|
| Lanczos | MGS2 | 24,324 → 2,189 | 22,230 → 1,995 | 11.1× fewer | 97,140 → 120,390 (+24%) |
| Lanczos | CGS2 | 24,591 → 23,217 | 22,230 → 22,185 | ≈ same | 97,140 → 100,200 (+3%) |
| Lanczos | CGSIR | 14,683 → 14,354 | 12,911 → 13,886 | +7.6% | 68,712 → 73,704 (+7%) |
| Arnoldi | MGS2 | 47,893 → 3,647 | 41,741 → 2,994 | 13.9× fewer | 154,535 → 235,991 (+53%) |
| Arnoldi | CGS2 | 45,069 → 44,256 | 41,741 → 41,696 | ≈ same | 154,535 → 154,655 (+0%) |
| Arnoldi | CGSIR | 27,646 → 24,893 | 24,306 → 23,323 | 4% fewer | 100,235 → 101,367 (+1%) |
We don't see much change for the CGS methods because I haven't addressed
project!!yet. Will try that next. The changes in https://github.com/Jutho/KrylovKit.jl/pull/180 should also help a lot withproject!!.