Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/martin-rizzo/tinyautoencoderconverter

Command-line tool to build VAEs and Transcoders (from Tiny AutoEncoders).
https://github.com/martin-rizzo/tinyautoencoderconverter

auto1111 comfyui flux stable-diffusion text2image transcoder txt2img vae

Last synced: 7 days ago
JSON representation

Command-line tool to build VAEs and Transcoders (from Tiny AutoEncoders).

Awesome Lists containing this project

README

        

# Tiny AutoEncoder Converter


Platform
License
Version
Last


**Tiny AutoEncoder Converter** is a command-line utility that converts Tiny AutoEncoders into comfyui-compatible Variational AutoEncoders (VAEs) and Transcoders.

## What are Tiny AutoEncoders?

Tiny AutoEncoders (TAEs) are highly optimized autoencoders that share the same latent space as Stable Diffusion and Flux VAEs. This enables significantly faster and more resource-efficient image encoding and decoding. These models were developed and trained by Ollin Boer Bohan, to whom I express my sincere gratitude. You can find Ollin's original implementation and pre-trained models in the [Tiny AutoEncoder Repository](https://github.com/madebyollin/taesd).

## Command-Line Tools

This project provides the following command-line conversion tools:
- `build_tiny_vae.py`: Generates a comfyui-compatible VAE model from a Tiny AutoEncoder.
- `build_tiny_transcoder.py`: Creates a transcoder enabling latent space conversion between different models (e.g., SDXL to SD).

## Installation and Usage

1. **Clone the Repository:**
First, you need to clone this repository to your local machine.
```bash
git clone https://github.com/martin-rizzo/TinyAutoEncoderConverter.git
```

2. **Download Original Models:**
Navigate into the cloned directory and download the necessary models from Hugging Face.
```bash
cd TinyAutoEncoderConverter
wget https://huggingface.co/madebyollin/taef1/blob/main/diffusion_pytorch_model.safetensors -P original_taesd_models/taef1
wget https://huggingface.co/madebyollin/taesd/blob/main/diffusion_pytorch_model.safetensors -P original_taesd_models/taesd
wget https://huggingface.co/madebyollin/taesd3/blob/main/diffusion_pytorch_model.safetensors -P original_taesd_models/taesd3
wget https://huggingface.co/madebyollin/taesdx/blob/main/diffusion_pytorch_model.safetensors -P original_taesd_models/taesdx
```

4. **Run the Bash Script:**
Execute the `makeall.sh` script to generate.
```bash
./makeall.sh
```
## Output

When running the general `makeall.sh` script, it will generate several files with the following naming format:
- `tiny_vae_*.safetensors`: VAE models compatible with ComfyUI.
- `transcoder_from_*_to_*.safetensors`: Transcoder model files.

## License

**Copyright (c) 2024 Martin Rizzo**
This project is licensed under the MIT license.
Details can be found in the ["LICENSE"](LICENSE) file.

## Disclaimer

This tool is provided "as is" without any warranty. Use at your own risk.