Update app.py
Browse files
app.py
CHANGED
@@ -50,7 +50,7 @@ pipe = load_models()
|
|
50 |
def generate_image(enhanced_caption, seed, num_inference_steps, guidance_scale):
|
51 |
# pipe.to("cuda")
|
52 |
pipe.enable_model_cpu_offload()
|
53 |
-
"""Generate image using LeX-
|
54 |
# Truncate the caption if it's too long
|
55 |
# enhanced_caption = truncate_caption_by_tokens(enhanced_caption, max_tokens=256)
|
56 |
|
@@ -94,7 +94,7 @@ def run_pipeline(image_caption, text_caption, seed, num_inference_steps, guidanc
|
|
94 |
# Gradio interface
|
95 |
with gr.Blocks() as demo:
|
96 |
client = gr.State()
|
97 |
-
gr.Markdown("# LeX-Enhancer & LeX-
|
98 |
gr.Markdown("## Project Page: https://zhaoshitian.github.io/lexart/")
|
99 |
gr.Markdown("Generate enhanced captions from simple image and text descriptions, then create images with LeX-Lumina")
|
100 |
|
|
|
50 |
def generate_image(enhanced_caption, seed, num_inference_steps, guidance_scale):
|
51 |
# pipe.to("cuda")
|
52 |
pipe.enable_model_cpu_offload()
|
53 |
+
"""Generate image using LeX-FLUX"""
|
54 |
# Truncate the caption if it's too long
|
55 |
# enhanced_caption = truncate_caption_by_tokens(enhanced_caption, max_tokens=256)
|
56 |
|
|
|
94 |
# Gradio interface
|
95 |
with gr.Blocks() as demo:
|
96 |
client = gr.State()
|
97 |
+
gr.Markdown("# LeX-Enhancer & LeX-FLUX Demo")
|
98 |
gr.Markdown("## Project Page: https://zhaoshitian.github.io/lexart/")
|
99 |
gr.Markdown("Generate enhanced captions from simple image and text descriptions, then create images with LeX-Lumina")
|
100 |
|