Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -17,8 +17,11 @@ summarizer = pipeline("summarization", model="facebook/bart-large-cnn")
|
|
| 17 |
imagePipeline = FluxPipeline.from_pretrained("black-forest-labs/FLUX.1-schnell", torch_dtype=torch.bfloat16)
|
| 18 |
imagePipeline.enable_model_cpu_offload() #save some VRAM by offloading the model to CPU
|
| 19 |
|
|
|
|
|
|
|
|
|
|
| 20 |
#Input prompt
|
| 21 |
-
writingPrompt = st.text_input("Paste
|
| 22 |
|
| 23 |
#Conditional to check submission
|
| 24 |
if writingPrompt:
|
|
@@ -43,7 +46,7 @@ if writingPrompt:
|
|
| 43 |
#Image generation
|
| 44 |
summary = summarizer(response_content, max_length=130, min_length=30, do_sample=False)
|
| 45 |
|
| 46 |
-
|
| 47 |
prompt = "A cat holding a sign that says hello world"
|
| 48 |
image = imagePipeline(
|
| 49 |
prompt,
|
|
|
|
| 17 |
imagePipeline = FluxPipeline.from_pretrained("black-forest-labs/FLUX.1-schnell", torch_dtype=torch.bfloat16)
|
| 18 |
imagePipeline.enable_model_cpu_offload() #save some VRAM by offloading the model to CPU
|
| 19 |
|
| 20 |
+
#Intro text
|
| 21 |
+
st.write("Are you writing a story but don't know where to start?")
|
| 22 |
+
|
| 23 |
#Input prompt
|
| 24 |
+
writingPrompt = st.text_input("Paste your idea here, and have an introduction generated for you: ")
|
| 25 |
|
| 26 |
#Conditional to check submission
|
| 27 |
if writingPrompt:
|
|
|
|
| 46 |
#Image generation
|
| 47 |
summary = summarizer(response_content, max_length=130, min_length=30, do_sample=False)
|
| 48 |
|
| 49 |
+
"""
|
| 50 |
prompt = "A cat holding a sign that says hello world"
|
| 51 |
image = imagePipeline(
|
| 52 |
prompt,
|