Merge pull request #9407 from GoulartNogueira/master

Fix orientation bug on preprocess
This commit is contained in:
AUTOMATIC1111 2023-04-29 16:53:17 +03:00 committed by GitHub
commit 78b5bed374
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -161,7 +161,9 @@ def preprocess_work(process_src, process_dst, process_width, process_height, pre
params.subindex = 0
filename = os.path.join(src, imagefile)
try:
img = Image.open(filename).convert("RGB")
img = Image.open(filename)
img = ImageOps.exif_transpose(img)
img = img.convert("RGB")
except Exception:
continue