18 Commits

Author SHA1 Message Date
Jaret Burkett
7195abc32b Performance fixes and bug fixes 2026-08-28 22:21:09 -06:00
Jaret Burkett
85a6880643 Move the offload and quantization to the base model 2026-08-28 08:37:56 -06:00
Jaret Burkett
702254688d Added legacy paths 2026-08-28 07:55:19 -06:00
Jaret Burkett
520d96aac3 Phase 2 2026-08-27 18:18:31 -06:00
Jaret Burkett
8db198ec0a Phase 1 2026-08-27 11:53:08 -06:00
Jaret Burkett
e8d9cf6d35 Models v2 - phase 0 2026-08-27 10:51:43 -06:00
Jaret Burkett
deb409085a Made it possible to use the flux 2 small decoder VAE when setting the vae_path manually for flux2 models 2026-04-30 05:42:31 -06:00
Jaret Burkett
7ccec8ec2c Add checkpointing and a proper decode for flux 2 VAEs so they can be used with DFE 2026-04-30 04:27:13 -06:00
M. Hofer
f213e3b1e5 Fix FLUX2 Klein load-time VRAM spikes on low-memory GPUs. (#726)
Keep the transformer and Qwen text encoder off CUDA during initial load/quantization in low-VRAM mode so model startup avoids full-model OOM before offloading and quantization can take effect.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Jaret Burkett <jaretburkett@gmail.com>
2026-04-01 09:36:55 -06:00
Jaret Burkett
affa411edc Fixed an issue where Flux.2 model VAE can be left offloaded to CPU when encoding control images while caching latents 2026-03-29 09:49:10 -06:00
abionda-sc
4ef5cbe5bc Fixing bug where width and height are inverted for control image resizing (#707) 2026-03-28 13:00:32 -06:00
科林 KELIN
489b194231 Fix CPU/CUDA device mismatch in Klein edit control image encoding (#742)
When training Klein models with a `control_path` (edit/kontext-style
paired datasets), `encode_image_refs()` returns tensors that reside on
the VAE's device (CPU, since the VAE weights are loaded via
`load_file(..., device="cpu")` and are never explicitly moved to the
training device).  Concatenating those CPU tensors with the training
latents (`packed_latents`) that live on CUDA raises:

    RuntimeError: Expected all tensors to be on the same device

Fix: move `img_cond_seq` and `img_cond_seq_ids` to the same device
(and dtype) as `img_input` / `img_input_ids` before concatenation.

Co-authored-by: HuangYuChuh <HuangYuChuh@users.noreply.github.com>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-25 11:45:38 -06:00
Jaret Burkett
e82cf6eec2 Fixed issue that prevented full fine-tuning of flux2 models when using gradient checkpointing 2026-02-06 16:18:43 -07:00
Jaret Burkett
a6da9e37ac Add support for FLUX.2 klein base models 2026-01-17 17:46:25 -07:00
Jaret Burkett
0efed794b4 Fix issue where flux2 would ignore single control image on training 2026-01-17 20:26:35 +00:00
Jaret Burkett
01cf480233 Add FLUX.2 official weights 2025-11-25 08:52:19 -07:00
Jaret Burkett
dadbeda197 Update test weights 2025-11-23 10:51:50 -07:00
Jaret Burkett
af8e9ea149 Add initial support for FLUX.2 2025-11-18 11:17:38 -07:00