mirror of
https://github.com/TMElyralab/MuseTalk.git
synced 2026-02-04 09:29:20 +08:00
fix: download_weights.sh (#318)
Fixed wrong mkdir syntax, wrong install location of face-parse-bisent and improve readability
This commit is contained in:
@@ -4,34 +4,48 @@
|
|||||||
CheckpointsDir="models"
|
CheckpointsDir="models"
|
||||||
|
|
||||||
# Create necessary directories
|
# Create necessary directories
|
||||||
mkdir -p $CheckpointsDir/{musetalk,musetalkV15,syncnet,dwpose,face-parse-bisent,sd-vae-ft-mse,whisper}
|
mkdir -p models/musetalk models/musetalkV15 models/syncnet models/dwpose models/face-parse-bisent models/sd-vae models/whisper
|
||||||
|
|
||||||
# Install required packages
|
# Install required packages
|
||||||
pip install -U "huggingface_hub[cli]"
|
pip install -U "huggingface_hub[cli]"
|
||||||
pip install gdown
|
pip install gdown
|
||||||
|
|
||||||
# Set HuggingFace endpoint
|
# Set HuggingFace mirror endpoint
|
||||||
export HF_ENDPOINT=https://hf-mirror.com
|
export HF_ENDPOINT=https://hf-mirror.com
|
||||||
|
|
||||||
# Download MuseTalk weights
|
# Download MuseTalk V1.0 weights
|
||||||
huggingface-cli download TMElyralab/MuseTalk --local-dir $CheckpointsDir
|
huggingface-cli download TMElyralab/MuseTalk \
|
||||||
|
--local-dir $CheckpointsDir \
|
||||||
|
--include "musetalk/musetalk.json" "musetalk/pytorch_model.bin"
|
||||||
|
|
||||||
|
# Download MuseTalk V1.5 weights (unet.pth)
|
||||||
|
huggingface-cli download TMElyralab/MuseTalk \
|
||||||
|
--local-dir $CheckpointsDir \
|
||||||
|
--include "musetalkV15/musetalk.json" "musetalkV15/unet.pth"
|
||||||
|
|
||||||
# Download SD VAE weights
|
# Download SD VAE weights
|
||||||
huggingface-cli download stabilityai/sd-vae-ft-mse --local-dir $CheckpointsDir/sd-vae --include "config.json" "diffusion_pytorch_model.bin"
|
huggingface-cli download stabilityai/sd-vae-ft-mse \
|
||||||
|
--local-dir $CheckpointsDir/sd-vae \
|
||||||
|
--include "config.json" "diffusion_pytorch_model.bin"
|
||||||
|
|
||||||
# Download Whisper weights
|
# Download Whisper weights
|
||||||
huggingface-cli download openai/whisper-tiny --local-dir $CheckpointsDir/whisper --include "config.json" "pytorch_model.bin" "preprocessor_config.json"
|
huggingface-cli download openai/whisper-tiny \
|
||||||
|
--local-dir $CheckpointsDir/whisper \
|
||||||
|
--include "config.json" "pytorch_model.bin" "preprocessor_config.json"
|
||||||
|
|
||||||
# Download DWPose weights
|
# Download DWPose weights
|
||||||
huggingface-cli download yzd-v/DWPose --local-dir $CheckpointsDir/dwpose --include "dw-ll_ucoco_384.pth"
|
huggingface-cli download yzd-v/DWPose \
|
||||||
|
--local-dir $CheckpointsDir/dwpose \
|
||||||
|
--include "dw-ll_ucoco_384.pth"
|
||||||
|
|
||||||
# Download SyncNet weights
|
# Download SyncNet weights
|
||||||
huggingface-cli download ByteDance/LatentSync --local-dir $CheckpointsDir/syncnet --include "latentsync_syncnet.pt"
|
huggingface-cli download ByteDance/LatentSync \
|
||||||
|
--local-dir $CheckpointsDir/syncnet \
|
||||||
|
--include "latentsync_syncnet.pt"
|
||||||
|
|
||||||
# Download Face Parse Bisent weights (using gdown)
|
# Download Face Parse Bisent weights
|
||||||
gdown --id 154JgKpzCPW82qINcVieuPH3fZ2e0P812 -O $CheckpointsDir/face-parse-bisent/79999_iter.pth
|
gdown --id 154JgKpzCPW82qINcVieuPH3fZ2e0P812 -O $CheckpointsDir/face-parse-bisent/79999_iter.pth
|
||||||
|
curl -L https://download.pytorch.org/models/resnet18-5c106cde.pth \
|
||||||
|
-o $CheckpointsDir/face-parse-bisent/resnet18-5c106cde.pth
|
||||||
|
|
||||||
# Download ResNet weights
|
echo "✅ All weights have been downloaded successfully!"
|
||||||
curl -L https://download.pytorch.org/models/resnet18-5c106cde.pth -o $CheckpointsDir/face-parse-bisent/resnet18-5c106cde.pth
|
|
||||||
|
|
||||||
echo "All weights have been downloaded successfully!"
|
|
||||||
|
|||||||
Reference in New Issue
Block a user