Instructions to use CompVis/ldm-celebahq-256 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use CompVis/ldm-celebahq-256 with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("CompVis/ldm-celebahq-256", dtype=torch.bfloat16, device_map="cuda") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
Download vqvae/config.json from CompVis/ldm-celebahq-256: direct link, hf CLI and curl.
- Browser
- Download file 486 Bytes
-
https://huggingface.co/CompVis/ldm-celebahq-256/resolve/03978f22272a3c2502da709c3940e227c9714bdd/vqvae/config.json
- Command line
-
hf download hf://CompVis/ldm-celebahq-256@03978f22272a3c2502da709c3940e227c9714bdd/vqvae/config.json
-
curl -L -o config.json https://huggingface.co/CompVis/ldm-celebahq-256/resolve/03978f22272a3c2502da709c3940e227c9714bdd/vqvae/config.json
486 Bytes
| { | |
| "_class_name": "VQModel", | |
| "_diffusers_version": "0.1.2", | |
| "act_fn": "silu", | |
| "block_out_channels": [ | |
| 128, | |
| 256, | |
| 512 | |
| ], | |
| "down_block_types": [ | |
| "DownEncoderBlock2D", | |
| "DownEncoderBlock2D", | |
| "DownEncoderBlock2D" | |
| ], | |
| "in_channels": 3, | |
| "latent_channels": 3, | |
| "layers_per_block": 2, | |
| "num_vq_embeddings": 8192, | |
| "out_channels": 3, | |
| "sample_size": 256, | |
| "up_block_types": [ | |
| "UpDecoderBlock2D", | |
| "UpDecoderBlock2D", | |
| "UpDecoderBlock2D" | |
| ] | |
| } | |