Downloads · 30 days
24
4% of all-time downloads
minpeter/LoRA-FLUX-anime-style-v1
LoRA-FLUX-anime-style-v1 is a text-to-image model from minpeter. Use it when you need an image from a text prompt. It is set up for diffusers. The card lists the license as other.
<details<summarySee ostris/ai-toolkit config</summary
Downloads · 30 days
24
4% of all-time downloads
All-time downloads
538
Public
Repo size
347 MB
Likes
0
Public
Click a slice to open those files.
.safetensors344 MB · 100%
From the Hugging Face model README
ostris/ai-toolkit commit hash: fa187b1
job: "extension"
config:
name: "FAS"
process:
- type: "ui_trainer"
training_folder: "/data/minpeter/github.com/flux/ai-toolkit/output"
sqlite_db_path: "./aitk_db.db"
device: "cuda"
trigger_word: "anime style"
performance_log_every: 10
network:
type: "lora"
linear: 32
linear_alpha: 32
lokr_full_rank: true
lokr_factor: -1
save:
dtype: "bf16"
save_every: 250
max_step_saves_to_keep: 4
save_format: "diffusers"
push_to_hub: false
datasets:
- folder_path: "/data/minpeter/github.com/flux/ai-toolkit/datasets/fas"
mask_path: null
mask_min_value: 0.1
default_caption: "anime style, "
caption_ext: "txt"
caption_dropout_rate: 0.05
cache_latents_to_disk: false
is_reg: false
network_weight: 1
resolution:
- 512
- 768
- 1024
- 1280
- 1536
- 256
- folder_path: "/data/minpeter/github.com/flux/ai-toolkit/datasets/f"
mask_path: null
mask_min_value: 0.1
default_caption: ""
caption_ext: "txt"
caption_dropout_rate: 0.05
cache_latents_to_disk: false
is_reg: false
network_weight: 1
resolution:
- 512
- 768
- 1024
- 1280
- 1536
- 256
train:
batch_size: 1
bypass_guidance_embedding: false
steps: 2500
gradient_accumulation: 1
train_unet: true
train_text_encoder: false
gradient_checkpointing: true
noise_scheduler: "flowmatch"
optimizer: "adamw8bit"
timestep_type: "sigmoid"
content_or_style: "balanced"
optimizer_params:
weight_decay: 0.0001
unload_text_encoder: false
lr: 0.0001
ema_config:
use_ema: true
ema_decay: 0.99
dtype: "bf16"
diff_output_preservation: false
diff_output_preservation_multiplier: 1
diff_output_preservation_class: "person"
model:
name_or_path: "black-forest-labs/FLUX.1-dev"
quantize: true
quantize_te: true
arch: "flux"
low_vram: false
sample:
sampler: "flowmatch"
sample_every: 250
width: 1024
height: 1024
prompts:
- "anime style, woman with red hair, playing chess at the park, bomb going off in the background"
- "anime style, a man showing off his cool new t shirt at the beach, a shark is jumping out of the water in the background"
- "anime style, a bear building a log cabin in the snow covered mountains"
neg: ""
seed: 42
walk_seed: true
guidance_scale: 4
sample_steps: 25
num_frames: 1
fps: 1
meta:
name: "[name]"
version: "1.0"
</details><br>
A Flux LoRA trained on a local computer with ostris/ai-toolkit.
<Gallery />You should use anime style to trigger the image generation.
import torch
from diffusers import FluxPipeline
pipe = FluxPipeline.from_pretrained("black-forest-labs/FLUX.1-dev", torch_dtype=torch.bfloat16).to("cuda")
from huggingface_hub import hf_hub_download
pipe.load_lora_weights(
hf_hub_download("minpeter/FAS-v1", "adapter.safetensors"), adapter_name="fas-v1"
)
pipe.set_adapters(["fas-v1"], adapter_weights=[1])
prompt = "anime style, A vibrant fantasy city with sky-high spires and unique architectural buildings stacked upon each other, featuring bright and colorful tones with intricate details – anime style background."
image = pipe(
prompt=prompt,
guidance_scale=3.5,
height=1024,
width=1024,
num_inference_steps=20,
).images[0]
image.save("s4.png")