Spaces:
Running
Running
Yaron Koresh
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -85,6 +85,8 @@ def Piper(name,posi):
|
|
85 |
)
|
86 |
ret1.images[0].save(name)
|
87 |
|
|
|
|
|
88 |
css="""
|
89 |
input, input::placeholder {
|
90 |
text-align: center !important;
|
@@ -134,9 +136,7 @@ def infer(p):
|
|
134 |
_do.append(f'{p1}')
|
135 |
posi = " ".join(_do)
|
136 |
|
137 |
-
Piper(name,posi)
|
138 |
-
|
139 |
-
return name
|
140 |
|
141 |
def run(p1,*result):
|
142 |
|
@@ -147,7 +147,7 @@ def run(p1,*result):
|
|
147 |
rng = list(range(ln))
|
148 |
|
149 |
arr = [p for _ in rng]
|
150 |
-
pool = Pool()
|
151 |
out = list(pool.imap(infer,arr))
|
152 |
pool.close()
|
153 |
pool.join()
|
|
|
85 |
)
|
86 |
ret1.images[0].save(name)
|
87 |
|
88 |
+
return name
|
89 |
+
|
90 |
css="""
|
91 |
input, input::placeholder {
|
92 |
text-align: center !important;
|
|
|
136 |
_do.append(f'{p1}')
|
137 |
posi = " ".join(_do)
|
138 |
|
139 |
+
return Piper(name,posi)
|
|
|
|
|
140 |
|
141 |
def run(p1,*result):
|
142 |
|
|
|
147 |
rng = list(range(ln))
|
148 |
|
149 |
arr = [p for _ in rng]
|
150 |
+
pool = Pool(ln)
|
151 |
out = list(pool.imap(infer,arr))
|
152 |
pool.close()
|
153 |
pool.join()
|