mirror of
https://github.com/storytold/storyteller-ml.git
synced 2026-10-18 00:33:15 +00:00
2d2b25d5a6
MIT license Commit: https://github.com/OpenTalker/SadTalker commit ae0b26359d44c9379450a8e02a38b45eeec15549 (HEAD -> main, origin/main, origin/HEAD) Author: shadowcun <shadowcun@tencent.com> Date: Mon Jul 3 13:48:35 2023 +0800 fixed bug: hacking facexlib of FAN
8 lines
198 B
Python
8 lines
198 B
Python
|
|
|
|
def load_x_from_safetensor(checkpoint, key):
|
|
x_generator = {}
|
|
for k,v in checkpoint.items():
|
|
if key in k:
|
|
x_generator[k.replace(key+'.', '')] = v
|
|
return x_generator |