Instructions to use runchat/lora-be0b71e2-b283-4e1a-a198-3d32c9f92d5e-4uysso with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use runchat/lora-be0b71e2-b283-4e1a-a198-3d32c9f92d5e-4uysso with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("black-forest-labs/FLUX.1-dev", torch_dtype=torch.bfloat16, device_map="cuda") pipe.load_lora_weights("runchat/lora-be0b71e2-b283-4e1a-a198-3d32c9f92d5e-4uysso") prompt = "a photo of a sks style" image = pipe(prompt).images[0] - Inference
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- Draw Things
- DiffusionBee
Upload Flux LoRA for 'sks' (both diffusers and Kohya formats)
Browse files
README.md
ADDED
|
@@ -0,0 +1,65 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: other
|
| 3 |
+
license_name: flux-1-dev-non-commercial-license
|
| 4 |
+
license_link: https://huggingface.co/black-forest-labs/FLUX.1-dev/blob/main/LICENSE.md
|
| 5 |
+
base_model: black-forest-labs/FLUX.1-dev
|
| 6 |
+
tags:
|
| 7 |
+
- flux
|
| 8 |
+
- lora
|
| 9 |
+
- diffusers
|
| 10 |
+
- text-to-image
|
| 11 |
+
widget:
|
| 12 |
+
- text: 'a photo of a sks style'
|
| 13 |
+
output:
|
| 14 |
+
url: "placeholder.jpg"
|
| 15 |
+
---
|
| 16 |
+
|
| 17 |
+
# Flux LoRA: sks
|
| 18 |
+
|
| 19 |
+
This is a LoRA (Low-Rank Adaptation) model for Flux.1-dev fine-tuned on images with the trigger word `sks`.
|
| 20 |
+
|
| 21 |
+
## Files
|
| 22 |
+
|
| 23 |
+
- `pytorch_lora_weights.safetensors`: Diffusers format (use with diffusers library)
|
| 24 |
+
- `pytorch_lora_weights_webui.safetensors`: Kohya format (use with AUTOMATIC1111, ComfyUI, etc.)
|
| 25 |
+
|
| 26 |
+
## Usage
|
| 27 |
+
|
| 28 |
+
### Diffusers Library
|
| 29 |
+
|
| 30 |
+
```python
|
| 31 |
+
from diffusers import FluxPipeline
|
| 32 |
+
import torch
|
| 33 |
+
|
| 34 |
+
# Load base model
|
| 35 |
+
pipe = FluxPipeline.from_pretrained(
|
| 36 |
+
"black-forest-labs/FLUX.1-dev",
|
| 37 |
+
torch_dtype=torch.bfloat16
|
| 38 |
+
)
|
| 39 |
+
|
| 40 |
+
# Load LoRA weights (diffusers format)
|
| 41 |
+
pipe.load_lora_weights("runchat/lora-be0b71e2-b283-4e1a-a198-3d32c9f92d5e-4uysso", weight_name="pytorch_lora_weights.safetensors")
|
| 42 |
+
pipe = pipe.to("cuda")
|
| 43 |
+
|
| 44 |
+
# Generate image
|
| 45 |
+
prompt = "a photo of a sks style"
|
| 46 |
+
image = pipe(prompt, num_inference_steps=50, guidance_scale=3.5).images[0]
|
| 47 |
+
image.save("output.png")
|
| 48 |
+
```
|
| 49 |
+
|
| 50 |
+
### WebUI (AUTOMATIC1111, ComfyUI, etc.)
|
| 51 |
+
|
| 52 |
+
Download the `pytorch_lora_weights_webui.safetensors` file and place it in your WebUI's LoRA directory.
|
| 53 |
+
Use the trigger word `sks` in your prompts.
|
| 54 |
+
|
| 55 |
+
## Training Details
|
| 56 |
+
- Base model: black-forest-labs/FLUX.1-dev
|
| 57 |
+
- Training steps: 500
|
| 58 |
+
- Learning rate: 0.001
|
| 59 |
+
- Batch size: 2
|
| 60 |
+
- LoRA rank: 16
|
| 61 |
+
- Trigger word: `sks`
|
| 62 |
+
|
| 63 |
+
## License
|
| 64 |
+
|
| 65 |
+
This model is trained on Flux.1-dev and inherits its non-commercial license. Please see the [license](https://huggingface.co/black-forest-labs/FLUX.1-dev/blob/main/LICENSE.md) for usage restrictions.
|
checkpoint-500/optimizer.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:28d92f10bef9c708983b70436881624c92cff8a8a0d81e1b3f8424d9519abcf0
|
| 3 |
+
size 91854485
|
checkpoint-500/pytorch_lora_weights.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:71f39f4a137cb8c9645c4c832584f64ba15e7f8971eb5358a053c6e9525aa3bb
|
| 3 |
+
size 89746864
|
checkpoint-500/random_states_0.pkl
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:45fc2fe4bcd53ccf22bc42b0c720f921edf5630dd2c39375a7447b75989797eb
|
| 3 |
+
size 14757
|
checkpoint-500/scheduler.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:f40a79520185bf7ffaaf2e1bf1dede1aad3e7ab0722ace3f1330fd60160fc35d
|
| 3 |
+
size 1401
|
pytorch_lora_weights.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:6349a2733a89b5cdcac39dc385d8a7cacd21f4d2bdcc7dc7ed18eade14a707cd
|
| 3 |
+
size 89746864
|
pytorch_lora_weights_webui.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:f969f92c5e7f2210b8a195bbde53c8e1a48a0ea6dac7fa1b074700f63230d959
|
| 3 |
+
size 89786904
|