Code Monkey home page Code Monkey logo

discodiffusion-warp-docker's Introduction

Disco Diffusion Docker

This is a fork of https://github.com/Sxela/DiscoDiffusion-Warp allowing to run the models locally outside of Google Collab on Windows and Linux machines. The following instructions are focused on Windows.

Prerequisites

How to build docker image

  1. go to the folder docker
  2. run docker build . -t disco-diffusion-docker

How to run docker image

Given that your path to this cloned repository is C:\repos\DiscoDiffusion-Warp-Docker, run following command in WSL:

docker run -it --rm --gpus=all -v /mnt/c/repos/DiscoDiffusion-Warp-Docker:/notebooks -p 8888:8888 disco-diffusion-docker

Original README follows.

Disco Diffusion v5.2 - WarpFusion

Disco Diffusion v5.2 - Warp visitors

Discuss on Discord (keeping it on linktree now so it's always an active link)

About

This version improves video init. You can now generate optical flow maps from input videos, and use those to:

  • warp init frames for consistent style
  • warp processed frames for less noise in final video

Init warping

The feature works like this: we take the 1st frame, diffuse it as usual as an image input with fixed skip steps. Then we warp in with its flow map into the 2nd frame and blend it with the original raw video 2nd frame. This way we get the style from heavily stylized 1st frame (warped accordingly) and content from 2nd frame (to reduce warping artifacts and prevent overexposure)

Changelog

27.05.2022

  • Add existing flow check, now generate only if no flow found
  • Add comprehensive error reporting for missing video_init, video frames, flow files
  • Fix non alphanumeric batch names not working
  • Fix frames not being sorted before creating output video
  • Fix incorrect RAFT root foder on local machines
  • Add storing RAFT on gdrive

23.05.2022

  • Add colab for 3d animation only

22.05.2022:

  • Add saving frames and flow to google drive (suggested by Chris the Wizard#8082)
  • Add back consistency checking

18.05.2022

  • Update 512x512 and secondary model urls

17.05.2022

  • Remove consistency checking for stability

15.05.2022

  • Add 256x256 comis faces model

22.04.2022:

  • Add ViT-L/14@336px

21.04.2022:

  • Add warp parameteres to saved settings

16.04.2022:

  • Use width_height size instead of input video size
  • Bring back adabins and 2d/3d anim modes
  • Install RAFT only when video input animation mode is selected
  • Generate optical flow maps only for video input animation mode even with flow_warp unchecked, so you can still save an obtical flow blended video later
  • Install AdaBins for 3d mode only (should do the same for midas)
  • Add animation mode check to create video tab

15.04.2022: Init

Optical flow input warping

Settings:

(Located in animation settings tab)

Video Optical Flow Settings:

  • flow_warp - check to warp
  • flow_blend: 0 - you get raw input, 1 - you get warped diffused previous frame
  • check_consistency: check forward-backward flow consistency (uncheck unless getting too many warping artifacts)

Output warping

This feature is plain simple - we just take any frame, warp in to the next frame, blend with real next frame, get smooth noise-free result.

Settings:

(located in create video tab) blend_mode:

  • none: just mash frames together in a video
  • optical flow: take frame, warp, blend with the next frame
  • check_consistency: use consistency maps (may prevent warping artfacts)
  • blend: 0 - you get raw 2nd frame, 1 - you get warped 1st frame

TODO:

  • Add automatic flow map management (i.e. create only when needed)
  • Add error reporting for missing inputs, flows, frames
  • Add turbo
  • Add turbosmooth

This is a variation of the awesome DiscoDiffusion colab

If you like what I'm doing you can check my linktree

  • follow author of Disco Diffusion Warp on twitter
  • tip author of Disco Diffusion Warp on patreon

Thank you for being awesome!

discodiffusion-warp-docker's People

Contributors

sxela avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.