CaioXapelaum commited on
Commit
cb2b794
1 Parent(s): b976226

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -4
app.py CHANGED
@@ -4,7 +4,6 @@ from PIL import Image
4
  import io
5
  import os
6
 
7
- # Set up your Hugging Face API key
8
  token = os.getenv("HF_TOKEN")
9
 
10
  API_URL = "https://api-inference.huggingface.co/models/stabilityai/stable-diffusion-xl-base-1.0"
@@ -24,14 +23,12 @@ def generate_image(prompt):
24
  return None
25
 
26
  def main():
27
- st.title("Stable Diffusion Image Generator")
28
 
29
- # Get user input
30
  prompt = st.text_input("Enter a prompt for image generation:")
31
 
32
  if st.button("Generate Image"):
33
  if prompt:
34
- # Generate and display the image
35
  image = generate_image(prompt)
36
  if image:
37
  st.image(image, caption="Generated Image")
 
4
  import io
5
  import os
6
 
 
7
  token = os.getenv("HF_TOKEN")
8
 
9
  API_URL = "https://api-inference.huggingface.co/models/stabilityai/stable-diffusion-xl-base-1.0"
 
23
  return None
24
 
25
  def main():
26
+ st.title("Stable Diffusion XL 1.0")
27
 
 
28
  prompt = st.text_input("Enter a prompt for image generation:")
29
 
30
  if st.button("Generate Image"):
31
  if prompt:
 
32
  image = generate_image(prompt)
33
  if image:
34
  st.image(image, caption="Generated Image")