Vicky0522 commited on
Commit
d7cdf82
1 Parent(s): e2742f0

Upload item1/source_and_edits/config_multi_chunks.yaml with huggingface_hub

Browse files
item1/source_and_edits/config_multi_chunks.yaml ADDED
@@ -0,0 +1,139 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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_ablation"
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/item1/girl.mp4"
32
+ keyframe_paths:
33
+ - "../datasets/svdedit/item1/edit1.png"
34
+ start_t: 0
35
+ end_t: 8.4
36
+ sample_fps: 2.5
37
+ chunk_size: 11
38
+ overlay_size: 1
39
+ normalize: true
40
+ output_fps: 5
41
+ save_sampled_frame: true
42
+ output_res: [576, 1024]
43
+ pad_to_fit: false
44
+ begin_clip_id: 0
45
+ end_clip_id: 2
46
+
47
+ train_motion_lora_params:
48
+ cache_latents: true
49
+ cached_latent_dir: null #/path/to/cached_latents
50
+ lora_rank: 32
51
+ # Use LoRA for the UNET model.
52
+ use_unet_lora: True
53
+ # LoRA Dropout. This parameter adds the probability of randomly zeros out elements. Helps prevent overfitting.
54
+ # See: https://pytorch.org/docs/stable/generated/torch.nn.Dropout.html
55
+ lora_unet_dropout: 0.1
56
+ # The only time you want this off is if you're doing full LoRA training.
57
+ save_pretrained_model: False
58
+ # Learning rate for AdamW
59
+ learning_rate: 5e-4
60
+ # Weight decay. Higher = more regularization. Lower = closer to dataset.
61
+ adam_weight_decay: 1e-2
62
+ # Maximum number of train steps. Model is saved after training.
63
+ max_train_steps: 300
64
+ # Saves a model every nth step.
65
+ checkpointing_steps: 50
66
+ # How many steps to do for validation if sample_preview is enabled.
67
+ validation_steps: 50
68
+ # Whether or not we want to use mixed precision with accelerate
69
+ mixed_precision: "fp16"
70
+ # Trades VRAM usage for speed. You lose roughly 20% of training speed, but save a lot of VRAM.
71
+ # If you need to save more VRAM, it can also be enabled for the text encoder, but reduces speed x2.
72
+ gradient_checkpointing: True
73
+ image_encoder_gradient_checkpointing: True
74
+
75
+ train_data:
76
+ # The width and height in which you want your training data to be resized to.
77
+ width: 896
78
+ height: 512
79
+ # This will find the closest aspect ratio to your input width and height.
80
+ # For example, 512x512 width and height with a video of resolution 1280x720 will be resized to 512x256
81
+ use_data_aug: ~ #"controlnet"
82
+ pad_to_fit: false
83
+
84
+ validation_data:
85
+ # Whether or not to sample preview during training (Requires more VRAM).
86
+ sample_preview: True
87
+ # The number of frames to sample during validation.
88
+ num_frames: 14
89
+ # Height and width of validation sample.
90
+ width: 1024
91
+ height: 576
92
+ pad_to_fit: false
93
+ # scale of spatial LoRAs, default is 0
94
+ spatial_scale: 0
95
+ # scale of noise prior, i.e. the scale of inversion noises
96
+ noise_prior:
97
+ #- 0.0
98
+ - 1.0
99
+
100
+ sarp_params:
101
+ sarp_noise_scale: 0.005
102
+
103
+ attention_matching_params:
104
+ best_checkpoint_index: 300
105
+ lora_scale: 1.0
106
+ # lora path
107
+ lora_dir: "./cache/item1/train_motion_lora"
108
+ max_guidance_scale: 2.0
109
+
110
+ disk_store: True
111
+ load_attention_store: "./cache/item1/attention_store"
112
+ load_consistency_attention_store: "./cache/item1/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
+ temporal_step_thr: [0.5, 0.8]
126
+ spatial_self_replace_steps: 1.0
127
+ mask_thr: [0.35,0.35]
128
+ spatial_attention_chunk_size: 1
129
+
130
+ long_video_params:
131
+ mode: "skip-interval"
132
+ registered_modules:
133
+ BasicTransformerBlock:
134
+ #- "attn1"
135
+ #- "attn2"
136
+ TemporalBasicTransformerBlock:
137
+ - "attn1"
138
+ #- "attn2"
139
+