kundaja-green commited on
Commit
64dddc1
·
1 Parent(s): a723a7c

Update start.sh to use correct model filenames from dedicated repo

Browse files
Files changed (1) hide show
  1. start.sh +17 -26
start.sh CHANGED
@@ -1,55 +1,46 @@
1
  #!/bin/bash
2
- # --- Final Definitive Startup Script (v23.2 - Uses USER-VERIFIED filenames) ---
3
 
4
  set -e
5
  echo "--- Startup Script Initialized ---"
6
 
7
- # --- Define where models will be downloaded ---
8
  MODELS_DIR="/data/models"
9
- mkdir -p $MODELS_DIR # Create the directory if it doesn't exist
 
 
 
 
10
 
11
- # --- Define paths to the model files with CORRECTED names ---
12
  DIT_PATH="$MODELS_DIR/wan2.1_i2v_720p_14B_fp8_e4m3fn.safetensors"
13
  VAE_PATH="$MODELS_DIR/Wan2.1_VAE.pth"
14
- CLIP_PATH="$MODELS_DIR/models_clip_open-clip-xlm-roberta-large-vit-huge-14.pth" # CORRECTED FILENAME
15
- T5_PATH="$MODELS_DIR/models_t5_umt5-xxl-enc-bf16.pth" # CORRECTED FILENAME
16
- OUTPUT_DIR="/data/output"
17
 
18
  # --- Download models from our dedicated model repo IF they don't already exist ---
19
- echo "--- Checking for model files... ---"
20
 
21
  if [ ! -f "$DIT_PATH" ]; then
22
- echo "Downloading DiT model from jujutechnology/WANfortraining..."
23
  huggingface-cli download jujutechnology/WANfortraining wan2.1_i2v_720p_14B_fp8_e4m3fn.safetensors --local-dir $MODELS_DIR --local-dir-use-symlinks False
24
- else
25
- echo "DiT model already exists."
26
  fi
27
-
28
  if [ ! -f "$VAE_PATH" ]; then
29
- echo "Downloading VAE model from jujutechnology/WANfortraining..."
30
  huggingface-cli download jujutechnology/WANfortraining Wan2.1_VAE.pth --local-dir $MODELS_DIR --local-dir-use-symlinks False
31
- else
32
- echo "VAE model already exists."
33
  fi
34
-
35
  if [ ! -f "$CLIP_PATH" ]; then
36
- echo "Downloading CLIP model from jujutechnology/WANfortraining..."
37
- # CORRECTED FILENAME in download command
38
  huggingface-cli download jujutechnology/WANfortraining models_clip_open-clip-xlm-roberta-large-vit-huge-14.pth --local-dir $MODELS_DIR --local-dir-use-symlinks False
39
- else
40
- echo "CLIP model already exists."
41
  fi
42
-
43
  if [ ! -f "$T5_PATH" ]; then
44
- echo "Downloading T5 model from jujutechnology/WANfortraining..."
45
- # CORRECTED FILENAME in download command
46
  huggingface-cli download jujutechnology/WANfortraining models_t5_umt5-xxl-enc-bf16.pth --local-dir $MODELS_DIR --local-dir-use-symlinks False
47
- else
48
- echo "T5 model already exists."
49
  fi
50
 
51
  echo "--- All models are present. Starting training... ---"
52
- ls -lh $MODELS_DIR # List the downloaded files to confirm
53
 
54
  # --- Run the training command ---
55
  accelerate launch wan_train_network.py \
 
1
  #!/bin/bash
2
+ # --- Final Definitive Startup Script (v23.2 - Assumes Persistent Storage is enabled) ---
3
 
4
  set -e
5
  echo "--- Startup Script Initialized ---"
6
 
7
+ # This path is correct ONLY if persistent storage is enabled at /data
8
  MODELS_DIR="/data/models"
9
+ OUTPUT_DIR="/data/output"
10
+
11
+ # Create our subdirectories inside the persistent storage
12
+ mkdir -p $MODELS_DIR
13
+ mkdir -p $OUTPUT_DIR
14
 
15
+ # --- Define paths to the model files ---
16
  DIT_PATH="$MODELS_DIR/wan2.1_i2v_720p_14B_fp8_e4m3fn.safetensors"
17
  VAE_PATH="$MODELS_DIR/Wan2.1_VAE.pth"
18
+ CLIP_PATH="$MODELS_DIR/models_clip_open-clip-xlm-roberta-large-vit-huge-14.pth"
19
+ T5_PATH="$MODELS_DIR/models_t5_umt5-xxl-enc-bf16.pth"
 
20
 
21
  # --- Download models from our dedicated model repo IF they don't already exist ---
22
+ echo "--- Checking for model files in persistent storage... ---"
23
 
24
  if [ ! -f "$DIT_PATH" ]; then
25
+ echo "Downloading DiT model..."
26
  huggingface-cli download jujutechnology/WANfortraining wan2.1_i2v_720p_14B_fp8_e4m3fn.safetensors --local-dir $MODELS_DIR --local-dir-use-symlinks False
 
 
27
  fi
28
+ # ... (rest of the download checks are the same) ...
29
  if [ ! -f "$VAE_PATH" ]; then
30
+ echo "Downloading VAE model..."
31
  huggingface-cli download jujutechnology/WANfortraining Wan2.1_VAE.pth --local-dir $MODELS_DIR --local-dir-use-symlinks False
 
 
32
  fi
 
33
  if [ ! -f "$CLIP_PATH" ]; then
34
+ echo "Downloading CLIP model..."
 
35
  huggingface-cli download jujutechnology/WANfortraining models_clip_open-clip-xlm-roberta-large-vit-huge-14.pth --local-dir $MODELS_DIR --local-dir-use-symlinks False
 
 
36
  fi
 
37
  if [ ! -f "$T5_PATH" ]; then
38
+ echo "Downloading T5 model..."
 
39
  huggingface-cli download jujutechnology/WANfortraining models_t5_umt5-xxl-enc-bf16.pth --local-dir $MODELS_DIR --local-dir-use-symlinks False
 
 
40
  fi
41
 
42
  echo "--- All models are present. Starting training... ---"
43
+ ls -lh $MODELS_DIR
44
 
45
  # --- Run the training command ---
46
  accelerate launch wan_train_network.py \