Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -1,10 +1,10 @@
|
|
1 |
import spaces
|
2 |
import torch
|
3 |
-
from
|
4 |
import gradio as gr
|
5 |
|
6 |
# Load the pre-trained diffusion model
|
7 |
-
pipe =
|
8 |
pipe.to('cuda')
|
9 |
import re
|
10 |
|
@@ -31,9 +31,9 @@ def generate(prompt, guidance_scale, num_inference_steps, resolution, negative_p
|
|
31 |
|
32 |
# Example prompts to demonstrate the model's capabilities
|
33 |
example_prompts = [
|
34 |
-
["A futuristic cityscape at night under a starry sky",
|
35 |
-
["A serene landscape with a flowing river and autumn trees",
|
36 |
-
["An abstract painting of joy and energy in bright colors",
|
37 |
]
|
38 |
|
39 |
# Create a Gradio interface, 1024x1024,1152x960,896x1152
|
@@ -50,7 +50,7 @@ iface = gr.Interface(
|
|
50 |
examples=example_prompts,
|
51 |
title="PixArt 900M",
|
52 |
description=(
|
53 |
-
"This is a
|
54 |
"<br />This model is being <strong>actively trained</strong> on 3.5M samples across a wide distribution of photos, synthetic data, cinema, anime, and safe-for-work furry art."
|
55 |
"<br />"
|
56 |
"<br /> The datasets been filtered for extremist and illegal content, but it is possible to produce toxic outputs. <strong>This model has not been safety-aligned or fine-tuned</strong>."
|
@@ -64,8 +64,7 @@ iface = gr.Interface(
|
|
64 |
"<br />"
|
65 |
"<ul>"
|
66 |
"<li>Lead trainer: @pseudoterminalx (bghira@GitHub)</li>"
|
67 |
-
"<li>
|
68 |
-
"<li>Datasets: @ProGamerGov, @jimmycarter, @pseudoterminalx</li>"
|
69 |
"</ul>"
|
70 |
)
|
71 |
).launch()
|
|
|
1 |
import spaces
|
2 |
import torch
|
3 |
+
from custom_pipeline import FluxPipeline
|
4 |
import gradio as gr
|
5 |
|
6 |
# Load the pre-trained diffusion model
|
7 |
+
pipe = FluxPipeline.from_pretrained('terminusresearch/flux-booru-cfg3.5', torch_dtype=torch.bfloat16)
|
8 |
pipe.to('cuda')
|
9 |
import re
|
10 |
|
|
|
31 |
|
32 |
# Example prompts to demonstrate the model's capabilities
|
33 |
example_prompts = [
|
34 |
+
["A futuristic cityscape at night under a starry sky", 3.5, 25, "blurry, overexposed"],
|
35 |
+
["A serene landscape with a flowing river and autumn trees", 3, 20, "crowded, noisy"],
|
36 |
+
["An abstract painting of joy and energy in bright colors", 3.0, 30, "dark, dull"]
|
37 |
]
|
38 |
|
39 |
# Create a Gradio interface, 1024x1024,1152x960,896x1152
|
|
|
50 |
examples=example_prompts,
|
51 |
title="PixArt 900M",
|
52 |
description=(
|
53 |
+
"This is a Flux-based 12B parameter model, fully trained across 8xH100 GPUs to reintroduce classifier-free guidance (CFG) sampling."
|
54 |
"<br />This model is being <strong>actively trained</strong> on 3.5M samples across a wide distribution of photos, synthetic data, cinema, anime, and safe-for-work furry art."
|
55 |
"<br />"
|
56 |
"<br /> The datasets been filtered for extremist and illegal content, but it is possible to produce toxic outputs. <strong>This model has not been safety-aligned or fine-tuned</strong>."
|
|
|
64 |
"<br />"
|
65 |
"<ul>"
|
66 |
"<li>Lead trainer: @pseudoterminalx (bghira@GitHub)</li>"
|
67 |
+
"<li>Datasets: @jimmycarter, @pseudoterminalx</li>"
|
|
|
68 |
"</ul>"
|
69 |
)
|
70 |
).launch()
|