Instructions to use HERIUN/inkspire_korean with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use HERIUN/inkspire_korean with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline from diffusers.utils import load_image # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("black-forest-labs/flux-3-image-klein-base", dtype=torch.bfloat16, device_map="cuda") pipe.load_lora_weights("HERIUN/inkspire_korean") prompt = "Turn this cat into a dog" input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png") image = pipe(image=input_image, prompt=prompt).images[0] - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- Draw Things
import torch
from diffusers import DiffusionPipeline
from diffusers.utils import load_image
# switch to "mps" for apple devices
pipe = DiffusionPipeline.from_pretrained("black-forest-labs/flux-3-image-klein-base", dtype=torch.bfloat16, device_map="cuda")
pipe.load_lora_weights("HERIUN/inkspire_korean")
prompt = "Turn this cat into a dog"
input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png")
image = pipe(image=input_image, prompt=prompt).images[0]InkSpire Korean โ ํ๊ธ ์๊ธ์จ ์คํ์ผ ์์ฑ LoRA
InkSpire (Wang et al., ICLR 2026) ๋ฅผ ํ๊ธ๋ก ์ฌํํ LoRA. FLUX.3-Image-Klein-Base + LoRA r32 (71.2M), 13k step. ์คํ์ผ ์๊ธ์จ ํ ์ค(+ ๊ทธ ์ ์ฌ)์ ๋ณด๊ณ ๊ฐ์ ํ์ฒด๋ก ์ ๋ฌธ์ฅ์ ์ด๋ค.
- ํ์ต ์ฝ๋ยท์คํ ๊ธฐ๋ก: https://github.com/HERIUN/Inkspire_korean_finetuning
- ๋ฐ๋ชจ(Eruku ์ ๋ชจ๋ธ ์ ํ): https://huggingface.co/spaces/HERIUN/eruku_korean_demo
- ๊ฐ์ ๋ฐ์ดํฐ๋ก ํ์ตํ ์๊ธฐํ๊ท ๋ชจ๋ธ ๋น๊ต ๋์: HERIUN/eruku_korean
์ ๋ ฅ ๊ท์ฝ
์บ๋ฒ์ค X(์ = ref ์๊ธ์จ, ์๋ = ๋น ์นธ) ยท ์ฝํ
์ธ ์ด๋ฏธ์ง Xc(NanumGothic ์ผ๋ก ref ์ ์ฌ์ ๋ชฉํ ๋ฌธ๊ตฌ๋ฅผ ๊ธ์ ์์์ ๊ทธ๋ฆฐ ๊ฒ) ยท ๋ง์คํฌ.
Xc ๋ฅผ ๊ธ์๋ณ ๋์ํ๋ก ์ฐ๋ฏ๋ก ref ์ ์ฌ(style text)๋ ํ์๋ค โ ๋น์ฐ๋ฉด ๋ถ๊ดดํ๋ค(CER 0.72, ์ ๋ฐ ๋ฐฑ์ง).
๋ชฉํ ์ค ํญ์ ref ์ "์๊ธ์จ ํญ / ํ์คํฐํธ ํญ" ๋น์จ๋ก ๋ง์ถ๋ค(ref_width, ๊ธฐ๋ณธ).
์ฑ๋ฅ (ref ์ ์ฌ๋ฅผ ์ค ๋, PP-OCRv6 ํ๋ CER)
| ํ๊ฐ | InkSpire (์ด ๋ชจ๋ธ) | Eruku Korean |
|---|---|---|
| ํ๊ธ ํฐํธ held-out 16์ข n=300 โ CERโ / HWDโ | 0.023 / 0.93 | 0.010 / 1.12 |
| ์ค์๊ธ์จ ๋ฌธ์ฅ ๊ต์ฐจ ์์ฑ n=20 โ CERโ | 0.246 | 0.014 |
| ์ค์๊ธ์จ ์์ ์นธ n=286 โ CERโ | 0.417 | 0.771 (๋ฐฑ์งยทํญ์ฃผ) |
| IAM lines 2,925 โ HWDโ / FIDโ | 1.68 / 18.58 | 1.62 / 20.00 |
๊ธ์ ์ ํ๋๋ Eruku, ํ์ฒด ํํ(HWD)์ ์ง์ ๋ถํ ref ์ ๋ํ ๊ฒฌ๊ณ ์ฑ์ InkSpire ์ชฝ์ด ๋ซ๋ค.
๋จ์ ์ค๋ฅ๋ ์ํ๋ง๋ค ๋ฌด์์์ธ ํ ์ค๋ฅ๋ค(์๋ 3๊ฐ ๊ณตํต ์ค๋ฅ 0) โ ์์ธ๋ GitHub docs/EXPERIMENTS.md.
์ฌ์ฉ๋ฒ
์ถ๋ก ์ฝ๋๋ GitHub repo ์ ์๋ค(๋ฒ ์ด์ค ๊ฐ์ค์น๋ black-forest-labs/flux-3-image-klein-base ์ฝ๊ด ์๋ฝ ํ ์๋ ๋ค์ด๋ก๋).
import numpy as np, torch
from huggingface_hub import snapshot_download
from PIL import Image
from infer.inkspire import InkSpireGen # GitHub repo ๋ฃจํธ์์
lora = snapshot_download("HERIUN/inkspire_korean") # pytorch_lora_weights.safetensors + klein_empty_prompt.pt
# klein_empty_prompt.pt ๋ model_zoo/ ์ ๋๋ค(๋น ํ๋กฌํํธ ํ
์คํธ ์๋ฒ ๋ฉ ์บ์ โ ํ
์คํธ ์ธ์ฝ๋๋ฅผ ์ ์ฌ๋ฆฐ๋ค)
g = InkSpireGen(lora, device="cuda")
ref = np.asarray(Image.open("style_line.png").convert("L"))
out = g.gen_lines(ref, "์คํ์ผ ์ด๋ฏธ์ง์ ์ ์ฌ", ["์์ฑํ ๋ฌธ์ฅ"], seed=0)[0] # u8 ์ค ์ด๋ฏธ์ง
๋ผ์ด์ ์ค
FLUX Kommunity License (๋ฒ ์ด์ค ๋ชจ๋ธ๊ณผ ๋์ผ, ๋น์์ ์ฉ๋) โ NOTICE ์ฐธ๊ณ . ํ์ต ๋ฐ์ดํฐ๋ ๊ณต๊ฐ ํ๊ธ ํฐํธ ๋ ๋์ด๋ฉฐ, ๋น๊ต ํ๊ฐ์ ์ด ์ค์๊ธ์จ ๋ฐ์ดํฐ๋ ํฌํจํ์ง ์์๋ค.
- Downloads last month
- -
Model tree for HERIUN/inkspire_korean
Base model
black-forest-labs/flux-3-image-klein-base
