Unverified Commit bb21a4cb authored by AUTOMATIC1111's avatar AUTOMATIC1111 Committed by GitHub
Browse files

Merge pull request #3715 from shwang95/master

Fix error caused by EXIF transpose when using custom scripts
parents e6060a7e 5c864be0
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -81,6 +81,7 @@ def img2img(mode: int, prompt: str, negative_prompt: str, prompt_style: str, pro
        mask = None

    # Use the EXIF orientation of photos taken by smartphones.
    if image is not None:
        image = ImageOps.exif_transpose(image) 

    assert 0. <= denoising_strength <= 1., 'can only work with strength in [0.0, 1.0]'