Wei Lin Liu commited on
Commit
f4029a8
·
unverified ·
1 Parent(s): b6de2a7

fix: download_weights.sh (#318)

Browse files

Fixed wrong mkdir syntax, wrong install location of face-parse-bisent and improve readability

Files changed (1) hide show
  1. download_weights.sh +27 -13
download_weights.sh CHANGED
@@ -4,34 +4,48 @@
4
  CheckpointsDir="models"
5
 
6
  # Create necessary directories
7
- mkdir -p $CheckpointsDir/{musetalk,musetalkV15,syncnet,dwpose,face-parse-bisent,sd-vae-ft-mse,whisper}
8
 
9
  # Install required packages
10
  pip install -U "huggingface_hub[cli]"
11
  pip install gdown
12
 
13
- # Set HuggingFace endpoint
14
  export HF_ENDPOINT=https://hf-mirror.com
15
 
16
- # Download MuseTalk weights
17
- huggingface-cli download TMElyralab/MuseTalk --local-dir $CheckpointsDir
 
 
 
 
 
 
 
18
 
19
  # Download SD VAE weights
20
- huggingface-cli download stabilityai/sd-vae-ft-mse --local-dir $CheckpointsDir/sd-vae --include "config.json" "diffusion_pytorch_model.bin"
 
 
21
 
22
  # Download Whisper weights
23
- huggingface-cli download openai/whisper-tiny --local-dir $CheckpointsDir/whisper --include "config.json" "pytorch_model.bin" "preprocessor_config.json"
 
 
24
 
25
  # Download DWPose weights
26
- huggingface-cli download yzd-v/DWPose --local-dir $CheckpointsDir/dwpose --include "dw-ll_ucoco_384.pth"
 
 
27
 
28
  # Download SyncNet weights
29
- huggingface-cli download ByteDance/LatentSync --local-dir $CheckpointsDir/syncnet --include "latentsync_syncnet.pt"
 
 
30
 
31
- # Download Face Parse Bisent weights (using gdown)
32
  gdown --id 154JgKpzCPW82qINcVieuPH3fZ2e0P812 -O $CheckpointsDir/face-parse-bisent/79999_iter.pth
 
 
33
 
34
- # Download ResNet weights
35
- curl -L https://download.pytorch.org/models/resnet18-5c106cde.pth -o $CheckpointsDir/face-parse-bisent/resnet18-5c106cde.pth
36
-
37
- echo "All weights have been downloaded successfully!"
 
4
  CheckpointsDir="models"
5
 
6
  # Create necessary directories
7
+ mkdir -p models/musetalk models/musetalkV15 models/syncnet models/dwpose models/face-parse-bisent models/sd-vae models/whisper
8
 
9
  # Install required packages
10
  pip install -U "huggingface_hub[cli]"
11
  pip install gdown
12
 
13
+ # Set HuggingFace mirror endpoint
14
  export HF_ENDPOINT=https://hf-mirror.com
15
 
16
+ # Download MuseTalk V1.0 weights
17
+ huggingface-cli download TMElyralab/MuseTalk \
18
+ --local-dir $CheckpointsDir \
19
+ --include "musetalk/musetalk.json" "musetalk/pytorch_model.bin"
20
+
21
+ # Download MuseTalk V1.5 weights (unet.pth)
22
+ huggingface-cli download TMElyralab/MuseTalk \
23
+ --local-dir $CheckpointsDir \
24
+ --include "musetalkV15/musetalk.json" "musetalkV15/unet.pth"
25
 
26
  # Download SD VAE weights
27
+ huggingface-cli download stabilityai/sd-vae-ft-mse \
28
+ --local-dir $CheckpointsDir/sd-vae \
29
+ --include "config.json" "diffusion_pytorch_model.bin"
30
 
31
  # Download Whisper weights
32
+ huggingface-cli download openai/whisper-tiny \
33
+ --local-dir $CheckpointsDir/whisper \
34
+ --include "config.json" "pytorch_model.bin" "preprocessor_config.json"
35
 
36
  # Download DWPose weights
37
+ huggingface-cli download yzd-v/DWPose \
38
+ --local-dir $CheckpointsDir/dwpose \
39
+ --include "dw-ll_ucoco_384.pth"
40
 
41
  # Download SyncNet weights
42
+ huggingface-cli download ByteDance/LatentSync \
43
+ --local-dir $CheckpointsDir/syncnet \
44
+ --include "latentsync_syncnet.pt"
45
 
46
+ # Download Face Parse Bisent weights
47
  gdown --id 154JgKpzCPW82qINcVieuPH3fZ2e0P812 -O $CheckpointsDir/face-parse-bisent/79999_iter.pth
48
+ curl -L https://download.pytorch.org/models/resnet18-5c106cde.pth \
49
+ -o $CheckpointsDir/face-parse-bisent/resnet18-5c106cde.pth
50
 
51
+ echo "✅ All weights have been downloaded successfully!"