Spaces:
Running
on
T4
Running
on
T4
Update app.py
Browse files
app.py
CHANGED
@@ -3,10 +3,10 @@ import subprocess
|
|
3 |
|
4 |
def generate(image, prompt, seed):
|
5 |
print(image, prompt, seed)
|
6 |
-
command = f"python handrefiner.py --input_img {image} --out_dir /content/HandRefiner/output --strength 0.55 --weights
|
7 |
try:
|
8 |
result = subprocess.run(command, shell=True, check=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE, text=True)
|
9 |
-
output_path = '
|
10 |
print("Output:", result.stdout)
|
11 |
return output_path
|
12 |
except subprocess.CalledProcessError as e:
|
|
|
3 |
|
4 |
def generate(image, prompt, seed):
|
5 |
print(image, prompt, seed)
|
6 |
+
command = f"python handrefiner.py --input_img {image} --out_dir /content/HandRefiner/output --strength 0.55 --weights models/inpaint_depth_control.ckpt --prompt '{prompt}' --seed {seed}"
|
7 |
try:
|
8 |
result = subprocess.run(command, shell=True, check=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE, text=True)
|
9 |
+
output_path = 'output/image_0.jpg'
|
10 |
print("Output:", result.stdout)
|
11 |
return output_path
|
12 |
except subprocess.CalledProcessError as e:
|