Skip to content

Add a Diffusers section to Train Models - #2833

Merged
davanstrien merged 1 commit into
huggingface:mainfrom
davanstrien:docs/jobs-training-diffusers
Oct 2, 2026
Merged

davanstrien merged 1 commit into
huggingface:mainfrom
davanstrien:docs/jobs-training-diffusers

Conversation

@davanstrien

@davanstrien davanstrien commented Sep 30, 2026 •

Copy link
Copy Markdown
Member

Adds a Diffusers section to Train Models (jobs-training.md), after Axolotl. This was left out of #2795 to be added later.

Most of the DreamBooth LoRA scripts in the Diffusers repo declare their dependencies in a script header, so they run on Jobs straight from their GitHub URL, like the Transformers scripts. The example trains a LoRA for FLUX.2 [klein] 4B (Apache-2.0, not gated) on diffusers/dog-example, capped to 20 steps, and takes about five minutes on a10g-small. The flags follow the README's klein command, except for these:

  • --dataset_name in place of a local folder
  • no --do_fp8_training: it needs torchao, which isn't in the header, and a GPU with compute capability 8.9 or higher. The A10G is 8.6.
  • no wandb, which isn't in the header
  • 512 px and 20 steps for the capped run

The command was run on Jobs as written.

Also in this PR: Diffusers joins the --push_to_hub and --output_dir lists in "After it ends".

Follow-up: it would be nice for the Diffusers docs to have a Jobs guide too, as Axolotl's and TRL's do. This section would then link to it, as the other library sections do.

🤖 Generated with Claude Code


Note

Low Risk
Documentation-only changes with no runtime, API, or security impact.

Overview
Adds Diffusers to the Train Models on Jobs guide: a new section after Axolotl documents running DreamBooth LoRA scripts via hf jobs uv run from GitHub (example: FLUX.2 klein 4B on diffusers/dog-example, ~5 minutes on a10g-small), including notes on # /// script headers vs --with for scripts without them.

The After it ends section now lists Diffusers alongside Transformers and TRL for --push_to_hub and --output_dir, so post-job Hub upload and bucket checkpoint guidance applies to diffusion training runs too.

Reviewed by Cursor Bugbot for commit c4bd337. Bugbot is set up for automated code reviews on this repo. Configure here.

Runs the FLUX.2 [klein] 4B DreamBooth LoRA script from its GitHub URL
(PEP 723 header) on a10g-small; tested on Jobs. Also adds Diffusers to the
push_to_hub / output_dir lists in "After it ends".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Xu83DsDNs5aqjdh3WYGXHK
@HuggingFaceDocBuilderDev

Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@julien-c

julien-c commented Oct 1, 2026

Copy link
Copy Markdown
Member

Follow-up: it would be nice for the Diffusers docs to have a Jobs guide too, as Axolotl's and TRL's do.

100%, let's track that @sayakpaul?

@davanstrien

Copy link
Copy Markdown
Member Author

Opened huggingface/diffusers#14924 to track this.

@davanstrien

Copy link
Copy Markdown
Member Author

Opened an issue to track this on Diffusers side here: huggingface/diffusers#14924

@davanstrien
davanstrien merged commit 35dea5d into huggingface:main Oct 2, 2026
2 checks passed
@davanstrien
davanstrien deleted the docs/jobs-training-diffusers branch October 2, 2026 08:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants