File size: 613 Bytes
c104964
 
 
 
 
 
 
1faad62
c104964
 
646462e
 
 
3652fcb
646462e
3652fcb
 
 
 
 
 
 
646462e
c104964
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
---
license: apache-2.0
---

Exported with (Inferentia 2 only):

```bash
optimum-cli export neuron --model black-forest-labs/FLUX.1-Krea-dev --tensor_parallel_size 8 --batch_size 1 --height 1024 --width 1024 --num_images_per_prompt 1 --sequence_length 512 --torch_dtype bfloat16 flux_krea_neuron_1024_tp8/
```

Inference

```python
from optimum.neuron import NeuronFluxPipeline

pipe = NeuronFluxPipeline.from_pretrained("Jingya/FLUX.1-Krea-dev-neuronx-tp8")
prompt = "A frog holding a sign that says hello world"
image = pipe(
    prompt,
    guidance_scale=4.5,
).images[0]
image.save("flux-krea-dev.png")
```