Merge 945a8aa9632a33b05d50f6a00242a3193e737036 into 33aa808713f7c36cd9476c53b8b67c745e9bc107

This commit is contained in:
asagi4 2025-12-23 18:03:00 +08:00 committed by GitHub
commit 76299af7bc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -367,6 +367,8 @@ def apply_control(h, control, name):
ctrl = control[name].pop()
if ctrl is not None:
try:
if ctrl.shape[2] != h.shape[2] or ctrl.shape[3] != h.shape[3]:
ctrl = F.interpolate(ctrl.float(), size=(h.shape[2], h.shape[3]), mode="bicubic", align_corners=False).to(h.dtype)
h += ctrl
except:
logging.warning("warning control could not be applied {} {}".format(h.shape, ctrl.shape))