Upload README.md with huggingface_hub
Browse files123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051---license: otherpipeline_tag: text-to-imagetags: [text-to-image, flow-matching, dit, dc-ae]---
# HobbyLM-image-2
Private working checkpoint of HobbyLM-Image v2 (`model_v2_768`, 23 November 2026).
- **Model:** 333M-parameter flow-matching DiT, single panel, with a small text-fusion module.- **Text encoders (not included):** `openai/clip-vit-large-patch14` (64 tokens) and `google/flan-t5-large` (96 tokens).- **Autoencoder (not included):** `mit-han-lab/dc-ae-f32c32-sana-1.1-diffusers` (32x compression, 32 channels).- **Resolution:** trained at 512px and 768px; sample at 768px with timestep shift 1.5 (stored in the checkpoint), or at 512px with no shift.- **Sampler:** Euler, 50 steps, CFG 4.5, all-zero null conditioning.
## Files
- `model_v2_768.pt`: EMA weights. Keys: `sd` (DiT), `fusion` (text fusion), `cfg_dict`, `lat_std`, `sf`, `steps`, `v2` (metadata incl. `hi_res`, `hi_shift`).- `hobby_image/dit.py`, `hobby_image/v2.py`: model and sampler code.- `samples/`: fixed-seed grids at 768px.
## Usage sketch
```pythonimport torchfrom diffusers import AutoencoderDCfrom hobby_image.dit import HobbyImageDiT, DiTConfigfrom hobby_image import v2 as V2
ck = torch.load("model_v2_768.pt", map_location="cuda")dit = HobbyImageDiT(DiTConfig(**ck["cfg_dict"])).cuda().eval(); dit.load_state_dict(ck["sd"])fusion = V2.TextFusion(1024, dit.cfg.ctx_dim).cuda().eval(); fusion.load_state_dict(ck["fusion"])# encode text with V2.encode_text(...), build the null condition with V2.null_like(...),# sample with V2.sample(dit, ctx, mask, uctx, umask, z, n_steps=50, cfg=4.5, shift=V2.ckpt_shift(ck["v2"], 768)),# decode with ae.decode(z * ck["lat_std"] / ck["sf"]).```
## Scores (self-run, one seed)
| Benchmark | Score ||---|---|| GenEval 2 Soft-TIFA, 768px | AM 59.55 / GM 15.99 || GenEval 2 Soft-TIFA, 512px | AM 57.39 / GM 15.08 || GenEval (previous checkpoint `model_v2_512c`, 512px) | 0.831 |
## Disclosures
- The training mix includes GenEval-style compositional data (Echo-4o-Image, BLIP3o-60k), so GenEval is not zero-shot.- The mix includes FLUX-Reason-6M (FLUX.1-dev outputs), whose licence restricts training competing models. Check before any public release.- Known weaknesses: hands, text rendering, faces smaller than about 55px, counts above three.README.mdAdded+51