Code Monkey home page Code Monkey logo

dreambooth-docker's Introduction

Docker for Dreambooth Stable Diffusion

This is a Docker Setup for Dreambooth to train personalized stable diffusion models.

See wsl2-setup.md for infos about setting up WSL2 and Docker under Windows.

Install

  • clone repo
  • Build with: docker compose -f docker-compose.build.yaml build

One-Time Setup

  • register on huggingface and create a new Access Token here: https://huggingface.co/settings/tokens
  • copy the token and set it in a file named .env in the form TOKEN=yourtoken. (see also example.env)

Configuration

  • make sure the folders checkpoint_output/, class_images and output/ are empty before training a new checkpoint.

    (if they don't exist, they are created on the first start)

  • put training images into instance_images/ directory.

  • edit app/train.sh file in a text editor.

    • only uncomment the type of training you want to use.
    • edit INSTANCE_PROMPT and CLASS_PROMPT
  • Edit settings in accelerate-config.yaml or run docker compose -f docker-compose.build.yaml exec accelerate config --config_file=/app/examples/dreambooth/accelerate-config.yaml to configure training acceleration settings.

Training

  • run container with docker compose -f docker-compose.build.yaml up -d
  • run docker compose -f docker-compose.build.yaml exec dreambooth ./train.sh
  • get the generated checkpoint file to use with most SD UIs (like https://github.com/AUTOMATIC1111/stable-diffusion-webui) from checkpoint_output/model.ckpt.

Helper

  • open shell into container with: docker compose -f docker-compose.build.yaml exec dreambooth bash

Sources

dreambooth-docker's People

Contributors

sharrnah 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.