REPO STORY / リポジトリ紹介
vivo/BluePixel
テキスト指示で 4K 解像度の画像を高速編集するディフュージョンモデル
01 / 何ができる?
どんな作業に
役立つ?
BluePixelModel は、テキスト指示で写真を編集して 4K サイズで直接出力するディフュージョンモデルです。Flux 2 Klein をベースに DCAE-F64 エンコーダを採用し、4 ステップの高速推論で編集を実現します。セーターやジャケットなど、衣服の色をテキスト指示で変更するような実用的な編集に使用できます。推論には CUDA BF16 対応 GPU と Diffusers 0.36 以上が必要です。
- ネイティブ 4K 直接出力(スーパーレゾリューション不要)
- 4 ステップ蒸留による高速推論
- DCAE-F64 による効率的な 4K トークン圧縮
02 / 自分に合う?
使いどころと、
選ぶ前の確認。
こんなときに
- 肖像写真の衣服(セーター、ジャケット、帽子など)の色をテキスト指示で変更したい場合
- 高品質な 4K 解像度で対話的に画像を編集したい場合
先に確認すること
以下の前提条件を確認し、必要に応じて環境を準備してください。
- CUDA BF16 対応 GPU
- Diffusers 0.36 API 以上
ギット飯の日本語要約から、利用例と前提条件を紹介しています。
03 / 始め方
最初の一歩を、
順番に。
準備するもの
- CUDA BF16 対応 GPU
- Diffusers 0.36 API 以上
- 依存関係をインストール
pip install -r requirements.txt
- モデルウェイトをダウンロード
hf download openvivo/BluePixel-Turbo --local-dir ./BluePixel-Turbo
- 単一画像を編集する場合、以下の Python スクリプトを実行
import torch
from PIL import Image
from vins_infer import load_pipeline
pipe = load_pipeline(
"BluePixel-Turbo",
device="cuda",
vae_tiling=False,
lora_scale=None,
shift=0,
mu_mode="empirical",
)
result = pipe(
image=Image.open("assets/test_input.jpg").convert("RGB"),
instruction="Change the gray sweater to burgundy red.",
num_inference_steps=4,
guidance_scale=3.0,
target_pixels=4096 * 4096,
generator=torch.Generator(device="cuda").manual_seed(42),
).images[0]
result.save("output.jpg")
- バッチ処理を行う場合、image_name と edit_prompt フィールドを含む JSON-L ファイルを作成
{"image_name": "/path/to/input.png", "edit_prompt": "make the hair red"}
- バッチ推論スクリプトを実行
CUDA_VISIBLE_DEVICES=0 python vins_infer.py \
--model-dir BluePixel-Turbo \
--jsonl /path/to/your_tasks.jsonl \
--out-dir ./output \
--target-pixels 16777216 \
--steps 4 \
--guidance 3.0 \
--seed 42 \
--mu-mode empirical \
--instruction-field edit_prompt
コマンドは要約からの引用です。実行やインストールの成否は検証していません。公式の所要時間は記載されていません。
04 / 関連リポジトリ
どんなリポジトリとつながる?
比較グラフのスナップショットから関係の種類と根拠を紹介します。現在公開中のリポジトリだけを表示します。
Anil-matcha/awesome-flux-3-api-prompts ↗
共通するGitHubトピック:flux,image-to-image
repos.topicsの共通項(flux,image-to-image)
グラフの元データ ↗astropuzzo/ComfyUI-MiniMax-H3-Image-Studio ↗
共通するGitHubトピック:image-editing,image-to-image
repos.topicsの共通項(image-editing,image-to-image)
グラフの元データ ↗beckettharriman/openfill ↗
共通するGitHubトピック:flux,image-editing
repos.topicsの共通項(flux,image-editing)
グラフの元データ ↗DenRakEiw/scumble ↗
共通するGitHubトピック:flux,image-editing
repos.topicsの共通項(flux,image-editing)
グラフの元データ ↗