Fix incorrect Resampling enum

This commit is contained in:
awsr
2026-05-13 20:42:05 -07:00
parent 82886ba9a3
commit 111b36a949
+1 -1
View File
@@ -1687,7 +1687,7 @@ def preprocess_image(image: Image.Image):
image = image.convert("RGB")
w, h = image.size
w, h = (x - x % 32 for x in (w, h))
image = image.resize((w, h), resample=Image.LANCZOS)
image = image.resize((w, h), resample=Image.Resampling.LANCZOS)
image = np.array(image).astype(np.float32) / 255.0
image = image[None].transpose(0, 3, 1, 2)
image = torch.from_numpy(image)