v1.0
版本发布时间: 2024-09-03 04:57:51
bghira/SimpleTuner最新发布版本:v1.1.1(2024-10-05 08:37:33)
Everything has changed! And yet, nothing has. Some defaults may. No, will - be different. It's hard to know which ones.
For those who can do so, it's recommended to use configure.py
to reconfigure your environment on this new release.
It should go without saying, but for those in the middle of a training run, do not upgrade to this release until you finish.
Refactoring and Enhancements:
-
Refactor
train.py
into a Trainer Class:- The core logic of
train.py
has been restructured into aTrainer
class, improving modularity and maintainability. - Exposes an SDK for reuse elsewhere.
- The core logic of
-
Model Family Unification:
- References to specific model types (
--sd3
,--flux
, etc.) have been replaced with a unified--model_family
argument, streamlining model specification and reducing clutter in configurations.
- References to specific model types (
-
Configuration System Overhaul:
- Switched from
.env
configuration files to JSON (config.json
), with multiple backends supporting JSON configuration loading. This allows more flexible and readable configuration management. - Updated the configuration loader to auto-detect the best backend when launching.
- Switched from
-
Enhanced Argument Handling:
- Deprecated old argument references and moved argument parsing to
helpers/configuration/cmd_args.py
for better organization. - Introduced support for new arguments such as
--model_card_safe_for_work
,--flux_schedule_shift
, and--disable_bucket_pruning
.
- Deprecated old argument references and moved argument parsing to
-
Improved Hugging Face Integration:
- Modified
configure.py
to avoid asking for Hugging Face model name details unless required. - Added the ability to pass the SFW (safe-for-work) argument into the training script.
- Modified
-
Optimizations and Bug Fixes:
- Fixed several references to learning rate (lr) initialization and corrected
--optimizer
usage. - Addressed issues with attention masks swapping and fixed the persistence of text encoders in RAM after refactoring.
- Fixed several references to learning rate (lr) initialization and corrected
-
Training and Validation Enhancements:
- Added better dataset examples with support for multiple resolutions and mixed configurations.
- Configured training scripts to disable gradient accumulation steps by default and provided better control over training options via the updated config files.
-
Enhanced Logging and Monitoring:
- Improved the handling of Weights & Biases (wandb) logs and updated tracker argument references.
-
Documentation Updates:
- Revised documentation to reflect changes in model family handling, argument updates, and configuration management.
- Added guidance on setting up the new configuration files and examples for multi-resolution datasets.
-
Miscellaneous Improvements:
- Enabled support for NSFW tags in model cards enabled by default.
- Updated
train.sh
to minimal requirements, reducing complexity and streamlining the training process.
More detailed change log
- lycoris model card updates by @bghira in https://github.com/bghira/SimpleTuner/pull/820
- Generate and store attention masks for T5 for flux by @AmericanPresidentJimmyCarter in https://github.com/bghira/SimpleTuner/pull/821
- Fix validation by @AmericanPresidentJimmyCarter in https://github.com/bghira/SimpleTuner/pull/822
- backwards-compatible flux embedding cache masks by @bghira in https://github.com/bghira/SimpleTuner/pull/823
- merge by @bghira in https://github.com/bghira/SimpleTuner/pull/824
- parquet add width and height columns by @frankchieng in https://github.com/bghira/SimpleTuner/pull/825
- quanto: remove warnings about int8/fp8 confusion as it happened so long ago now; add warning about int4 by @bghira in https://github.com/bghira/SimpleTuner/pull/826
- remove clip warning by @bghira in https://github.com/bghira/SimpleTuner/pull/827
- update lycoris to dev branch, 3.0.1dev3 by @bghira in https://github.com/bghira/SimpleTuner/pull/828
- Fix caption_with_blip3.py on CUDA by @anhi in https://github.com/bghira/SimpleTuner/pull/833
- fix quanto resuming by @bghira in https://github.com/bghira/SimpleTuner/pull/834
- lycoris: resume should use less vram now by @bghira in https://github.com/bghira/SimpleTuner/pull/835
- (#644) temporarily block training on multi-gpu setup with quanto + PEFT, inform user to go with lycoris instead by @bghira in https://github.com/bghira/SimpleTuner/pull/837
- quanto + deepspeed minor fixes for multigpu training by @bghira in https://github.com/bghira/SimpleTuner/pull/839
- deepspeed sharding by @bghira in https://github.com/bghira/SimpleTuner/pull/840
- fix: only run save full model on main process by @ErwannMillon in https://github.com/bghira/SimpleTuner/pull/838
- merge by @bghira in https://github.com/bghira/SimpleTuner/pull/841
- clean-up by @bghira in https://github.com/bghira/SimpleTuner/pull/842
- follow-up fixes for quanto limitation on multigpu by @bghira in https://github.com/bghira/SimpleTuner/pull/846
- merge by @bghira in https://github.com/bghira/SimpleTuner/pull/850
- (#851) remove shard merge code on load hook by @bghira in https://github.com/bghira/SimpleTuner/pull/853
- csv backend updates by @williamzhuk in https://github.com/bghira/SimpleTuner/pull/645
- csv fixes by @bghira in https://github.com/bghira/SimpleTuner/pull/856
- add schedulefree optim w/ kahan summation by @bghira in https://github.com/bghira/SimpleTuner/pull/857
- merge by @bghira in https://github.com/bghira/SimpleTuner/pull/858
- merge by @bghira in https://github.com/bghira/SimpleTuner/pull/861
- schedulefree: return to previous stable settings and add a new preset for aggressive training by @bghira in https://github.com/bghira/SimpleTuner/pull/862
- fix validation image filename only using resolution from first img, and, unreadable/untypeable parenthesis by @bghira in https://github.com/bghira/SimpleTuner/pull/863
- (#519) add side by side comparison with base model by @bghira in https://github.com/bghira/SimpleTuner/pull/865
- merge fixes by @bghira in https://github.com/bghira/SimpleTuner/pull/870
- (#864) add flux final export for full tune by @bghira in https://github.com/bghira/SimpleTuner/pull/871
- wandb gallery mode by @bghira in https://github.com/bghira/SimpleTuner/pull/872
- sdxl: dtype inference followup fix by @bghira in https://github.com/bghira/SimpleTuner/pull/873
- merge by @bghira in https://github.com/bghira/SimpleTuner/pull/878
- combine the vae cache clear logic with bucket rebuild logic by @bghira in https://github.com/bghira/SimpleTuner/pull/879
- flux: mobius-style training via augmented guidance scale by @bghira in https://github.com/bghira/SimpleTuner/pull/880
- track flux cfg via wandb by @bghira in https://github.com/bghira/SimpleTuner/pull/881
- multigpu VAE cache rebuild fixes; random crop auto-rebuild; mobius flux; json backend now renamed to discovery ; wandb guidance tracking by @bghira in https://github.com/bghira/SimpleTuner/pull/888
- fixing typo in flux document for preserve_data_backend_cache key by @riffmaster-2001 in https://github.com/bghira/SimpleTuner/pull/882
- reintroduce timestep dependent shift as an option during flux training for dev and schnell, disabled by default by @bghira in https://github.com/bghira/SimpleTuner/pull/892
- adding SD3 timestep-dependent shift for Flux training by @bghira in https://github.com/bghira/SimpleTuner/pull/894
- fix: set optimizer details to empty dict w/ deepspeed by @ErwannMillon in https://github.com/bghira/SimpleTuner/pull/895
- fix: make sure wandb_logs is always defined by @ErwannMillon in https://github.com/bghira/SimpleTuner/pull/896
- merge by @bghira in https://github.com/bghira/SimpleTuner/pull/900
- Dataloader Docs - Correct caption strategy for instance prompt by @barakyo in https://github.com/bghira/SimpleTuner/pull/902
- refactor train.py into Trainer class by @bghira in https://github.com/bghira/SimpleTuner/pull/899
- Update TRAINER_EXTRA_ARGS for model_family by @barakyo in https://github.com/bghira/SimpleTuner/pull/903
- Fix text encoder nuking regression by @mhirki in https://github.com/bghira/SimpleTuner/pull/906
- added lokr lycoris init_lora by @flotos in https://github.com/bghira/SimpleTuner/pull/907
- Fix Flux schedule shift and add resolution-dependent schedule shift by @mhirki in https://github.com/bghira/SimpleTuner/pull/905
- Swap the attention mask location, because Flux swapped text and image… by @AmericanPresidentJimmyCarter in https://github.com/bghira/SimpleTuner/pull/908
- support toml, json, env config backend, and multiple config environments by @bghira in https://github.com/bghira/SimpleTuner/pull/909
- Add
"none"
to --report_to argument by @twri in https://github.com/bghira/SimpleTuner/pull/911 - Add support for tiny PEFT-based Flux LoRA based on TheLastBen's post on Reddit by @mhirki in https://github.com/bghira/SimpleTuner/pull/912
- Update lycoris_config.json.example with working defaults by @mhirki in https://github.com/bghira/SimpleTuner/pull/918
- fix constant_with_warmup not being so constant or warming up by @bghira in https://github.com/bghira/SimpleTuner/pull/919
- follow-up fix for setting last_epoch by @bghira in https://github.com/bghira/SimpleTuner/pull/920
- fix multigpu schedule issue with LR on resume by @bghira in https://github.com/bghira/SimpleTuner/pull/921
- multiply the resume state step by the number of GPUs in an attempt to overcome accelerate v0.33 issue by @bghira in https://github.com/bghira/SimpleTuner/pull/922
- default to json/toml before the env file in case multigpu is configured by @bghira in https://github.com/bghira/SimpleTuner/pull/923
- fix json/toml configs str bool values by @bghira in https://github.com/bghira/SimpleTuner/pull/924
- bypass some "helpful" diffusers logic that makes random decisions to run on CPU by @bghira in https://github.com/bghira/SimpleTuner/pull/925
- v1.0 merge by @bghira in https://github.com/bghira/SimpleTuner/pull/910
- doc updates by @bghira in https://github.com/bghira/SimpleTuner/pull/927
- merge by @bghira in https://github.com/bghira/SimpleTuner/pull/928
New Contributors
Christ, that's a lot of new people. Welcome!
- @anhi made their first contribution in https://github.com/bghira/SimpleTuner/pull/833
- @ErwannMillon made their first contribution in https://github.com/bghira/SimpleTuner/pull/838
- @williamzhuk made their first contribution in https://github.com/bghira/SimpleTuner/pull/645
- @riffmaster-2001 made their first contribution in https://github.com/bghira/SimpleTuner/pull/882
- @barakyo made their first contribution in https://github.com/bghira/SimpleTuner/pull/902
- @flotos made their first contribution in https://github.com/bghira/SimpleTuner/pull/907
- @twri made their first contribution in https://github.com/bghira/SimpleTuner/pull/911
Full Changelog: https://github.com/bghira/SimpleTuner/compare/v0.9.8.3.2...v1.0