Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -41,7 +41,7 @@ def infer(text,title):
|
|
41 |
prompt = f"""Please create a simple suitable image to accompany the following text as part of an article with the title "{title}". The objects in the image must have realistic proportions. Text: "{text}"
|
42 |
Please make sure not to include text in the image."""
|
43 |
image_url_openai, revised_prompt = generate_image_openai(prompt)
|
44 |
-
style_image_url = style_transfer(image_url_openai, f'./
|
45 |
response = requests.get(style_image_url)
|
46 |
img = Image.open(BytesIO(response.content))
|
47 |
|
|
|
41 |
prompt = f"""Please create a simple suitable image to accompany the following text as part of an article with the title "{title}". The objects in the image must have realistic proportions. Text: "{text}"
|
42 |
Please make sure not to include text in the image."""
|
43 |
image_url_openai, revised_prompt = generate_image_openai(prompt)
|
44 |
+
style_image_url = style_transfer(image_url_openai, f'./Style.png',revised_prompt)
|
45 |
response = requests.get(style_image_url)
|
46 |
img = Image.open(BytesIO(response.content))
|
47 |
|