Git Product home page Git Product logo

comfyui-ella-wrapper's Introduction

ComfyUI wrapper nodes to use the Diffusers implementation of ELLA

image

image

Installing

Either use the Manager and it's install from git -feature, or clone this repo to custom_nodes and run:

pip install -r requirements.txt

or if you use portable (run this in ComfyUI_windows_portable -folder):

python_embeded\python.exe -m pip install -r ComfyUI\custom_nodes\ComfyUI-ELLA-wrapper\requirements.txt

You can use any 1.5 model, rest is auto downloaded, sources:

ELLA model (132MB):

https://huggingface.co/QQGYLab/ELLA/blob/main/ella-sd1.5-tsc-t5xl.safetensors

Also requires google-flan-t5-xl, for which I have opted to autodownload this repo, 6GB):

https://huggingface.co/ybelkada/flan-t5-xl-sharded-bf16/tree/main

Original repo:

ELLA: Equip Diffusion Models with LLM for Enhanced Semantic Alignment

Xiwei Hu*, Rui Wang*, Yixiao Fang*, Bin Fu*, Pei Cheng, Gang Yuโœฆ

* Equal contributions, โœฆ Corresponding Author


Official code of "ELLA: Equip Diffusion Models with LLM for Enhanced Semantic Alignment".

๐ŸŒŸ Changelog

  • [2024.4.9] ๐Ÿ”ฅ๐Ÿ”ฅ๐Ÿ”ฅ Release ELLA-SD1.5 Checkpoint! Welcome to try!
  • [2024.3.11] ๐Ÿ”ฅ Release DPG-Bench! Welcome to try!
  • [2024.3.7] Initial update

Inference

ELLA-SD1.5

# get ELLA-SD1.5 at https://huggingface.co/QQGYLab/ELLA/blob/main/ella-sd1.5-tsc-t5xl.safetensors

# comparing ella-sd1.5 and sd1.5
# will generate images at `./assets/ella-inference-examples`
python3 inference.py test --save_folder ./assets/ella-inference-examples --ella_path /path/to/ella-sd1.5-tsc-t5xl.safetensors

# build a demo for ella-sd1.5
GRADIO_SERVER_NAME=0.0.0.0 GRADIO_SERVER_PORT=8082 python3 ./inference.py demo /path/to/ella-sd1.5-tsc-t5xl.safetensors

๐Ÿ“Š DPG-Bench

The guideline of DPG-Bench:

  1. Generate your images according to our prompts.

    It is recommended to generate 4 images per prompt and grid them to 2x2 format. Please Make sure your generated image's filename is the same with the prompt's filename.

  2. Run the following command to conduct evaluation.

    bash dpg_bench/dist_eval.sh $YOUR_IMAGE_PATH $RESOLUTION

Thanks to the excellent work of DSG sincerely, we follow their instructions to generate questions and answers of DPG-Bench.

๐Ÿ“ TODO

  • add huggingface demo link
  • release checkpoint
  • release inference code
  • release DPG-Bench

๐Ÿ’ก Others

We have also found LaVi-Bridge, another independent but similar work completed almost concurrently, which offers additional insights not covered by ELLA. The difference between ELLA and LaVi-Bridge can be found in issue 13. We are delighted to welcome other researchers and community users to promote the development of this field.

๐Ÿ˜‰ Citation

If you find ELLA useful for your research and applications, please cite us using this BibTeX:

@misc{hu2024ella,
      title={ELLA: Equip Diffusion Models with LLM for Enhanced Semantic Alignment}, 
      author={Xiwei Hu and Rui Wang and Yixiao Fang and Bin Fu and Pei Cheng and Gang Yu},
      year={2024},
      eprint={2403.05135},
      archivePrefix={arXiv},
      primaryClass={cs.CV}
}

comfyui-ella-wrapper's People

Contributors

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