---
language:
- en
tags:
- stable-diffusion
- text-to-image
- image-to-image
- anime
- illustrious
pipeline_tag: image-to-image
---
# Illustrious anime mix xl
`MykosX/illustrious-anime-mix-xl` is a Stable Diffusion model that can be used both for:
- text-to-image: generates quite good anime images, has some potential for NSFW
- image-to-image: tends to sharpen images generated by this model, great results when using original images (or generated by other models)
## Image show-case
|
(seed=300)** |
(seed=400)** |
(seed=500)** |
text-to-image
|
|
|
|
image-to-image
|
|
|
|
|
(seed=300)** |
(seed=400)** |
(seed=500)** |
text-to-image
|
|
|
|
image-to-image
|
|
|
|
Base image (from another model) |
image-to-image (seed=300)** |
image-to-image (seed=400)** |
image-to-image (seed=500)** |
|
|
|
|
|
|
|
|
Base image (from another model) |
image-to-image (seed=300)* |
image-to-image (seed=400)* |
image-to-image (seed=500)* |
** using these defaults unless specified:
Setting |
Default value |
prompt (landscape) |
landscape image, a boy and girl having fun on the beach |
prompt (portrait) |
portrait image, a girl in a nice dress posing for a photo |
negative prompt |
deformed iris, deformed pupils, bad anatomy, cloned face, extra arms, extra legs, missing fingers, too many fingers |
size (landscape) |
1024 x 768 |
size (portrait) |
768 x 1024 |
seed |
300 |
guidance scale |
12.0 |
strength |
0.5 |
inference steps |
30 |
## Diffusers
For more general information on how to run text-to-image models with 🧨 Diffusers, see [the docs](https://huggingface.co/docs/diffusers/using-diffusers/conditional_image_generation).
1. Installation
```
pip install diffusers transformers accelerate
```
2. Running example for text-to-image generation
```py
import torch
from diffusers import AutoPipelineForText2Image
pipe = AutoPipelineForText2Image.from_pretrained('MykosX/illustrious-anime-mix-xl', torch_dtype=torch.float32)
pipe = pipe.to("cpu")
prompt = "portrait image, a girl in a nice dress posing for a photo"
image = pipe(prompt).images[0]
image.save("./images/text-to-image.png")
```
3. Running example for image-to-image generation
```py
import torch
from diffusers import AutoPipelineForImage2Image
from PIL import Image
pipe = AutoPipelineForImage2Image.from_pretrained('MykosX/illustrious-anime-mix-xl', torch_dtype=torch.float32)
pipe = pipe.to("cpu")
base_image = Image.open("./images/text-to-image/girl-posing-photo-(original).jpg")
prompt = "portrait image, a girl in a nice dress posing for a photo"
image = pipe(prompt, image=base_image).images[0]
image.save("./images/image-to-image.png")
```
## PS
Play with the model and don't hesitate to show off