How to use from the
Use from the
Diffusers library
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.2-klein-4B", dtype=torch.bfloat16, device_map="cuda")
pipe.load_lora_weights("itslenoid/flux2-klein-4b-comic-lora")

prompt = "a black and white comic illustration of a software engineer at a multi-monitor workstation, detailed line art, crosshatching, technical schematics on the wall, high contrast"
image = pipe(prompt).images[0]

🖋️ Comic Illustration LoRA — FLUX.2 Klein 4B

License: Apache 2.0 Base Model: FLUX.2-klein-4B Engine: Imaginator Framework: MLX & Diffusers Adapter Size: 99MB Dataset

A high-performance LoRA adapter specialized in pen-and-ink comic illustration, crosshatching, and technical schematics, trained on black-forest-labs/FLUX.2-klein-4B using Imaginator — the end-to-end Apple Silicon FLUX.2 training and data engineering framework.

This repository contains the standalone dynamic LoRA adapter (comic-illustration-lora.safetensors, ~99 MB). If you prefer complete, out-of-the-box models without needing runtime adapter injection, see the pre-baked fused variants below.


📌 Model Selection: Which Variant Should You Use?

Model Variant Repository Format LoRA Multiplier ($\alpha$ Benchmark) Fidelity vs. Style Transfer Tradeoff Profile Best For
📦 Dynamic LoRA (This Repo) itslenoid/flux2-klein-4b-comic-lora LoRA Safetensors (~99 MB) Configurable ($0.0 \le s \le 2.0$) Full Prompt Flexibility: Preserves base model text comprehension; enables dynamic scale sweeping and multi-LoRA stacking. Custom adapter pipelines, testing varied scale strengths, storage-limited setups.
⚡ Standalone Fused 1.0x itslenoid/flux2-klein-4b-comic-fused-1x Full Model Safetensors (~4B) Fixed $1.0\times$ baseline High Prompt Fidelity: Strict adherence to complex compositional instructions. Clean contour lines, restrained crosshatching, neutral tonal balance. Engineering schematics, infographics, detailed scenes requiring strict prompt adherence.
⚡ Standalone Fused 1.5x itslenoid/flux2-klein-4b-comic-fused-1.5x Full Model Safetensors (~4B) Fixed $1.5\times$ amplified Balanced Style Saturation: Pronounced pen-and-ink aesthetics, distinct crosshatching gradients, and stylized background blueprints while retaining subject clarity. Graphic novels, character design, developer & hacker workspace illustrations.
⚡ Standalone Fused 2.0x itslenoid/flux2-klein-4b-comic-fused-2x Full Model Safetensors (~4B) Fixed $2.0\times$ heavy saturation Aggressive Style Dominance: Maximum ink density, forceful conversion of mid-tones into binary hatching patterns, high-contrast woodcut/engraving texture. High-contrast noir comics, retro pulp art, intense black-and-white ink drawings.

🎨 Visual Signature & Capabilities

  • Crosshatching & Linework: Dense, hand-drawn ink hatching for volumetric shading and shadows.
  • Technical Schematics: Automatically incorporates circuit diagrams, flowcharts, blueprints, and terminal outputs into scene backgrounds.
  • Developer & Engineering Focus: Specially tuned for hardware workshops, multi-monitor desks, server rooms, and scientific environments.
  • Comic Framing: Strong support for multi-panel split compositions and sequential art perspective.

🚀 Quickstart & Usage

1. Apple Silicon via mflux (Recommended for Mac)

Install mflux:

pip install mflux

Generate using the FLUX.2 Klein CLI with dynamic LoRA application:

mflux-generate-flux2 \
  --model black-forest-labs/FLUX.2-klein-4B \
  --lora-paths itslenoid/flux2-klein-4b-comic-lora/comic-illustration-lora.safetensors \
  --lora-scales 1.25 \
  --prompt "a black and white comic illustration of a developer working late, detailed line art, technical schematics, crosshatching" \
  --steps 30 \
  --guidance 1.0 \
  --low-ram \
  --output comic_output.png \
  --seed 42

2. Linux / CUDA via diffusers (PyTorch)

import torch
from diffusers import FluxPipeline

# Load base FLUX.2 Klein pipeline
pipe = FluxPipeline.from_pretrained(
    "black-forest-labs/FLUX.2-klein-4B",
    torch_dtype=torch.bfloat16
).to("cuda")

# Load and fuse LoRA adapter weights
pipe.load_lora_weights("itslenoid/flux2-klein-4b-comic-lora", weight_name="comic-illustration-lora.safetensors")
pipe.fuse_lora(lora_scale=1.2)

prompt = "a black and white comic illustration of a robotics laboratory, engineer soldering a circuit board, intricate technical blueprints, fine ink crosshatching"
image = pipe(
    prompt=prompt,
    num_inference_steps=30,
    guidance_scale=3.5,
    height=1024,
    width=1024,
).images[0]

image.save("comic_robotics.png")

💡 Prompting & Parameter Guidelines

Parameter Recommended Value Notes
Recommended LoRA Scale 1.0 – 1.5 1.0 gives tight prompt obedience; 1.5 unleashes rich comic hatching.
Inference Steps 25 – 35 30 steps produces optimal line crispness on FLUX.2 Klein.
Guidance Scale 1.0 (mflux) / 3.0 - 3.5 (diffusers) Keeps black-and-white tonal contrast sharp without artifacting.
Resolution 1024x1024, 1024x768, 768x1024 Native high-resolution training resolution.

Trigger & Style Tokens

To maximize the comic style activation, incorporate these keywords in your positive prompt:

  • a black and white comic illustration
  • detailed line art, crosshatching, pen and ink
  • technical diagrams, circuit schematics, blueprints in background
  • high contrast, graphic novel panel

🛠️ Engine & Training Provenance

This model was engineered, captioned, and trained end-to-end using Imaginator:

  • Local Apple Silicon Execution: 100% native execution on Apple Metal via MLX and mflux without requiring cloud GPUs.
  • Zero-OOM Auto-Captioning Pipeline: Curated and captioned using a token-optimized vision-language pipeline that reduced visual memory footprint from >8 GB down to 1.2 GB, fitting comfortably on 16 GB unified RAM.
  • Precision Target Layers: Injected rank-16 Low-Rank Adaptation across single and double transformer blocks (cross-attention, self-attention, and feed-forward MLP layers) with gradient checkpointing on 8-bit quantized weights.
  • Dataset: itslenoid/comic-illustration-dataset (86 curated high-resolution line-art & schematic illustrations).
  • Train Your Own Models: To train custom FLUX.2 Klein LoRA adapters locally on Apple Silicon, visit the Imaginator repository.

📜 License

This model and adapter are released under the Apache 2.0 License.

Downloads last month
-
MLX
Hardware compatibility
Log In to add your hardware

Quantized

Inference Providers NEW
Examples

Model tree for itslenoid/flux2-klein-4b-comic-lora

Adapter
(90)
this model

Dataset used to train itslenoid/flux2-klein-4b-comic-lora

Collection including itslenoid/flux2-klein-4b-comic-lora