mirror of
https://github.com/storytold/FineTrainers-Conditioning.git
synced 2026-10-27 08:47:10 +00:00
Full Finetuning for LTX possibily extended to other models. (#192)
* Full Finetuning for LTX possibily extended to other models. * Change name of the flag * Used disable grad for component on lora fine tuning enabled * Suggestions Addressed Renamed to SFT Added 2 other models. Testing required. * Switching to Full FineTuning * Run linter. * parse subfolder when needed. * tackle saving and loading hooks. * tackle validation. * fix subfolder bug. * remove __class__. * refactor * remove unnecessary changes * handle saving of final model weights correctly * remove unnecessary changes * LTX uses a default frame rate of 24 FPS We need to modify the output validation framerate to match that value. Add Framerate args. Add Update video output and inference frame rate * There was a results_args mapping that needed to be modified. * update * update README * Update README.md * update docs * add training configuration in cogvideox --------- Co-authored-by: Sayak Paul <spsayakpaul@gmail.com> Co-authored-by: Aryan <aryan@huggingface.co> Co-authored-by: Aryan <contact.aryanvs@gmail.com>
This commit is contained in:
@@ -2,6 +2,8 @@
|
||||
|
||||
## Training
|
||||
|
||||
For LoRA training, specify `--training_type lora`. For full finetuning, specify `--training_type full-finetune`.
|
||||
|
||||
```bash
|
||||
#!/bin/bash
|
||||
|
||||
@@ -87,6 +89,8 @@ echo -ne "-------------------- Finished executing script --------------------\n\
|
||||
|
||||
## Memory Usage
|
||||
|
||||
### LoRA
|
||||
|
||||
LoRA with rank 128, batch size 1, gradient checkpointing, optimizer adamw, `49x512x768` resolutions, **without precomputation**:
|
||||
|
||||
```
|
||||
@@ -139,6 +143,10 @@ Training configuration: {
|
||||
|
||||
Note: requires about `47` GB of VRAM with validation. If validation is not performed, the memory usage is reduced to about `42` GB.
|
||||
|
||||
### Full finetuning
|
||||
|
||||
Current, full finetuning is not supported for HunyuanVideo. It goes out of memory (OOM) for `49x512x768` resolutions.
|
||||
|
||||
## Inference
|
||||
|
||||
Assuming your LoRA is saved and pushed to the HF Hub, and named `my-awesome-name/my-awesome-lora`, we can now use the finetuned model for inference:
|
||||
|
||||
Reference in New Issue
Block a user