Spaces:
Running
Running
Yaron Koresh
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -59,7 +59,7 @@ def generate_random_string(length):
|
|
59 |
return ''.join(random.choice(characters) for _ in range(length))
|
60 |
|
61 |
@spaces.GPU
|
62 |
-
def Pipe(english_prompt
|
63 |
return Pipe(
|
64 |
english_prompt,
|
65 |
height=192,
|
@@ -73,7 +73,7 @@ def infer(prompt):
|
|
73 |
name = generate_random_string(12)+".png"
|
74 |
english_prompt = f'TRUE {translate(prompt,"english").upper()}:'
|
75 |
print(f'Final prompt: {english_prompt}')
|
76 |
-
image = Pipe(english_prompt
|
77 |
return name
|
78 |
|
79 |
css="""
|
|
|
59 |
return ''.join(random.choice(characters) for _ in range(length))
|
60 |
|
61 |
@spaces.GPU
|
62 |
+
def Pipe(english_prompt):
|
63 |
return Pipe(
|
64 |
english_prompt,
|
65 |
height=192,
|
|
|
73 |
name = generate_random_string(12)+".png"
|
74 |
english_prompt = f'TRUE {translate(prompt,"english").upper()}:'
|
75 |
print(f'Final prompt: {english_prompt}')
|
76 |
+
image = Pipe(english_prompt).images[0].save(name)
|
77 |
return name
|
78 |
|
79 |
css="""
|