Vicky0522 commited on
Commit
ad97abc
1 Parent(s): 8427d6d

Upload item3/config_multi_chunks.yaml with huggingface_hub

Browse files
Files changed (1) hide show
  1. item3/config_multi_chunks.yaml +151 -0
item3/config_multi_chunks.yaml ADDED
@@ -0,0 +1,151 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Pretrained diffusers model path.
2
+ pretrained_model_path: "ckpts/stable-video-diffusion-img2vid"
3
+ # The folder where your training outputs will be placed.
4
+ output_dir: "./sig_girl"
5
+ seed: 23
6
+ num_steps: 25
7
+ # Xformers must be installed for best memory savings and performance (< Pytorch 2.0)
8
+ enable_xformers_memory_efficient_attention: True
9
+ # Use scaled dot product attention (Only available with >= Torch 2.0)
10
+ enable_torch_2_attn: True
11
+
12
+ use_sarp: true
13
+
14
+ use_motion_lora: true
15
+ train_motion_lora_only: false
16
+ retrain_motion_lora: false
17
+
18
+ use_inversed_latents: true
19
+ use_attention_matching: true
20
+ use_consistency_attention_control: true
21
+ dtype: fp16
22
+
23
+ visualize_attention_store: false
24
+ visualize_attention_store_steps: [0, 5, 10, 15, 20, 24]
25
+
26
+ save_last_frames: True
27
+ load_from_last_frames_latents:
28
+
29
+ # data_params
30
+ data_params:
31
+ video_path: "../datasets/svdedit/item3/source.mp4"
32
+ keyframe_paths:
33
+ - "../datasets/svdedit/item3/cyberpunk.png"
34
+ - "../datasets/svdedit/item3/hat.png"
35
+ - "../datasets/svdedit/item3/shinkai.png"
36
+ - "../datasets/svdedit/item3/tshirt.png"
37
+ start_t: 0
38
+ end_t: -1
39
+ sample_fps: 7
40
+ chunk_size: 16
41
+ overlay_size: 1
42
+ normalize: true
43
+ output_fps: 7
44
+ save_sampled_frame: true
45
+ output_res: [576, 1024]
46
+ pad_to_fit: false
47
+
48
+ train_motion_lora_params:
49
+ cache_latents: true
50
+ cached_latent_dir: null #/path/to/cached_latents
51
+ lora_rank: 32
52
+ # Use LoRA for the UNET model.
53
+ use_unet_lora: True
54
+ # LoRA Dropout. This parameter adds the probability of randomly zeros out elements. Helps prevent overfitting.
55
+ # See: https://pytorch.org/docs/stable/generated/torch.nn.Dropout.html
56
+ lora_unet_dropout: 0.1
57
+ # The only time you want this off is if you're doing full LoRA training.
58
+ save_pretrained_model: False
59
+ # Learning rate for AdamW
60
+ learning_rate: 5e-4
61
+ # Weight decay. Higher = more regularization. Lower = closer to dataset.
62
+ adam_weight_decay: 1e-2
63
+ # Maximum number of train steps. Model is saved after training.
64
+ max_train_steps: 250
65
+ # Saves a model every nth step.
66
+ checkpointing_steps: 250
67
+ # How many steps to do for validation if sample_preview is enabled.
68
+ validation_steps: 300
69
+ # Whether or not we want to use mixed precision with accelerate
70
+ mixed_precision: "fp16"
71
+ # Trades VRAM usage for speed. You lose roughly 20% of training speed, but save a lot of VRAM.
72
+ # If you need to save more VRAM, it can also be enabled for the text encoder, but reduces speed x2.
73
+ gradient_checkpointing: True
74
+ image_encoder_gradient_checkpointing: True
75
+
76
+ train_data:
77
+ # The width and height in which you want your training data to be resized to.
78
+ width: 896
79
+ height: 512
80
+ # This will find the closest aspect ratio to your input width and height.
81
+ # For example, 512x512 width and height with a video of resolution 1280x720 will be resized to 512x256
82
+ use_data_aug: ~ #"controlnet"
83
+ pad_to_fit: false
84
+
85
+ validation_data:
86
+ # Whether or not to sample preview during training (Requires more VRAM).
87
+ sample_preview: True
88
+ # The number of frames to sample during validation.
89
+ num_frames: 14
90
+ # Height and width of validation sample.
91
+ width: 1024
92
+ height: 576
93
+ pad_to_fit: false
94
+ # scale of spatial LoRAs, default is 0
95
+ spatial_scale: 0
96
+ # scale of noise prior, i.e. the scale of inversion noises
97
+ noise_prior:
98
+ #- 0.0
99
+ - 1.0
100
+
101
+ sarp_params:
102
+ sarp_noise_scale: 0.005
103
+
104
+ attention_matching_params:
105
+ best_checkpoint_index: 250
106
+ lora_scale: 1.0
107
+ # lora path
108
+ lora_dir: "./cache/item3/train_motion_lora/"
109
+ max_guidance_scale: 2.0
110
+ disk_store: True
111
+ load_attention_store: "./cache/item3/attention_store"
112
+ load_consistency_attention_store: "./cache/item3/consistency_attention_store"
113
+ registered_modules:
114
+ BasicTransformerBlock:
115
+ - "attn1"
116
+ #- "attn2"
117
+ TemporalBasicTransformerBlock:
118
+ - "attn1"
119
+ #- "attn2"
120
+ control_mode:
121
+ spatial_self: "masked_copy"
122
+ temporal_self: "copy_v2"
123
+ cross_replace_steps: 0.0
124
+ temporal_self_replace_steps: 1.0
125
+ spatial_self_replace_steps: 1.0
126
+ spatial_attention_chunk_size: 1
127
+
128
+ params:
129
+ edit0:
130
+ temporal_step_thr: [0.4, 0.5]
131
+ mask_thr: [0.35, 0.35]
132
+ edit1:
133
+ temporal_step_thr: [0.5, 0.8]
134
+ mask_thr: [0.35, 0.35]
135
+ edit2:
136
+ temporal_step_thr: [0.5, 0.8]
137
+ mask_thr: [0.35, 0.35]
138
+ edit3:
139
+ temporal_step_thr: [0.5, 0.8]
140
+ mask_thr: [0.35, 0.35]
141
+
142
+ long_video_params:
143
+ mode: "skip-interval"
144
+ registered_modules:
145
+ BasicTransformerBlock:
146
+ #- "attn1"
147
+ #- "attn2"
148
+ TemporalBasicTransformerBlock:
149
+ - "attn1"
150
+ #- "attn2"
151
+