Skip to content

Commit 0cf8e95

Browse files
authored
Merge pull request #1845 from bghira/chore/docs-update-for-validation-adapters
add note about multi-adapter validations
2 parents 2dd050e + dd96c7f commit 0cf8e95

File tree

2 files changed

+42
-0
lines changed

2 files changed

+42
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@ SimpleTuner provides comprehensive training support across multiple diffusion mo
9090
- **Loss functions** - L2, Huber, Smooth L1 with scheduling support
9191
- **SNR weighting** - Min-SNR gamma weighting for improved training dynamics
9292
- **Group offloading** - Diffusers v0.33+ module-group CPU/disk staging with optional CUDA streams
93+
- **Validation adapter sweeps** - Temporarily attach LoRA adapters (single or JSON presets) during validation to measure adapter-only or comparison renders without touching the training loop
9394

9495
### Model-Specific Features
9596

documentation/OPTIONS.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -291,6 +291,47 @@ A lot of settings are instead set through the [dataloader config](/documentation
291291
- **What**: Output image resolution, measured in pixels, or, formatted as: `widthxheight`, as in `1024x1024`. Multiple resolutions can be defined, separated by commas.
292292
- **Why**: All images generated during validation will be this resolution. Useful if the model is being trained with a different resolution.
293293

294+
### `--validation_adapter_path`
295+
296+
- **What**: Temporarily loads a single LoRA adapter when running scheduled validations.
297+
- **Formats**:
298+
- Hugging Face repo: `org/repo` or `org/repo:weight_name.safetensors` (defaults to `pytorch_lora_weights.safetensors`).
299+
- Local file or directory path pointing to a safetensors adapter.
300+
- **Notes**:
301+
- Mutually exclusive with `--validation_adapter_config`; supplying both raises an error.
302+
- The adapter is only attached for validation runs (baseline training weights remain untouched).
303+
304+
### `--validation_adapter_name`
305+
306+
- **What**: Optional identifier to apply to the temporary adapter loaded via `--validation_adapter_path`.
307+
- **Why**: Controls how the adapter run is labelled in logs/web UI and ensures predictable adapter names when multiple adapters are tested sequentially.
308+
309+
### `--validation_adapter_strength`
310+
311+
- **What**: Strength multiplier applied when enabling the temporary adapter (defaults to `1.0`).
312+
- **Why**: Lets you sweep lighter/heavier LoRA scaling during validation without altering training state; accepts any value greater than zero.
313+
314+
### `--validation_adapter_mode`
315+
316+
- **Choices**: `adapter_only`, `comparison`, `none`
317+
- **What**:
318+
- `adapter_only`: run validations only with the temporary adapter attached.
319+
- `comparison`: generate both base-model and adapter-enabled samples for side-by-side review.
320+
- `none`: skip attaching the adapter (useful for disabling the feature without deleting CLI flags).
321+
322+
### `--validation_adapter_config`
323+
324+
- **What**: JSON file or inline JSON that describes multiple validation adapter combinations to iterate over.
325+
- **Format**: Either an array of entries or an object with a `runs` array. Each entry may include:
326+
- `label`: Friendly name shown in logs/UI.
327+
- `path`: Hugging Face repo ID or local path (same formats as `--validation_adapter_path`).
328+
- `adapter_name`: Optional identifier per adapter.
329+
- `strength`: Optional scalar override.
330+
- `adapters`/`paths`: Array of objects/strings to load multiple adapters in a single run.
331+
- **Notes**:
332+
- When provided, the single-adapter options (`--validation_adapter_path`, `--validation_adapter_name`, `--validation_adapter_strength`, `--validation_adapter_mode`) are ignored/disabled in the UI.
333+
- Each run is loaded one at a time and fully detached before the next run begins.
334+
294335
### `--evaluation_type`
295336

296337
- **What**: Enable CLIP evaluation of generated images during validations.

0 commit comments

Comments
 (0)