gaussian_sbi_recovery
Run a bounded Gaussian/Gaussian SBI proxy recovery that exercises F-NPSE score training, composition, and sampling.
- License 许可
- Apache-2.0
- 最近更新
- 2026-09-03
- Stars
- ★ 351
- Forks
- 27
01 前言 Front Matter
- name
- gaussian_sbi_recovery
- description
- Run a bounded Gaussian/Gaussian SBI proxy recovery that exercises F-NPSE score training, composition, and sampling.
02 资源文件 2
- 脚本scripts/recovery_harness.py15.0 KB
- 脚本tests/test_recovery_math.py470 B
03 SKILL.md 正文
Gaussian SBI Recovery Harness
Use this skill to produce executable soft-mode recovery evidence for Compositional Score Modeling for Simulation-Based Inference when the full paper benchmark suite or original implementation is unavailable. It targets the paper's Gaussian/Gaussian benchmark family because the posterior is analytic and the core mechanism can be verified cheaply.
Do not use this skill to claim full paper reproduction. It is a declared reduced/proxy recovery harness whose output must say so.
Inputs
- Attempt directory containing
module_plan.json. - Runtime handoff from
prepare-recovery-environment. - Generated skill root containing
denoising_score_training,factorized_score_composition, andannealed_langevin_sampler. - Small experiment controls: seed, dimension, observation count, sample count, and Langevin settings.
Outputs
recovery/logs/generated_data_item.json.recovery/logs/training_trace.json.recovery/logs/sampler_trace.json.recovery/logs/generated_skill_invocations.json.recovery/source_manifest.json.recovery/recovery_result.json.
Workflow
- Generate a Gaussian/Gaussian simulator item from a standard normal prior and diagonal Gaussian likelihood.
- Compute the analytic multi-observation posterior.
- Run a real denoising score optimizer step using the training skill.
- Build analytic single-observation posterior score terms for a calibrated proxy score predictor.
- Compose scores using the F-NPSE composition skill.
- Sample with the annealed Langevin skill.
- Compute squared MMD, posterior mean error, and a bounded higher-is-better proxy score.
- Write recovery artifacts and mechanism checks for the Distiller validators.
Validation
Run the harness and then run:
python /share/project/yuyang/workspace/Paper2Skills/Distiller/skills/recover-paper/scripts/validate_recovery_experiment.py <attempt_dir> --output <attempt_dir>/recovery/experiment_validation.json
The experiment is acceptable only when the gate reports ok: true and the analysis report accepts the declared proxy scope.
Limitations
The harness uses an analytic Gaussian score for the sampling path after running a reduced score-training step. This isolates the compositional mechanism and sampler under bounded runtime but does not reproduce the paper's neural network training scale, full noise schedule, or benchmark figures.
04 同仓库更多 Skills
passnet-triton-opt
Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.
passnet-solve
END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.
passnet-skill
PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.
passnet-pattern-fusion
Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.
passnet-orchestrate
Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.
passnet-feedback
Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).