Hugging Face
Models
Datasets
Spaces
Posts
Docs
Enterprise
Pricing
Log In
Sign Up
Spaces:
Duplicated from
vinthony/SadTalker
John6666
/
SadTalker
like
3
Sleeping
App
Files
Files
Community
3
488e66f
SadTalker
/
src
/
utils
/
safetensor_helper.py
shadowcun
new version of sadtalker
9ab094a
over 1 year ago
raw
Copy download link
history
blame
Safe
198 Bytes
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