diff options
| author | tanaka takashi <isazaka@gmail.com> | 2026-09-13 22:02:44 +0900 |
|---|---|---|
| committer | tanaka takashi <isazaka@gmail.com> | 2026-09-13 22:02:44 +0900 |
| commit | 213e738140859dbcc12c2540ce40d6b6d2875aa7 (patch) | |
| tree | 93443693ffbfbfb8706e1eea2f857d677d62cb4a /tests | |
| parent | de44625e3baae4d43ad096248b7096578b11e0b0 (diff) | |
ddim timestep_spacingをtrailingに強制するモードを追加
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/test_config.py | 11 | ||||
| -rw-r--r-- | tests/test_pipeline_factory.py | 1 |
2 files changed, 12 insertions, 0 deletions
diff --git a/tests/test_config.py b/tests/test_config.py index 5d339f8..0e34086 100644 --- a/tests/test_config.py +++ b/tests/test_config.py @@ -282,6 +282,17 @@ def test_generation_defaults_clip_skip_and_pad_last_block(tmp_path: Path) -> Non assert config.generation.pad_last_block is False +def test_generation_accepts_ddim_trailing_scheduler(tmp_path: Path) -> None: + path = tmp_path / "config.toml" + path.write_text( + f'[model]\nroot = "{tmp_path.as_posix()}"\ncheckpoint = "base.safetensors"\n' + '[generation]\nscheduler = "ddim_trailing"\n', + encoding="utf-8", + ) + config = load_config(path, validate_paths=False) + assert config.generation.scheduler == "ddim_trailing" + + def test_generation_reads_clip_skip_and_pad_last_block(tmp_path: Path) -> None: path = tmp_path / "config.toml" path.write_text( diff --git a/tests/test_pipeline_factory.py b/tests/test_pipeline_factory.py index 14b771b..e7904ab 100644 --- a/tests/test_pipeline_factory.py +++ b/tests/test_pipeline_factory.py @@ -142,6 +142,7 @@ def test_checkpoint_without_vae_fails_pipeline_initialization(app_config, monkey ), ("euler_a", "FakeEulerAncestralDiscreteScheduler", {}), ("ddim", "FakeDDIMScheduler", {}), + ("ddim_trailing", "FakeDDIMScheduler", {"timestep_spacing": "trailing"}), ("lcm", "FakeLCMScheduler", {}), ], ) |
