File size: 557 Bytes
d3fae95
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# MUSE-512-finetuned 

## Example 

First install the deps using 

```bash
pip install transformers accelerate ftfy
pip install -U git+https://github.com/huggingface/open-muse.git
```

```python
import torch
from muse import PipelineMuse

pipe = PipelineMuse.from_pretrained("openMUSE/muse-512-finetuned).to("cuda", dtype=torch.float16)
pipe.transformer.enable_xformers_memory_efficient_attention()

prompt = "A monkey doing yoga on the beach"
images = pipe(
  prompt, timesteps=16, guidance_scale=10, transformer_seq_len=1024, use_fp16=True
)
images[0]
```