Unverified Commit 5c7ab90a authored by LipeCarmel's avatar LipeCarmel Committed by GitHub
Browse files

loopback.py Colab compatibility and bug fix

This code (suggested by @abvgdeabvgde2 ) literally does the same thing and it does not break with Python 3.9, making it helpful for Google Colab users (me included).
fixes #8927
Also a partial fix for #8902 but it does not resolve the unresponsive UI problem faced by @Archon332
parent 91ae48fd
Loading
Loading
Loading
Loading
+6 −9
Original line number Diff line number Diff line
@@ -54,14 +54,11 @@ class Script(scripts.Script):
                return strength

            progress = loop / (loops - 1)
            match denoising_curve:
                case "Aggressive":
            if denoising_curve == "Aggressive":
                strength = math.sin((progress) * math.pi * 0.5)

                case "Lazy":
            elif denoising_curve == "Lazy":
                strength = 1 - math.cos((progress) * math.pi * 0.5)

                case _:
            else:
                strength = progress

            change = (final_denoising_strength - initial_denoising_strength) * strength