Spaces:
Sleeping
Sleeping
Yaron Koresh
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -78,11 +78,10 @@ def generate_random_string(length):
|
|
78 |
return ''.join(random.choice(characters) for _ in range(length))
|
79 |
|
80 |
@spaces.GPU(duration=45)
|
81 |
-
def Piper(_do
|
82 |
try:
|
83 |
retu = pipe(
|
84 |
_do,
|
85 |
-
prompt_2=_do2,
|
86 |
height=448,
|
87 |
width=448,
|
88 |
num_inference_steps=8,
|
@@ -98,10 +97,10 @@ def infer(p1,p2):
|
|
98 |
if p1 == "":
|
99 |
_do = 'beautiful, playful, photographed, highly detailed, realistic elements, dynamic poze, deep field, vivid reasonable coloring, rough texture, high sharpness, highres, best quality, focused'
|
100 |
else if p2 == "":
|
101 |
-
_do = f'{
|
102 |
else:
|
103 |
_do = f'{p2} reduced {p1}, beautiful, playful, photographed, highly detailed, realistic elements, dynamic poze, deep field, vivid reasonable coloring, rough texture, high sharpness, highres, best quality, focused'
|
104 |
-
output = Piper(_do
|
105 |
if output == "":
|
106 |
return output
|
107 |
else:
|
|
|
78 |
return ''.join(random.choice(characters) for _ in range(length))
|
79 |
|
80 |
@spaces.GPU(duration=45)
|
81 |
+
def Piper(_do):
|
82 |
try:
|
83 |
retu = pipe(
|
84 |
_do,
|
|
|
85 |
height=448,
|
86 |
width=448,
|
87 |
num_inference_steps=8,
|
|
|
97 |
if p1 == "":
|
98 |
_do = 'beautiful, playful, photographed, highly detailed, realistic elements, dynamic poze, deep field, vivid reasonable coloring, rough texture, high sharpness, highres, best quality, focused'
|
99 |
else if p2 == "":
|
100 |
+
_do = f'{p1}, beautiful, playful, photographed, highly detailed, realistic elements, dynamic poze, deep field, vivid reasonable coloring, rough texture, high sharpness, highres, best quality, focused'
|
101 |
else:
|
102 |
_do = f'{p2} reduced {p1}, beautiful, playful, photographed, highly detailed, realistic elements, dynamic poze, deep field, vivid reasonable coloring, rough texture, high sharpness, highres, best quality, focused'
|
103 |
+
output = Piper(_do)
|
104 |
if output == "":
|
105 |
return output
|
106 |
else:
|