Add temporal OOM backoff for latent upscale

This commit is contained in:
2026-09-04 06:54:35 +00:00
parent a0d80bcc47
commit 04a61af874
2 changed files with 67 additions and 1 deletions
+12
View File
@@ -1184,6 +1184,18 @@ class DumasH3LongVideosHelperTests(unittest.TestCase):
bounds = latent._temporal_segments(124, 85, 17)
self.assertEqual(bounds, [(0, 85), (68, 124)])
def test_shrink_temporal_param_reduces_chunk_length(self):
latent = importlib.import_module("dumas_h3_latent_upscale")
smaller = latent._shrink_temporal_param({
"chunk_length": 85,
"temporal_overlap": 17,
})
self.assertIsNotNone(smaller)
self.assertLess(smaller["chunk_length"], 85)
self.assertLess(smaller["temporal_overlap"], 85)
self.assertEqual(smaller["chunk_length"] % 17, 0)
self.assertEqual(smaller["temporal_overlap"] % 17, 0)
def test_compose_persistent_does_not_expand_ambiguous_plural_to_full_cast(self):
active = self.module.parse_wardrobe(
"Maya = she, red jacket\n"