Update main.py
Browse files
main.py
CHANGED
|
@@ -28,7 +28,7 @@ pipe.safety_checker = dummy
|
|
| 28 |
|
| 29 |
@app.get("/")
|
| 30 |
def hello():
|
| 31 |
-
return "Hello, I'm
|
| 32 |
|
| 33 |
|
| 34 |
@app.get("/gen/{prompt}")
|
|
@@ -37,10 +37,7 @@ def generate_image(prompt: str):
|
|
| 37 |
guidance_scale=8.5 # how strict to follow the prompt
|
| 38 |
).images[0]
|
| 39 |
# Save the image
|
| 40 |
-
image.save('
|
| 41 |
|
| 42 |
-
# do something with the generated image
|
| 43 |
-
image_data = image.tobytes().hex()
|
| 44 |
-
image_url = url_for('static', filename='image.png')
|
| 45 |
|
| 46 |
-
return
|
|
|
|
| 28 |
|
| 29 |
@app.get("/")
|
| 30 |
def hello():
|
| 31 |
+
return "Hello, I'm Artist"
|
| 32 |
|
| 33 |
|
| 34 |
@app.get("/gen/{prompt}")
|
|
|
|
| 37 |
guidance_scale=8.5 # how strict to follow the prompt
|
| 38 |
).images[0]
|
| 39 |
# Save the image
|
| 40 |
+
image.save('image.png')
|
| 41 |
|
|
|
|
|
|
|
|
|
|
| 42 |
|
| 43 |
+
return "Gen done"
|