From f1a2fd98667713a4d291e8378ec359d8559442f7 Mon Sep 17 00:00:00 2001 From: Michael Cahill Date: Sat, 7 Mar 2026 18:32:23 -0800 Subject: [PATCH] ci(M01): add k_diffusion.sampling stubs (get_sigmas_*, torch) Made-with: Cursor --- scripts/dev/create_stub_repos.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/scripts/dev/create_stub_repos.py b/scripts/dev/create_stub_repos.py index 33b9b47fb..528159098 100644 --- a/scripts/dev/create_stub_repos.py +++ b/scripts/dev/create_stub_repos.py @@ -107,10 +107,18 @@ def main() -> None: "# stub\n", ) - # k-diffusion: k_diffusion.sampling + # k-diffusion: k_diffusion.sampling (sd_schedulers, sd_samplers_common) kd = "k-diffusion" touch(os.path.join(REPOS, kd, "k_diffusion", "__init__.py")) - touch(os.path.join(REPOS, kd, "k_diffusion", "sampling.py"), "# stub\n") + kd_sampling = ( + "import torch as _torch\n" + "torch = _torch\n" + "def get_sigmas_karras(*a, **k): pass\n" + "def get_sigmas_exponential(*a, **k): pass\n" + "def get_sigmas_polyexponential(*a, **k): pass\n" + "def to_d(*a, **k): pass\n" + ) + touch(os.path.join(REPOS, kd, "k_diffusion", "sampling.py"), kd_sampling) # BLIP: models/blip.py touch(os.path.join(REPOS, "BLIP", "models", "blip.py"), "# stub\n")