animesh007
commited on
Commit
•
f944859
1
Parent(s):
73b9008
Update app.py
Browse files
app.py
CHANGED
@@ -18,7 +18,7 @@ DESCRIPTION = '''### Gradio demo for <b>Thin-Plate Spline Motion Model for Image
|
|
18 |
|
19 |
<img id="overview" alt="overview" src="https://github.com/yoyo-nb/Thin-Plate-Spline-Motion-Model/raw/main/assets/vox.gif" />
|
20 |
'''
|
21 |
-
FOOTER = '<img id="visitor-badge" alt="visitor badge" src="https://visitor-badge.glitch.me/badge?page_id=gradio-blocks.
|
22 |
|
23 |
|
24 |
def get_style_image_path(style_name: str) -> str:
|
@@ -51,7 +51,7 @@ def inference(img,vid):
|
|
51 |
os.system('mkdir temp')
|
52 |
|
53 |
img.save("temp/image.jpg", "JPEG")
|
54 |
-
os.system(f"python demo.py --config config/vox-256.yaml --checkpoint ./checkpoints/vox.pth.tar --source_image 'temp/image.jpg' --driving_video {vid} --result_video './temp/result.mp4'")
|
55 |
return './temp/result.mp4'
|
56 |
|
57 |
|
|
|
18 |
|
19 |
<img id="overview" alt="overview" src="https://github.com/yoyo-nb/Thin-Plate-Spline-Motion-Model/raw/main/assets/vox.gif" />
|
20 |
'''
|
21 |
+
FOOTER = '<img id="visitor-badge" alt="visitor badge" src="https://visitor-badge.glitch.me/badge?page_id=gradio-blocks.Image-Animation-using-Thin-Plate-Spline-Motion-Model" />'
|
22 |
|
23 |
|
24 |
def get_style_image_path(style_name: str) -> str:
|
|
|
51 |
os.system('mkdir temp')
|
52 |
|
53 |
img.save("temp/image.jpg", "JPEG")
|
54 |
+
os.system(f"python demo.py --config config/vox-256.yaml --checkpoint ./checkpoints/vox.pth.tar --source_image 'temp/image.jpg' --driving_video {vid} --result_video './temp/result.mp4' --cpu")
|
55 |
return './temp/result.mp4'
|
56 |
|
57 |
|