Spaces:
Runtime error
Runtime error
Testing image params
Browse files- app.py +3 -1
- funciones.py +1 -1
- sulkuPypi.py +2 -0
app.py
CHANGED
|
@@ -84,12 +84,14 @@ def perform(input1, input2):
|
|
| 84 |
return path, info_window
|
| 85 |
|
| 86 |
label = gr.Label("Hola!")
|
|
|
|
|
|
|
| 87 |
|
| 88 |
demo = gr.Interface(
|
| 89 |
fn=perform,
|
| 90 |
title="",
|
| 91 |
inputs=[gr.Image(), gr.Image()],
|
| 92 |
-
outputs=[gr.Image(),label],
|
| 93 |
css="footer {visibility: hidden}"
|
| 94 |
)
|
| 95 |
demo.launch(auth=authenticate)
|
|
|
|
| 84 |
return path, info_window
|
| 85 |
|
| 86 |
label = gr.Label("Hola!")
|
| 87 |
+
buy = gr.Button("Buy More")
|
| 88 |
+
imagen = gr.Image('source.png', show_download_button=False, visible=False)
|
| 89 |
|
| 90 |
demo = gr.Interface(
|
| 91 |
fn=perform,
|
| 92 |
title="",
|
| 93 |
inputs=[gr.Image(), gr.Image()],
|
| 94 |
+
outputs=[gr.Image(),label, buy, imagen],
|
| 95 |
css="footer {visibility: hidden}"
|
| 96 |
)
|
| 97 |
demo.launch(auth=authenticate)
|
funciones.py
CHANGED
|
@@ -81,7 +81,7 @@ def mass(input1, input2):
|
|
| 81 |
print("source_path: ", source_path)
|
| 82 |
print("target_path: ", target_path)
|
| 83 |
#FUTURE: Agrega por parámetro o mejor aún por enviroment el hecho de si es compu para usar cpu o si es hf para usar cuda.
|
| 84 |
-
command = f"python run.py -s {source_path} -t {target_path} -o {result_path} --frame-processor {procesador} --execution-provider
|
| 85 |
print(command)
|
| 86 |
time.sleep(1)
|
| 87 |
proc = os.popen(command)
|
|
|
|
| 81 |
print("source_path: ", source_path)
|
| 82 |
print("target_path: ", target_path)
|
| 83 |
#FUTURE: Agrega por parámetro o mejor aún por enviroment el hecho de si es compu para usar cpu o si es hf para usar cuda.
|
| 84 |
+
command = f"python run.py -s {source_path} -t {target_path} -o {result_path} --frame-processor {procesador} --execution-provider cpu"
|
| 85 |
print(command)
|
| 86 |
time.sleep(1)
|
| 87 |
proc = os.popen(command)
|
sulkuPypi.py
CHANGED
|
@@ -1,6 +1,8 @@
|
|
| 1 |
import requests
|
| 2 |
import time
|
| 3 |
|
|
|
|
|
|
|
| 4 |
base_url = "https://moibe-sulku-fastapi-docker.hf.space/"
|
| 5 |
userfile = "gAAAAABmEZA4SLBC2YczouOrjIEi9WNCNGOIvyUcqBUnzxNsftXTdy54KaX9x8mAjFkABSI6FJrdZDQKk_5lpJOgJoMChxlniw=="
|
| 6 |
#Ojo, cuando el userfile termina con símbolo igual y supongo que también si empieza, causa problemas, la solución, ...
|
|
|
|
| 1 |
import requests
|
| 2 |
import time
|
| 3 |
|
| 4 |
+
#Sulkupypi será el que en un futuro se volverá un paquete de python que instalarás y en el futuro quizá comercializarás.
|
| 5 |
+
|
| 6 |
base_url = "https://moibe-sulku-fastapi-docker.hf.space/"
|
| 7 |
userfile = "gAAAAABmEZA4SLBC2YczouOrjIEi9WNCNGOIvyUcqBUnzxNsftXTdy54KaX9x8mAjFkABSI6FJrdZDQKk_5lpJOgJoMChxlniw=="
|
| 8 |
#Ojo, cuando el userfile termina con símbolo igual y supongo que también si empieza, causa problemas, la solución, ...
|