gradient-diffusion commited on
Commit
6886d08
β€’
1 Parent(s): 7ec80e5

Create README.md

Browse files
Files changed (1) hide show
  1. README.md +64 -0
README.md ADDED
@@ -0,0 +1,64 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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.
5
+ language:
6
+ - en
7
+ pipeline_tag: text-to-image
8
+ tags:
9
+ - LoRA
10
+ - Stable Diffusion
11
+ - image-generation
12
+ - Flux
13
+ ---
14
+ This repository provides a checkpoint with trained LoRA for
15
+ [FLUX.1-dev model](https://huggingface.co/black-forest-labs/FLUX.1-dev) by Black Forest Labs
16
+ [<img src="https://github.com/XLabs-AI/x-flux/blob/main/assets/readme/light/join-our-discord-rev1.png?raw=true">](https://discord.gg/FHY2guThfy)
17
+
18
+ ![Example Picture 1](https://github.com/XLabs-AI/x-flux/blob/main/assets/readme/examples/result_14.png?raw=true)
19
+
20
+ # Training details
21
+ [XLabs AI](https://github.com/XLabs-AI) team is happy to publish fune-tuning Flux scripts, including:
22
+
23
+ - **LoRA** πŸ”₯
24
+ - **ControlNet** πŸ”₯
25
+
26
+ [See our github](https://github.com/XLabs-AI/x-flux) for train script and train configs.
27
+
28
+ # Training Dataset
29
+ Dataset has the following format for the training process:
30
+
31
+ ```
32
+ β”œβ”€β”€ images/
33
+ β”‚ β”œβ”€β”€ 1.png
34
+ β”‚ β”œβ”€β”€ 1.json
35
+ β”‚ β”œβ”€β”€ 2.png
36
+ β”‚ β”œβ”€β”€ 2.json
37
+ β”‚ β”œβ”€β”€ ...
38
+ ```
39
+ A .json file contains "caption" field with a text prompt.
40
+
41
+ Thank https://civitai.com/user/dobrosketchkun and https://civitai.com/user/sadxzero for datasets for loras
42
+
43
+ # Inference
44
+ ## mjv6_lora
45
+ ```bash
46
+ python3 main.py \
47
+ --prompt "A handsome man in a suit, 25 years old, cool, futuristic" \
48
+ --lora_repo_id XLabs-AI/flux-lora-collection --lora_name mjv6_lora.safetensors \
49
+ --device cuda:4 --offload --use_lora --model_type flux-dev-fp8 --width 1024 --height 1024
50
+ ```
51
+
52
+ ![Example Picture 1](https://github.com/XLabs-AI/x-flux/blob/main/assets/readme/examples/result_13.png?raw=true)
53
+
54
+ ```bash
55
+ python3 main.py \
56
+ --prompt "A girl in a suit covered with bold tattoos and holding a vest pistol, beautiful woman, 25 years old, cool, future fantasy, turquoise & light orange ping curl hair" \
57
+ --lora_repo_id XLabs-AI/flux-lora-collection --lora_name mjv6_lora.safetensors \
58
+ --device cuda --offload --use_lora --model_type flux-dev-fp8 --width 1024 --height 1024
59
+ ```
60
+
61
+ ![Example Picture 1](https://github.com/XLabs-AI/x-flux/blob/main/assets/readme/examples/result_12.png?raw=true)
62
+
63
+
64
+ lora.safetensors falls under the [FLUX.1 [dev]](https://huggingface.co/black-forest-labs/FLUX.1-dev/blob/main/LICENSE.md) Non-Commercial License<br/>