huangfeice commited on
Commit
a324fc8
·
verified ·
1 Parent(s): c749a2d

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +48 -28
README.md CHANGED
@@ -9,54 +9,74 @@ tags:
9
  base_model: jdopensource/JoyAI-Image-Edit-Diffusers
10
  ---
11
 
12
- # JoyAI-Image-Edit (ComfyUI)
13
 
14
- Repackaged single-file weights of [`jdopensource/JoyAI-Image-Edit-Diffusers`](https://huggingface.co/jdopensource/JoyAI-Image-Edit-Diffusers) for ComfyUI's standard model-folder layout. Keys, filenames and directory layout follow the [Comfy-Org](https://huggingface.co/Comfy-Org) packaging convention used by `Qwen-Image-Edit_ComfyUI` and `Wan_2.1_ComfyUI_repackaged` — drop the files into `ComfyUI/models/` and they load natively.
 
 
15
 
16
  ## Files
17
 
18
  | File | Size | Goes into | Component |
19
  |------|------|-----------|-----------|
20
- | `split_files/diffusion_models/joyai_image_edit_bf16.safetensors` | ~32 GB | `ComfyUI/models/diffusion_models/` | `JoyImageEditTransformer3DModel` (bf16) |
21
- | `split_files/text_encoders/qwen_3vl_8b_joyimage_bf16.safetensors` | ~17 GB | `ComfyUI/models/text_encoders/` | Qwen3-VL-8B text encoder, JoyImage-finetuned (bf16) |
22
- | `split_files/vae/wan_2.1_vae.safetensors` | ~250 MB | `ComfyUI/models/vae/` | Wan 2.1 VAE (shared with Wan / Qwen-Image; bf16) |
23
 
24
- The VAE is the standard Wan 2.1 VAE — bit-identical to [`Comfy-Org/Wan_2.1_ComfyUI_repackaged/split_files/vae/wan_2.1_vae.safetensors`](https://huggingface.co/Comfy-Org/Wan_2.1_ComfyUI_repackaged/blob/main/split_files/vae/wan_2.1_vae.safetensors). If you already have it from Wan or Qwen-Image, you can skip the VAE here.
25
 
26
- ## Quick start
27
 
28
- ```bash
29
- # Download into ComfyUI/models/ (skips split_files/ wrapper):
30
- hf download jdopensource/JoyAI-Image-Edit-ComfyUI \
31
- --include "split_files/*" \
32
- --local-dir /path/to/ComfyUI/models \
33
- --local-dir-use-symlinks False
34
 
35
- # Or fetch each file individually into the matching model folder.
 
 
 
36
  ```
37
 
38
- ## Requirements
39
 
40
- Native JoyImageEdit support is in flight upstream against [Comfy-Org/ComfyUI](https://github.com/comfyanonymous/ComfyUI). Until the PR lands, install ComfyUI from the JoyAI fork's branch:
41
 
42
  ```bash
43
- git clone https://github.com/jd-opensource/JoyAI-Image.git
44
- # follow the ComfyUI branch instructions in JoyAI-Image/README.md
45
  ```
46
 
47
- When the upstream PR merges, plain `comfyanonymous/ComfyUI` will detect and load these files with no extra setup.
 
 
48
 
49
- ## Key namespaces
50
 
51
- For developers / quantizers — the top-level state-dict prefixes in each file:
 
 
 
 
 
52
 
53
- - **diffusion_models**: raw transformer keys (`double_blocks.*`, `condition_embedder.*`, `img_in.*`, `proj_out.*`, `norm_out.*`). No `model.diffusion_model.` wrapper. Auto-detected by ComfyUI's `model_detection.py`.
54
- - **text_encoders**: HF Qwen3-VL keys (`model.language_model.*`, `model.visual.*`, `lm_head.*`). ComfyUI strips the `model.` wrappers internally.
55
- - **vae**: standard Comfy-Org Wan 2.1 VAE keys (`encoder.{conv1,downsamples,middle}.*`, `decoder.{conv1,upsamples,middle,head}.*`, plus top-level `conv1.*`/`conv2.*` for the post-quant projections).
 
 
 
 
 
 
 
 
 
 
 
 
 
56
 
57
  ## Links
58
 
59
- - Source code & nodes: [github.com/jd-opensource/JoyAI-Image](https://github.com/jd-opensource/JoyAI-Image)
60
- - Diffusers weights: [jdopensource/JoyAI-Image-Edit-Diffusers](https://huggingface.co/jdopensource/JoyAI-Image-Edit-Diffusers)
61
- - GGUF quantizations (community): [huangfeice/JoyAI-Image-Edit-Diffusers-GGUF](https://huggingface.co/huangfeice/JoyAI-Image-Edit-Diffusers-GGUF)
62
- - License: Apache 2.0
 
9
  base_model: jdopensource/JoyAI-Image-Edit-Diffusers
10
  ---
11
 
12
+ # JoyAI-Image-Edit (ComfyUI weights)
13
 
14
+ Single-file `.safetensors` checkpoints of [JoyAI-Image-Edit](https://github.com/jd-opensource/JoyAI-Image), repackaged for **native ComfyUI** support (no custom node required).
15
+
16
+ JoyAI-Image-Edit is the single-image instruction-guided editing model of the [JoyAI-Image](https://github.com/jd-opensource/JoyAI-Image) family. It takes one reference image plus a text instruction and generates the edited result.
17
 
18
  ## Files
19
 
20
  | File | Size | Goes into | Component |
21
  |------|------|-----------|-----------|
22
+ | `diffusion_models/joy_image_edit_bf16.safetensors` | ~31 GB | `ComfyUI/models/diffusion_models/` | `JoyImageEditTransformer3DModel` (bf16) |
23
+ | `text_encoders/qwen3vl_joyimage_bf16.safetensors` | ~17 GB | `ComfyUI/models/text_encoders/` | Qwen3-VL-8B text encoder (bf16) |
24
+ | `vae/joy_image_edit_vae.safetensors` | ~243 MB | `ComfyUI/models/vae/` | `AutoencoderKLWan` |
25
 
26
+ The repo's directory layout already matches `ComfyUI/models/`, so a single `hf download` into your models root drops every file where it needs to go.
27
 
28
+ ## Installation
29
 
30
+ The model runs natively in ComfyUI. Native support is proposed upstream in [Comfy-Org/ComfyUI#14428](https://github.com/Comfy-Org/ComfyUI/pull/14428); until it is merged, install the fork branch:
 
 
 
 
 
31
 
32
+ ```bash
33
+ git clone -b joyimage-edit-pr https://github.com/feice-huang/ComfyUI.git
34
+ cd ComfyUI
35
+ pip install -r requirements.txt
36
  ```
37
 
38
+ Once the PR is merged upstream, the stock ComfyUI release will run these weights with no fork needed.
39
 
40
+ Then download the weights straight into `ComfyUI/models/`:
41
 
42
  ```bash
43
+ hf download jdopensource/JoyAI-Image-Edit-ComfyUI \
44
+ --local-dir /path/to/ComfyUI/models
45
  ```
46
 
47
+ Restart ComfyUI.
48
+
49
+ ## Usage
50
 
51
+ Build the graph from these native nodes:
52
 
53
+ 1. **Load Diffusion Model** (`UNETLoader`) → `diffusion_models/joy_image_edit_bf16.safetensors`
54
+ 2. **Load CLIP** (`CLIPLoader`) → `text_encoders/qwen3vl_joyimage_bf16.safetensors`, type `joyimage`
55
+ 3. **Load VAE** (`VAELoader`) → `vae/joy_image_edit_vae.safetensors`
56
+ 4. **Load Image** (`LoadImage`) for the reference
57
+ 5. **TextEncodeJoyImageEdit** — feed `clip`, `vae`, the instruction, and the reference `image`. Wire one instance for the positive prompt and one (empty prompt, same image) for the negative. The node bucket-resizes the reference to the 1024-base buckets, VAE-encodes it, and appends the reference latent to the conditioning; its `image` output feeds `VAEDecode` / empty-latent sizing.
58
+ 6. **KSampler** → **VAEDecode** → **SaveImage**
59
 
60
+ Example workflow: [workflow_joyimage_edit.json](https://github.com/user-attachments/files/28871922/workflow_joyimage_edit.json)
61
+
62
+ ## Recommended parameters
63
+
64
+ | Parameter | Value |
65
+ |-----------|-------|
66
+ | Steps | 40 |
67
+ | CFG | 4.0 |
68
+ | Sampler | `euler` |
69
+ | Scheduler | `simple` |
70
+ | dtype | bf16 |
71
+ | Resolution | auto (1024-base buckets) |
72
+
73
+ ## GGUF quantizations
74
+
75
+ Lower-bit GGUF quants of the transformer and text encoder are available at [huangfeice/JoyAI-Image-Edit-Diffusers-GGUF](https://huggingface.co/huangfeice/JoyAI-Image-Edit-Diffusers-GGUF) (community contribution). The VAE here is the only VAE you need — GGUF doesn't quantize the VAE.
76
 
77
  ## Links
78
 
79
+ - Source code and documentation: [github.com/jd-opensource/JoyAI-Image](https://github.com/jd-opensource/JoyAI-Image)
80
+ - Original Diffusers-format weights: [jdopensource/JoyAI-Image-Edit-Diffusers](https://huggingface.co/jdopensource/JoyAI-Image-Edit-Diffusers)
81
+ - Multi-image edit model (ComfyUI): [jdopensource/JoyAI-Image-Edit-Plus-ComfyUI](https://huggingface.co/jdopensource/JoyAI-Image-Edit-Plus-ComfyUI)
82
+