Sign In

Smooth Generated Gifs - Guide

307
654
33
Type
Other
Stats
654
Reviews
Published
May 14, 2023
Base Model
SD 1.5
Hash
AutoV2
B8968EF90C
default creator card background decoration
Failed Generation Contest Participant
navimixu's Avatar
navimixu

This was a requested guide on how to generated smooth Gifs using SD-Auto1111, this is overall done in 3 big steps:

  1. Finding the right resources for the generation

  2. Processing the generated data into Gif

  3. post-Processing the Gif by applying interpolation (smoothing)

for this guide you'll need to download :

1. Finding the right resources

there two types of resources you can use leading to different types of animations:

  • Frames grid LoRAs, very precise on the subject its trained on but tend to be less flexible, the best person to making is type of resource is aDDont 🔞

  • Weight progressing concept LoRAs, while vary flexible it doesn't cover a wide range of motion, and its precision is bit jittery at times, , the best person to making is type of resource is ntc .

2. Processing into Gif

as we established before we're covering 2 types of animations [Frames Animation] and [Parameter Animation] .

Frames Animation 🎞 :

  1. for this you'll need to get a "Frames grid LoRA" and you'll the Img Slices To Gif script for cutting the generated result.

  2. start by using the LoRA in "txt2img" at full weight in the resolution mention by its creator.the result will look distorted so dont worry.

  3. then "send to img2img", and lower the LoRA to between 0.2-0.4, set the desnoising to between 0.28- 0.4

  4. now can add whatever additional LoRA you want, set the resolution as high as you want (but dont break the aspect ratio).

  5. now select the "Img Slices To Gif" in the script dropdown menu and, Enable, set the parameters based on the "Frames grid LoRA" used, example for 2x3 grid set XSlices=2 & YSlices=3.

  6. Expand the Extra options if want to toggle playing back and forth.

  7. Now Hit Generate ! and your can check the result in "stable-diffusion-webui\outputs\txt2img-images\txt2gif"

Parameter Animation 🎛 :

  1. for this you'll need to get a "Weight progressing concept LoRA" and you'll need the Controlled Parameters Animation script for progressing the LoRA weight .

    1. note that you can also try with this approach with normal LoRAs

  2. now select the "Controlled Parameters Animation" in the script dropdown menu .

  3. choose Parameter Type "LoRA"

  4. add the LoRA Name you want to control, Exmaple for "<lora:MyTestLora_v10 :1>" to I'll add "MyTestLora_v10"

  5. now specify the parameters like the stating Value (value does the LoRA starts moving form), the end Value (value where to LoRA stops progressing), and the step value (how much does to LoRA progresses each frame).

    1. note that you set the LoRA to progress backward by making the stating Value greater then the end Value

    2. lower step value like 0.01 makes for more generated frames and a much smoother transition

  6. now add the inputed parameters by clicking on " Add Parameter Layer"

  7. Expand the Extra options can hit "Estimate Output" to check how many images are going to get generated

    1. you can also toggle playing back and forth by checking "Pingpong".

  8. Now Hit Generate ! and your can check the result in "stable-diffusion-webui\outputs\txt2img-images\txt2gif"

3. Applying interpolation (smoothing)

  1. for this you'll need the Flowframes software installed, when prompted to choose an interpolation model to download just choose the latest RIFE model (RIFE CUDA for NVIDIA).

    1. the model file is a bit large and may fail to download at first, just keep on retrying by going to Setting/ Application/ Manage Downloaded Model Files / Open Model Downloader

  2. Now in the interpolation Tab choose the Ai model that you downloaded,

  3. click on browse Video and load the generated GIF from "stable-diffusion-webui\outputs\txt2img-images\txt2gif"

  4. experiment with the output speed, I mostly use "x3 Speed" with "x2 Slowmo" for smooth 30fps GIFs

  5. and finally set the output format to GIF

    1. you might want to low the quality and color pallet for smaller sizes

  6. Now Hit Interpolate! and you'll find the result in the same Directory as the input

Happy Animating 👍