Spaces:
Sleeping
Sleeping
fixed resize mode
Browse files- .gitignore +3 -1
- README.md +1 -1
- modules/__pycache__/sadtalker_test.cpython-38.pyc +0 -0
- modules/sadtalker_test.py +1 -1
.gitignore
CHANGED
@@ -150,4 +150,6 @@ dmypy.json
|
|
150 |
.pytype/
|
151 |
|
152 |
# Cython debug symbols
|
153 |
-
cython_debug/
|
|
|
|
|
|
150 |
.pytype/
|
151 |
|
152 |
# Cython debug symbols
|
153 |
+
cython_debug/
|
154 |
+
|
155 |
+
results/
|
README.md
CHANGED
@@ -4,7 +4,7 @@ emoji: 😭
|
|
4 |
colorFrom: purple
|
5 |
colorTo: green
|
6 |
sdk: gradio
|
7 |
-
sdk_version: 3.
|
8 |
app_file: app.py
|
9 |
pinned: false
|
10 |
license: mit
|
|
|
4 |
colorFrom: purple
|
5 |
colorTo: green
|
6 |
sdk: gradio
|
7 |
+
sdk_version: 3.23.0
|
8 |
app_file: app.py
|
9 |
pinned: false
|
10 |
license: mit
|
modules/__pycache__/sadtalker_test.cpython-38.pyc
CHANGED
Binary files a/modules/__pycache__/sadtalker_test.cpython-38.pyc and b/modules/__pycache__/sadtalker_test.cpython-38.pyc differ
|
|
modules/sadtalker_test.py
CHANGED
@@ -89,7 +89,7 @@ class SadTalker():
|
|
89 |
#crop image and extract 3dmm from image
|
90 |
first_frame_dir = os.path.join(save_dir, 'first_frame_dir')
|
91 |
os.makedirs(first_frame_dir, exist_ok=True)
|
92 |
-
first_coeff_path, crop_pic_path, original_size = self.preprocess_model.generate(pic_path, first_frame_dir, crop_or_resize= '
|
93 |
if first_coeff_path is None:
|
94 |
raise AttributeError("No face is detected")
|
95 |
|
|
|
89 |
#crop image and extract 3dmm from image
|
90 |
first_frame_dir = os.path.join(save_dir, 'first_frame_dir')
|
91 |
os.makedirs(first_frame_dir, exist_ok=True)
|
92 |
+
first_coeff_path, crop_pic_path, original_size = self.preprocess_model.generate(pic_path, first_frame_dir, crop_or_resize= 'resize' if resize_mode else 'crop')
|
93 |
if first_coeff_path is None:
|
94 |
raise AttributeError("No face is detected")
|
95 |
|