source
stringclasses
273 values
url
stringlengths
47
172
file_type
stringclasses
1 value
chunk
stringlengths
1
512
chunk_id
stringlengths
5
9
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
```py from diffusers import StableDiffusionXLPipeline, DDIMScheduler ckpt_path = "https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0/blob/main/sd_xl_base_1.0_0.9vae.safetensors" scheduler = DDIMScheduler() pipeline = StableDiffusionXLPipeline.from_single_file(ckpt_path, scheduler=scheduler) ``` Or you c...
82_9_16
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
Or you could use a ControlNet model in the pipeline. ```py from diffusers import StableDiffusionControlNetPipeline, ControlNetModel ckpt_path = "https://huggingface.co/stable-diffusion-v1-5/stable-diffusion-v1-5/blob/main/v1-5-pruned-emaonly.safetensors" controlnet = ControlNetModel.from_pretrained("lllyasviel/contr...
82_9_17
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
### Customize configuration options Models have a configuration file that define their attributes like the number of inputs in a UNet. Pipelines configuration options are available in the pipeline's class. For example, if you look at the [`StableDiffusionXLInstructPix2PixPipeline`] class, there is an option to scale t...
82_9_18
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
These configuration files can be found in the models Hub repository or another location from which the configuration file originated (for example, a GitHub repository or locally on your device). <hfoptions id="config-file"> <hfoption id="Hub configuration file">
82_9_19
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
<hfoptions id="config-file"> <hfoption id="Hub configuration file"> > [!TIP] > The [`~loaders.FromSingleFileMixin.from_single_file`] method automatically maps the checkpoint to the appropriate model repository, but there are cases where it is useful to use the `config` parameter. For example, if the model components i...
82_9_20
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
The [`~loaders.FromSingleFileMixin.from_single_file`] method automatically determines the configuration to use from the configuration file in the model repository. You could also explicitly specify the configuration to use by providing the repository id to the `config` parameter.
82_9_21
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
```py from diffusers import StableDiffusionXLPipeline ckpt_path = "https://huggingface.co/segmind/SSD-1B/blob/main/SSD-1B.safetensors" repo_id = "segmind/SSD-1B" pipeline = StableDiffusionXLPipeline.from_single_file(ckpt_path, config=repo_id) ```
82_9_22
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
The model loads the configuration file for the [UNet](https://huggingface.co/segmind/SSD-1B/blob/main/unet/config.json), [VAE](https://huggingface.co/segmind/SSD-1B/blob/main/vae/config.json), and [text encoder](https://huggingface.co/segmind/SSD-1B/blob/main/text_encoder/config.json) from their respective subfolders i...
82_9_23
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
</hfoption> <hfoption id="original configuration file"> The [`~loaders.FromSingleFileMixin.from_single_file`] method can also load the original configuration file of a pipeline that is stored elsewhere. Pass a local path or URL of the original configuration file to the `original_config` parameter.
82_9_24
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
```py from diffusers import StableDiffusionXLPipeline ckpt_path = "https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0/blob/main/sd_xl_base_1.0_0.9vae.safetensors" original_config = "https://raw.githubusercontent.com/Stability-AI/generative-models/main/configs/inference/sd_xl_base.yaml" pipeline = Stabl...
82_9_25
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
> [!TIP] > Diffusers attempts to infer the pipeline components based on the type signatures of the pipeline class when you use `original_config` with `local_files_only=True`, instead of fetching the configuration files from the model repository on the Hub. This prevents backward breaking changes in code that can't conn...
82_9_26
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
> > This is not as reliable as providing a path to a local model repository with the `config` parameter, and might lead to errors during pipeline configuration. To avoid errors, run the pipeline with `local_files_only=False` once to download the appropriate pipeline configuration files to the local cache.
82_9_27
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
</hfoption> </hfoptions> While the configuration files specify the pipeline or models default parameters, you can override them by providing the parameters directly to the [`~loaders.FromSingleFileMixin.from_single_file`] method. Any parameter supported by the model or pipeline class can be configured in this way. <h...
82_9_28
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
For example, to scale the image latents in [`StableDiffusionXLInstructPix2PixPipeline`] pass the `is_cosxl_edit` parameter. ```python from diffusers import StableDiffusionXLInstructPix2PixPipeline ckpt_path = "https://huggingface.co/stabilityai/cosxl/blob/main/cosxl_edit.safetensors" pipeline = StableDiffusionXLInst...
82_9_29
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
</hfoption> <hfoption id="model"> For example, to upcast the attention dimensions in a [`UNet2DConditionModel`] pass the `upcast_attention` parameter. ```python from diffusers import UNet2DConditionModel ckpt_path = "https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0/blob/main/sd_xl_base_1.0_0.9vae.saf...
82_9_30
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
</hfoption> </hfoptions> ### Local files In Diffusers>=v0.28.0, the [`~loaders.FromSingleFileMixin.from_single_file`] method attempts to configure a pipeline or model by inferring the model type from the keys in the checkpoint file. The inferred model type is used to determine the appropriate model repository on the ...
82_9_31
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
For example, any single file checkpoint based on the Stable Diffusion XL base model will use the [stabilityai/stable-diffusion-xl-base-1.0](https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0) model repository to configure the pipeline.
82_9_32
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
But if you're working in an environment with restricted internet access, you should download the configuration files with the [`~huggingface_hub.snapshot_download`] function, and the model checkpoint with the [`~huggingface_hub.hf_hub_download`] function. By default, these files are downloaded to the Hugging Face Hub [...
82_9_33
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
Pass the configuration and checkpoint paths to the [`~loaders.FromSingleFileMixin.from_single_file`] method to load locally. <hfoptions id="local"> <hfoption id="Hub cache directory">
82_9_34
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
<hfoptions id="local"> <hfoption id="Hub cache directory"> ```python from huggingface_hub import hf_hub_download, snapshot_download my_local_checkpoint_path = hf_hub_download( repo_id="segmind/SSD-1B", filename="SSD-1B.safetensors" ) my_local_config_path = snapshot_download( repo_id="segmind/SSD-1B", allow_pattern...
82_9_35
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
</hfoption> <hfoption id="specific local directory">
82_9_36
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
```python from huggingface_hub import hf_hub_download, snapshot_download my_local_checkpoint_path = hf_hub_download( repo_id="segmind/SSD-1B", filename="SSD-1B.safetensors" local_dir="my_local_checkpoints" ) my_local_config_path = snapshot_download( repo_id="segmind/SSD-1B", allow_patterns=["*.json", "**/*.json", "...
82_9_37
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
</hfoption> </hfoptions> #### Local files without symlink > [!TIP] > In huggingface_hub>=v0.23.0, the `local_dir_use_symlinks` argument isn't necessary for the [`~huggingface_hub.hf_hub_download`] and [`~huggingface_hub.snapshot_download`] functions.
82_9_38
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
The [`~loaders.FromSingleFileMixin.from_single_file`] method relies on the [huggingface_hub](https://hf.co/docs/huggingface_hub/index) caching mechanism to fetch and store checkpoints and configuration files for models and pipelines. If you're working with a file system that does not support symlinking, you should down...
82_9_39
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
disable symlinking with the `local_dir_use_symlink=False` parameter in the [`~huggingface_hub.hf_hub_download`] function and [`~huggingface_hub.snapshot_download`] functions.
82_9_40
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
```python from huggingface_hub import hf_hub_download, snapshot_download my_local_checkpoint_path = hf_hub_download( repo_id="segmind/SSD-1B", filename="SSD-1B.safetensors" local_dir="my_local_checkpoints", local_dir_use_symlinks=False ) print("My local checkpoint: ", my_local_checkpoint_path) my_local_config_path ...
82_9_41
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
local_dir_use_symlinks=False, ) print("My local config: ", my_local_config_path) ```
82_9_42
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/other-formats.md
https://huggingface.co/docs/diffusers/en/using-diffusers/other-formats/#dduf
.md
Then you can pass the local paths to the `pretrained_model_link_or_path` and `config` parameters. ```python pipeline = StableDiffusionXLPipeline.from_single_file(my_local_checkpoint_path, config=my_local_config_path, local_files_only=True) ```
82_9_43
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/
.md
<!--Copyright 2024 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agr...
83_0_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/
.md
an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. -->
83_0_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image
.md
[[open-in-colab]]
83_1_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image
.md
Image-to-image is similar to [text-to-image](conditional_image_generation), but in addition to a prompt, you can also pass an initial image as a starting point for the diffusion process. The initial image is encoded to latent space and noise is added to it. Then the latent diffusion model takes a prompt and the noisy l...
83_1_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image
.md
noise from the initial latent image to get the new latent image. Lastly, a decoder decodes the new latent image back into an image.
83_1_2
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image
.md
With 🤗 Diffusers, this is as easy as 1-2-3: 1. Load a checkpoint into the [`AutoPipelineForImage2Image`] class; this pipeline automatically handles loading the correct pipeline class based on the checkpoint: ```py import torch from diffusers import AutoPipelineForImage2Image from diffusers.utils import load_image...
83_1_3
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image
.md
pipeline = AutoPipelineForImage2Image.from_pretrained( "kandinsky-community/kandinsky-2-2-decoder", torch_dtype=torch.float16, use_safetensors=True ) pipeline.enable_model_cpu_offload() # remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xformers_memory_effic...
83_1_4
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image
.md
``` <Tip> You'll notice throughout the guide, we use [`~DiffusionPipeline.enable_model_cpu_offload`] and [`~DiffusionPipeline.enable_xformers_memory_efficient_attention`], to save memory and increase inference speed. If you're using PyTorch 2.0, then you don't need to call [`~DiffusionPipeline.enable_xformers_memor...
83_1_5
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image
.md
</Tip> 2. Load an image to pass to the pipeline: ```py init_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png") ``` 3. Pass a prompt and image to the pipeline to generate an image: ```py prompt = "cat wizard, gandalf, lord of the rings, detailed,...
83_1_6
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image
.md
make_image_grid([init_image, image], rows=1, cols=2) ``` <div class="flex gap-4"> <div> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png"/> <figcaption class="mt-2 text-center text-sm text-gray-500">initial image</figcaption> </div> <div> <im...
83_1_7
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image
.md
<figcaption class="mt-2 text-center text-sm text-gray-500">generated image</figcaption> </div> </div>
83_1_8
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#popular-models
.md
The most popular image-to-image models are [Stable Diffusion v1.5](https://huggingface.co/stable-diffusion-v1-5/stable-diffusion-v1-5), [Stable Diffusion XL (SDXL)](https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0), and [Kandinsky 2.2](https://huggingface.co/kandinsky-community/kandinsky-2-2-decoder). Th...
83_2_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#popular-models
.md
due to their architecture differences and training process; you can generally expect SDXL to produce higher quality images than Stable Diffusion v1.5. Let's take a quick look at how to use each of these models and compare their results.
83_2_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#stable-diffusion-v15
.md
Stable Diffusion v1.5 is a latent diffusion model initialized from an earlier checkpoint, and further finetuned for 595K steps on 512x512 images. To use this pipeline for image-to-image, you'll need to prepare an initial image to pass to the pipeline. Then you can pass a prompt and the image to the pipeline to generate...
83_3_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#stable-diffusion-v15
.md
pipeline = AutoPipelineForImage2Image.from_pretrained( "stable-diffusion-v1-5/stable-diffusion-v1-5", torch_dtype=torch.float16, variant="fp16", use_safetensors=True ) pipeline.enable_model_cpu_offload() # remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xfo...
83_3_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#stable-diffusion-v15
.md
# prepare image url = "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-init.png" init_image = load_image(url) prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k"
83_3_2
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#stable-diffusion-v15
.md
# pass prompt and image to pipeline image = pipeline(prompt, image=init_image).images[0] make_image_grid([init_image, image], rows=1, cols=2) ``` <div class="flex gap-4"> <div> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-init.png"/> <fig...
83_3_3
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#stable-diffusion-v15
.md
<figcaption class="mt-2 text-center text-sm text-gray-500">initial image</figcaption> </div> <div> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-sdv1.5.png"/> <figcaption class="mt-2 text-center text-sm text-gray-500">generated image</figcap...
83_3_4
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#stable-diffusion-xl-sdxl
.md
SDXL is a more powerful version of the Stable Diffusion model. It uses a larger base model, and an additional refiner model to increase the quality of the base model's output. Read the [SDXL](sdxl) guide for a more detailed walkthrough of how to use this model, and other techniques it uses to produce high quality image...
83_4_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#stable-diffusion-xl-sdxl
.md
pipeline = AutoPipelineForImage2Image.from_pretrained( "stabilityai/stable-diffusion-xl-refiner-1.0", torch_dtype=torch.float16, variant="fp16", use_safetensors=True ) pipeline.enable_model_cpu_offload() # remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xfo...
83_4_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#stable-diffusion-xl-sdxl
.md
# prepare image url = "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-sdxl-init.png" init_image = load_image(url) prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k"
83_4_2
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#stable-diffusion-xl-sdxl
.md
# pass prompt and image to pipeline image = pipeline(prompt, image=init_image, strength=0.5).images[0] make_image_grid([init_image, image], rows=1, cols=2) ``` <div class="flex gap-4"> <div> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-sd...
83_4_3
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#stable-diffusion-xl-sdxl
.md
<figcaption class="mt-2 text-center text-sm text-gray-500">initial image</figcaption> </div> <div> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-sdxl.png"/> <figcaption class="mt-2 text-center text-sm text-gray-500">generated image</figcapti...
83_4_4
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#kandinsky-22
.md
The Kandinsky model is different from the Stable Diffusion models because it uses an image prior model to create image embeddings. The embeddings help create a better alignment between text and images, allowing the latent diffusion model to generate better images. The simplest way to use Kandinsky 2.2 is: ```py imp...
83_5_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#kandinsky-22
.md
pipeline = AutoPipelineForImage2Image.from_pretrained( "kandinsky-community/kandinsky-2-2-decoder", torch_dtype=torch.float16, use_safetensors=True ) pipeline.enable_model_cpu_offload() # remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xformers_memory_effic...
83_5_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#kandinsky-22
.md
prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k"
83_5_2
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#kandinsky-22
.md
# pass prompt and image to pipeline image = pipeline(prompt, image=init_image).images[0] make_image_grid([init_image, image], rows=1, cols=2) ``` <div class="flex gap-4"> <div> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-init.png"/> <fig...
83_5_3
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#kandinsky-22
.md
<figcaption class="mt-2 text-center text-sm text-gray-500">initial image</figcaption> </div> <div> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-kandinsky.png"/> <figcaption class="mt-2 text-center text-sm text-gray-500">generated image</fig...
83_5_4
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#configure-pipeline-parameters
.md
There are several important parameters you can configure in the pipeline that'll affect the image generation process and image quality. Let's take a closer look at what these parameters do and how changing them affects the output.
83_6_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#strength
.md
`strength` is one of the most important parameters to consider and it'll have a huge impact on your generated image. It determines how much the generated image resembles the initial image. In other words: - 📈 a higher `strength` value gives the model more "creativity" to generate an image that's different from the i...
83_7_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#strength
.md
- 📉 a lower `strength` value means the generated image is more similar to the initial image The `strength` and `num_inference_steps` parameters are related because `strength` determines the number of noise steps to add. For example, if the `num_inference_steps` is 50 and `strength` is 0.8, then this means adding 40 ...
83_7_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#strength
.md
```py import torch from diffusers import AutoPipelineForImage2Image from diffusers.utils import make_image_grid, load_image
83_7_2
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#strength
.md
pipeline = AutoPipelineForImage2Image.from_pretrained( "stable-diffusion-v1-5/stable-diffusion-v1-5", torch_dtype=torch.float16, variant="fp16", use_safetensors=True ) pipeline.enable_model_cpu_offload() # remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xfo...
83_7_3
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#strength
.md
# prepare image url = "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-init.png" init_image = load_image(url) prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k"
83_7_4
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#strength
.md
# pass prompt and image to pipeline image = pipeline(prompt, image=init_image, strength=0.8).images[0] make_image_grid([init_image, image], rows=1, cols=2) ``` <div class="flex flex-row gap-4"> <div class="flex-1"> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/m...
83_7_5
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#strength
.md
<figcaption class="mt-2 text-center text-sm text-gray-500">strength = 0.4</figcaption> </div> <div class="flex-1"> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-strength-0.6.png"/> <figcaption class="mt-2 text-center text-sm text-gray-500">s...
83_7_6
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#strength
.md
<figcaption class="mt-2 text-center text-sm text-gray-500">strength = 0.6</figcaption> </div> <div class="flex-1"> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-strength-1.0.png"/> <figcaption class="mt-2 text-center text-sm text-gray-500">s...
83_7_7
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#guidance-scale
.md
The `guidance_scale` parameter is used to control how closely aligned the generated image and text prompt are. A higher `guidance_scale` value means your generated image is more aligned with the prompt, while a lower `guidance_scale` value means your generated image has more space to deviate from the prompt.
83_8_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#guidance-scale
.md
You can combine `guidance_scale` with `strength` for even more precise control over how expressive the model is. For example, combine a high `strength + guidance_scale` for maximum creativity or use a combination of low `strength` and low `guidance_scale` to generate an image that resembles the initial image but is not...
83_8_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#guidance-scale
.md
pipeline = AutoPipelineForImage2Image.from_pretrained( "stable-diffusion-v1-5/stable-diffusion-v1-5", torch_dtype=torch.float16, variant="fp16", use_safetensors=True ) pipeline.enable_model_cpu_offload() # remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xfo...
83_8_2
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#guidance-scale
.md
# prepare image url = "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-init.png" init_image = load_image(url) prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k"
83_8_3
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#guidance-scale
.md
# pass prompt and image to pipeline image = pipeline(prompt, image=init_image, guidance_scale=8.0).images[0] make_image_grid([init_image, image], rows=1, cols=2) ``` <div class="flex flex-row gap-4"> <div class="flex-1"> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/res...
83_8_4
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#guidance-scale
.md
<figcaption class="mt-2 text-center text-sm text-gray-500">guidance_scale = 0.1</figcaption> </div> <div class="flex-1"> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-guidance-3.0.png"/> <figcaption class="mt-2 text-center text-sm text-gray-...
83_8_5
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#guidance-scale
.md
<figcaption class="mt-2 text-center text-sm text-gray-500">guidance_scale = 5.0</figcaption> </div> <div class="flex-1"> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-guidance-7.5.png"/> <figcaption class="mt-2 text-center text-sm text-gray-...
83_8_6
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#negative-prompt
.md
A negative prompt conditions the model to *not* include things in an image, and it can be used to improve image quality or modify an image. For example, you can improve image quality by including negative prompts like "poor details" or "blurry" to encourage the model to generate a higher quality image. Or you can modif...
83_9_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#negative-prompt
.md
pipeline = AutoPipelineForImage2Image.from_pretrained( "stabilityai/stable-diffusion-xl-refiner-1.0", torch_dtype=torch.float16, variant="fp16", use_safetensors=True ) pipeline.enable_model_cpu_offload() # remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xfo...
83_9_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#negative-prompt
.md
# prepare image url = "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-init.png" init_image = load_image(url) prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" negative_prompt = "ugly, deformed, disfigured, poor details, bad anatomy"
83_9_2
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#negative-prompt
.md
# pass prompt and image to pipeline image = pipeline(prompt, negative_prompt=negative_prompt, image=init_image).images[0] make_image_grid([init_image, image], rows=1, cols=2) ``` <div class="flex flex-row gap-4"> <div class="flex-1"> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentati...
83_9_3
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#negative-prompt
.md
<figcaption class="mt-2 text-center text-sm text-gray-500">negative_prompt = "ugly, deformed, disfigured, poor details, bad anatomy"</figcaption> </div> <div class="flex-1"> <img class="rounded-xl" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-negative-2.png"/> <fi...
83_9_4
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#chained-image-to-image-pipelines
.md
There are some other interesting ways you can use an image-to-image pipeline aside from just generating an image (although that is pretty cool too). You can take it a step further and chain it with other pipelines.
83_10_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#text-to-image-to-image
.md
Chaining a text-to-image and image-to-image pipeline allows you to generate an image from text and use the generated image as the initial image for the image-to-image pipeline. This is useful if you want to generate an image entirely from scratch. For example, let's chain a Stable Diffusion and a Kandinsky model. Sta...
83_11_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#text-to-image-to-image
.md
```py from diffusers import AutoPipelineForText2Image, AutoPipelineForImage2Image import torch from diffusers.utils import make_image_grid
83_11_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#text-to-image-to-image
.md
pipeline = AutoPipelineForText2Image.from_pretrained( "stable-diffusion-v1-5/stable-diffusion-v1-5", torch_dtype=torch.float16, variant="fp16", use_safetensors=True ) pipeline.enable_model_cpu_offload() # remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xfor...
83_11_2
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#text-to-image-to-image
.md
text2image = pipeline("Astronaut in a jungle, cold color palette, muted colors, detailed, 8k").images[0] text2image ``` Now you can pass this generated image to the image-to-image pipeline: ```py pipeline = AutoPipelineForImage2Image.from_pretrained( "kandinsky-community/kandinsky-2-2-decoder", torch_dtype=torch.fl...
83_11_3
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#text-to-image-to-image
.md
# remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xformers_memory_efficient_attention()
83_11_4
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#text-to-image-to-image
.md
image2image = pipeline("Astronaut in a jungle, cold color palette, muted colors, detailed, 8k", image=text2image).images[0] make_image_grid([text2image, image2image], rows=1, cols=2) ```
83_11_5
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image-to-image
.md
You can also chain multiple image-to-image pipelines together to create more interesting images. This can be useful for iteratively performing style transfer on an image, generating short GIFs, restoring color to an image, or restoring missing areas of an image. Start by generating an image: ```py import torch from...
83_12_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image-to-image
.md
pipeline = AutoPipelineForImage2Image.from_pretrained( "stable-diffusion-v1-5/stable-diffusion-v1-5", torch_dtype=torch.float16, variant="fp16", use_safetensors=True ) pipeline.enable_model_cpu_offload() # remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xfo...
83_12_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image-to-image
.md
# prepare image url = "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-init.png" init_image = load_image(url) prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k"
83_12_2
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image-to-image
.md
# pass prompt and image to pipeline image = pipeline(prompt, image=init_image, output_type="latent").images[0] ``` <Tip> It is important to specify `output_type="latent"` in the pipeline to keep all the outputs in latent space to avoid an unnecessary decode-encode step. This only works if the chained pipelines are ...
83_12_3
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image-to-image
.md
</Tip> Pass the latent output from this pipeline to the next pipeline to generate an image in a [comic book art style](https://huggingface.co/ogkalu/Comic-Diffusion): ```py pipeline = AutoPipelineForImage2Image.from_pretrained( "ogkalu/Comic-Diffusion", torch_dtype=torch.float16 ) pipeline.enable_model_cpu_offload(...
83_12_4
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image-to-image
.md
# need to include the token "charliebo artstyle" in the prompt to use this checkpoint image = pipeline("Astronaut in a jungle, charliebo artstyle", image=image, output_type="latent").images[0] ``` Repeat one more time to generate the final image in a [pixel art style](https://huggingface.co/kohbanye/pixel-art-style):...
83_12_5
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image-to-image
.md
"kohbanye/pixel-art-style", torch_dtype=torch.float16 ) pipeline.enable_model_cpu_offload() # remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xformers_memory_efficient_attention()
83_12_6
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-image-to-image
.md
# need to include the token "pixelartstyle" in the prompt to use this checkpoint image = pipeline("Astronaut in a jungle, pixelartstyle", image=image).images[0] make_image_grid([init_image, image], rows=1, cols=2) ```
83_12_7
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-upscaler-to-super-resolution
.md
Another way you can chain your image-to-image pipeline is with an upscaler and super-resolution pipeline to really increase the level of details in an image. Start with an image-to-image pipeline: ```py import torch from diffusers import AutoPipelineForImage2Image from diffusers.utils import make_image_grid, load_i...
83_13_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-upscaler-to-super-resolution
.md
pipeline = AutoPipelineForImage2Image.from_pretrained( "stable-diffusion-v1-5/stable-diffusion-v1-5", torch_dtype=torch.float16, variant="fp16", use_safetensors=True ) pipeline.enable_model_cpu_offload() # remove following line if xFormers is not installed or you have PyTorch 2.0 or higher installed pipeline.enable_xfo...
83_13_1
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-upscaler-to-super-resolution
.md
# prepare image url = "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/img2img-init.png" init_image = load_image(url) prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k"
83_13_2
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-upscaler-to-super-resolution
.md
# pass prompt and image to pipeline image_1 = pipeline(prompt, image=init_image, output_type="latent").images[0] ``` <Tip> It is important to specify `output_type="latent"` in the pipeline to keep all the outputs in *latent* space to avoid an unnecessary decode-encode step. This only works if the chained pipelines ...
83_13_3
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-upscaler-to-super-resolution
.md
upscaler = StableDiffusionLatentUpscalePipeline.from_pretrained( "stabilityai/sd-x2-latent-upscaler", torch_dtype=torch.float16, variant="fp16", use_safetensors=True ) upscaler.enable_model_cpu_offload() upscaler.enable_xformers_memory_efficient_attention() image_2 = upscaler(prompt, image=image_1, output_type="latent...
83_13_4
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#image-to-upscaler-to-super-resolution
.md
super_res = StableDiffusionUpscalePipeline.from_pretrained( "stabilityai/stable-diffusion-x4-upscaler", torch_dtype=torch.float16, variant="fp16", use_safetensors=True ) super_res.enable_model_cpu_offload() super_res.enable_xformers_memory_efficient_attention() image_3 = super_res(prompt, image=image_2).images[0] make...
83_13_5
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#control-image-generation
.md
Trying to generate an image that looks exactly the way you want can be difficult, which is why controlled generation techniques and models are so useful. While you can use the `negative_prompt` to partially control image generation, there are more robust methods like prompt weighting and ControlNets.
83_14_0
/Users/nielsrogge/Documents/python_projecten/diffusers/docs/source/en/using-diffusers/img2img.md
https://huggingface.co/docs/diffusers/en/using-diffusers/img2img/#prompt-weighting
.md
Prompt weighting allows you to scale the representation of each concept in a prompt. For example, in a prompt like "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k", you can choose to increase or decrease the embeddings of "astronaut" and "jungle". The [Compel](https://github.com/damian0815/compel...
83_15_0