Instructions to use kirusanth08/flux-dev-sty1ref-lora with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Inference
- Notebooks
- Google Colab
- Kaggle
File size: 3,845 Bytes
add2822 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 | ---
base_model: black-forest-labs/FLUX.1-dev
tags:
- flux
- lora
- text-to-image
- style
- kohya-ss
license: other
license_name: flux-1-dev-non-commercial-license
license_link: https://huggingface.co/black-forest-labs/FLUX.1-dev/blob/main/LICENSE.md
instance_prompt: sty1ref
pipeline_tag: text-to-image
---
# sty1ref β FLUX.1-dev style LoRA (v1)
A stylised portrait-illustration LoRA: hard-edged planar shading, flat colour blocking
across the face, visible geometric facets in skin and hair, muted palette.
**Trigger word: `sty1ref`** β put it at the front of the prompt.
## Recommended settings
| Setting | Value |
|---|---|
| Checkpoint | `sty1ref-step00002000.safetensors` |
| **LoRA strength** | **1.4 β 1.6** (not 1.0 β see below) |
| Base | `flux1-dev` (fp8_e4m3fn is fine) |
| Sampler / scheduler | euler / beta, 28 steps |
| FluxGuidance | 3.0 |
| CFG | 1.0 (Flux dev is CFG-distilled; negatives do nothing) |
## Read this before using it
**Strength 1.0 is too weak.** This LoRA is undertrained at unit strength β a prompt
rendered at 1.0 comes back looking like base Flux with a light stylisation pass. The
faceted planar shading only appears clearly from about 1.4 upward. 1.5 is the sweet
spot; 2.0 works but muddies the midtones.
**It is portrait-biased.** All 12 training images are head-and-shoulders portraits, so
the trigger has only ever co-occurred with faces. Consequences:
- Portraits of unseen subjects: works well at 1.5.
- Scenes without people (streets, landscapes, objects): the output becomes *painterly*
but does not pick up the hard faceted planes. At 1.0 it is essentially unstyled.
If you need this texture on arbitrary scenes, retrain with non-portrait references in
the same style β full figures, architecture, objects, landscapes. That is the fix; no
strength value substitutes for it.
## Checkpoints
| File | Steps | Notes |
|---|---|---|
| `sty1ref-step00000400.safetensors` | 400 | barely stylised |
| `sty1ref-step00000800.safetensors` | 800 | faint |
| `sty1ref-step00001200.safetensors` | 1200 | usable at 1.5 |
| `sty1ref-step00001600.safetensors` | 1600 | close second |
| `sty1ref-step00002000.safetensors` | 2000 | **recommended** |
`samples/` holds two renders per checkpoint at a fixed seed (42) β one portrait of an
unseen subject, one people-free scene β plus the comparison grids.
## Training recipe
kohya-ss `sd-scripts` (sd3 branch), `flux_train_network.py`, on one RTX 5090 (32 GB),
~1 hour for 2000 steps.
```
--network_module networks.lora_flux --network_dim 24 --network_alpha 24
--network_train_unet_only
--optimizer_type adamw8bit --learning_rate 1e-4
--lr_scheduler constant_with_warmup --lr_warmup_steps 40
--max_train_steps 2000 --save_every_n_steps 400
--gradient_checkpointing --mixed_precision bf16 --fp8_base --sdpa --highvram
--timestep_sampling shift --discrete_flow_shift 3.1582
--model_prediction_type raw --guidance_scale 1.0 --loss_type l2
```
Dataset: 12 images, aspect-ratio bucketing at 1024 base with `bucket_no_upscale`,
`keep_tokens = 1`. Captions describe **content only** (subject, clothing, framing,
background) so that everything constant across the set collapses onto the trigger token
rather than scattering across style adjectives.
Known cause of the weak transfer: 12 images at lr 1e-4 for 2000 steps undercooks this
style. A v2 should use more images and/or lr 2e-4.
## Dataset
`kirusanth08/sty1ref-dataset` (private) β the 12 cleaned images and their caption files.
## Usage (ComfyUI)
`workflow/workflow_api.json` is a working API-format graph at the recommended settings.
`workflow/workflow.json` drags onto the canvas.
## Licence
Inherits the FLUX.1-dev non-commercial licence. The training references were collected
from the web and are not owned by the author of this LoRA; treat outputs accordingly.
|