VishnuPJ commited on
Commit
ecf28b9
·
verified ·
1 Parent(s): 1b49d46

Upload ComfyUI models

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. .gitattributes +115 -0
  2. LanPaint/.editorconfig +21 -0
  3. LanPaint/.github/ISSUE_TEMPLATE.md +15 -0
  4. LanPaint/.github/workflows/build-pipeline.yml +35 -0
  5. LanPaint/.github/workflows/publish_action.yml +24 -0
  6. LanPaint/.github/workflows/publish_node.yml +21 -0
  7. LanPaint/.github/workflows/validate.yml +15 -0
  8. LanPaint/.gitignore +102 -0
  9. LanPaint/.pre-commit-config.yaml +10 -0
  10. LanPaint/.tracking +155 -0
  11. LanPaint/.vscode/settings.json +12 -0
  12. LanPaint/Example.JPG +3 -0
  13. LanPaint/LICENSE +674 -0
  14. LanPaint/MANIFEST.in +9 -0
  15. LanPaint/Nodes.JPG +3 -0
  16. LanPaint/README.md +565 -0
  17. LanPaint/__init__.py +94 -0
  18. LanPaint/__pycache__/__init__.cpython-312.pyc +0 -0
  19. LanPaint/build/lib/LanPaint/__init__.py +0 -0
  20. LanPaint/build/lib/LanPaint/earlystop.py +337 -0
  21. LanPaint/build/lib/LanPaint/lanpaint.py +272 -0
  22. LanPaint/build/lib/LanPaint/nodes.py +648 -0
  23. LanPaint/build/lib/LanPaint/types.py +10 -0
  24. LanPaint/build/lib/LanPaint/utils.py +300 -0
  25. LanPaint/example_workflows/Flux.2.Dev_Inpaint.jpg +3 -0
  26. LanPaint/example_workflows/Flux.2.Dev_Inpaint.json +1886 -0
  27. LanPaint/example_workflows/Flux2_Klein_inpainting.jpg +3 -0
  28. LanPaint/example_workflows/Flux2_Klein_inpainting.json +2665 -0
  29. LanPaint/example_workflows/Flux_Inpaint.jpg +3 -0
  30. LanPaint/example_workflows/Flux_Inpaint.json +786 -0
  31. LanPaint/example_workflows/Hunyuan_Inpaint.jpg +3 -0
  32. LanPaint/example_workflows/Hunyuan_Inpaint.json +1033 -0
  33. LanPaint/example_workflows/Masked_Qwen_Image_Edit.jpg +3 -0
  34. LanPaint/example_workflows/Masked_Qwen_Image_Edit.json +1636 -0
  35. LanPaint/example_workflows/Masked_Qwen_Image_Edit_2509.jpg +3 -0
  36. LanPaint/example_workflows/Masked_Qwen_Image_Edit_2509.json +1829 -0
  37. LanPaint/example_workflows/Qwen_Image_Inpaint.jpg +3 -0
  38. LanPaint/example_workflows/Qwen_Image_Inpaint.json +806 -0
  39. LanPaint/example_workflows/Qwen_Image_Outpaint.jpg +3 -0
  40. LanPaint/example_workflows/Qwen_Image_Outpaint.json +909 -0
  41. LanPaint/example_workflows/SDXL_Inpaint.jpg +3 -0
  42. LanPaint/example_workflows/SDXL_Inpaint.json +735 -0
  43. LanPaint/example_workflows/Z_image_Inpaint.jpg +3 -0
  44. LanPaint/example_workflows/Z_image_Inpaint.json +1475 -0
  45. LanPaint/example_workflows/Z_image_base_Inpaint.jpg +3 -0
  46. LanPaint/example_workflows/Z_image_base_Inpaint.json +1548 -0
  47. LanPaint/example_workflows/wan2_2_T2I_Inpaint.jpg +3 -0
  48. LanPaint/example_workflows/wan2_2_T2I_Inpaint.json +1330 -0
  49. LanPaint/example_workflows/wan2_2_T2I_Partial_Inpaint.jpg +3 -0
  50. LanPaint/example_workflows/wan2_2_T2I_Partial_Inpaint.json +1128 -0
.gitattributes CHANGED
@@ -33,3 +33,118 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
36
+ comfyui-qwen-asr/assets/intro.png filter=lfs diff=lfs merge=lfs -text
37
+ LanPaint/Example.JPG filter=lfs diff=lfs merge=lfs -text
38
+ LanPaint/example_workflows/Flux.2.Dev_Inpaint.jpg filter=lfs diff=lfs merge=lfs -text
39
+ LanPaint/example_workflows/Flux2_Klein_inpainting.jpg filter=lfs diff=lfs merge=lfs -text
40
+ LanPaint/example_workflows/Flux_Inpaint.jpg filter=lfs diff=lfs merge=lfs -text
41
+ LanPaint/example_workflows/Hunyuan_Inpaint.jpg filter=lfs diff=lfs merge=lfs -text
42
+ LanPaint/example_workflows/Masked_Qwen_Image_Edit.jpg filter=lfs diff=lfs merge=lfs -text
43
+ LanPaint/example_workflows/Masked_Qwen_Image_Edit_2509.jpg filter=lfs diff=lfs merge=lfs -text
44
+ LanPaint/example_workflows/Qwen_Image_Inpaint.jpg filter=lfs diff=lfs merge=lfs -text
45
+ LanPaint/example_workflows/Qwen_Image_Outpaint.jpg filter=lfs diff=lfs merge=lfs -text
46
+ LanPaint/example_workflows/SDXL_Inpaint.jpg filter=lfs diff=lfs merge=lfs -text
47
+ LanPaint/example_workflows/wan2_2_T2I_Inpaint.jpg filter=lfs diff=lfs merge=lfs -text
48
+ LanPaint/example_workflows/wan2_2_T2I_Partial_Inpaint.jpg filter=lfs diff=lfs merge=lfs -text
49
+ LanPaint/example_workflows/Z_image_base_Inpaint.jpg filter=lfs diff=lfs merge=lfs -text
50
+ LanPaint/example_workflows/Z_image_Inpaint.jpg filter=lfs diff=lfs merge=lfs -text
51
+ LanPaint/examples/Example_1/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
52
+ LanPaint/examples/Example_1/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
53
+ LanPaint/examples/Example_1/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
54
+ LanPaint/examples/Example_10/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
55
+ LanPaint/examples/Example_10/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
56
+ LanPaint/examples/Example_11/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
57
+ LanPaint/examples/Example_11/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
58
+ LanPaint/examples/Example_12/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
59
+ LanPaint/examples/Example_12/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
60
+ LanPaint/examples/Example_13/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
61
+ LanPaint/examples/Example_13/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
62
+ LanPaint/examples/Example_13/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
63
+ LanPaint/examples/Example_14/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
64
+ LanPaint/examples/Example_14/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
65
+ LanPaint/examples/Example_14/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
66
+ LanPaint/examples/Example_14/QwenEdit_2509_InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
67
+ LanPaint/examples/Example_15/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
68
+ LanPaint/examples/Example_15/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
69
+ LanPaint/examples/Example_15/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
70
+ LanPaint/examples/Example_16/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
71
+ LanPaint/examples/Example_16/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
72
+ LanPaint/examples/Example_16/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
73
+ LanPaint/examples/Example_17/Inpainted_40frames_Drag_Me_to_ComfyUI.mp4 filter=lfs diff=lfs merge=lfs -text
74
+ LanPaint/examples/Example_17/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
75
+ LanPaint/examples/Example_17/Original_No_Mask.mp4 filter=lfs diff=lfs merge=lfs -text
76
+ LanPaint/examples/Example_17/Wan22_[[:space:]]5B_Inpainted_40frames_Drag_Me_to_ComfyUI.mp4 filter=lfs diff=lfs merge=lfs -text
77
+ LanPaint/examples/Example_18/Inpainted_40frames_Drag_Me_to_ComfyUI.mp4 filter=lfs diff=lfs merge=lfs -text
78
+ LanPaint/examples/Example_18/Inpainted_81frames_Drag_Me_to_ComfyUI.mp4 filter=lfs diff=lfs merge=lfs -text
79
+ LanPaint/examples/Example_18/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
80
+ LanPaint/examples/Example_18/Original_No_Mask.mp4 filter=lfs diff=lfs merge=lfs -text
81
+ LanPaint/examples/Example_19/Original_Load_Me_in_Loader.mp4 filter=lfs diff=lfs merge=lfs -text
82
+ LanPaint/examples/Example_19/Outpainted_40frames_Drag_Me_to_ComfyUI.mp4 filter=lfs diff=lfs merge=lfs -text
83
+ LanPaint/examples/Example_19/Outpainted_41frames_Drag_Me_to_ComfyUI.mp4 filter=lfs diff=lfs merge=lfs -text
84
+ LanPaint/examples/Example_2/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
85
+ LanPaint/examples/Example_2/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
86
+ LanPaint/examples/Example_2/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
87
+ LanPaint/examples/Example_20/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
88
+ LanPaint/examples/Example_20/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
89
+ LanPaint/examples/Example_20/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
90
+ LanPaint/examples/Example_21/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
91
+ LanPaint/examples/Example_21/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
92
+ LanPaint/examples/Example_21/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
93
+ LanPaint/examples/Example_22/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
94
+ LanPaint/examples/Example_22/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
95
+ LanPaint/examples/Example_22/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
96
+ LanPaint/examples/Example_23/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
97
+ LanPaint/examples/Example_23/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
98
+ LanPaint/examples/Example_23/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
99
+ LanPaint/examples/Example_24/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
100
+ LanPaint/examples/Example_24/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
101
+ LanPaint/examples/Example_24/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
102
+ LanPaint/examples/Example_25/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
103
+ LanPaint/examples/Example_25/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
104
+ LanPaint/examples/Example_25/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
105
+ LanPaint/examples/Example_3/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
106
+ LanPaint/examples/Example_3/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
107
+ LanPaint/examples/Example_3/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
108
+ LanPaint/examples/Example_4/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
109
+ LanPaint/examples/Example_4/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
110
+ LanPaint/examples/Example_4/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
111
+ LanPaint/examples/Example_5/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
112
+ LanPaint/examples/Example_5/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
113
+ LanPaint/examples/Example_5/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
114
+ LanPaint/examples/Example_6/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
115
+ LanPaint/examples/Example_6/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
116
+ LanPaint/examples/Example_6/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
117
+ LanPaint/examples/Example_7/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
118
+ LanPaint/examples/Example_7/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
119
+ LanPaint/examples/Example_7/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
120
+ LanPaint/examples/Example_8/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
121
+ LanPaint/examples/Example_8/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
122
+ LanPaint/examples/Example_8/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
123
+ LanPaint/examples/Example_9/InPainted_Drag_Me_to_ComfyUI.png filter=lfs diff=lfs merge=lfs -text
124
+ LanPaint/examples/Example_9/Masked_Load_Me_in_Loader.png filter=lfs diff=lfs merge=lfs -text
125
+ LanPaint/examples/Example_9/Original_No_Mask.png filter=lfs diff=lfs merge=lfs -text
126
+ LanPaint/examples/InpaintChara_04.jpg filter=lfs diff=lfs merge=lfs -text
127
+ LanPaint/examples/InpaintChara_05.jpg filter=lfs diff=lfs merge=lfs -text
128
+ LanPaint/examples/InpaintChara_06.jpg filter=lfs diff=lfs merge=lfs -text
129
+ LanPaint/examples/InpaintChara_07.jpg filter=lfs diff=lfs merge=lfs -text
130
+ LanPaint/examples/InpaintChara_08.jpg filter=lfs diff=lfs merge=lfs -text
131
+ LanPaint/examples/InpaintChara_09.jpg filter=lfs diff=lfs merge=lfs -text
132
+ LanPaint/examples/InpaintChara_10.jpg filter=lfs diff=lfs merge=lfs -text
133
+ LanPaint/examples/InpaintChara_11.jpg filter=lfs diff=lfs merge=lfs -text
134
+ LanPaint/examples/InpaintChara_12.jpg filter=lfs diff=lfs merge=lfs -text
135
+ LanPaint/examples/InpaintChara_13(1).jpg filter=lfs diff=lfs merge=lfs -text
136
+ LanPaint/examples/InpaintChara_13.jpg filter=lfs diff=lfs merge=lfs -text
137
+ LanPaint/examples/InpaintChara_14.jpg filter=lfs diff=lfs merge=lfs -text
138
+ LanPaint/examples/InpaintChara_45.jpg filter=lfs diff=lfs merge=lfs -text
139
+ LanPaint/examples/InpaintChara_46.jpg filter=lfs diff=lfs merge=lfs -text
140
+ LanPaint/examples/Inpainted_40frames_Drag_Me_to_ComfyUI_example17.gif filter=lfs diff=lfs merge=lfs -text
141
+ LanPaint/examples/Inpainted_81frames_Drag_Me_to_ComfyUI_example18.gif filter=lfs diff=lfs merge=lfs -text
142
+ LanPaint/examples/LanPaintQwen_01.jpg filter=lfs diff=lfs merge=lfs -text
143
+ LanPaint/examples/LanPaintQwen_03.jpg filter=lfs diff=lfs merge=lfs -text
144
+ LanPaint/examples/LanPaintQwen_04.jpg filter=lfs diff=lfs merge=lfs -text
145
+ LanPaint/examples/Mask_Example19_.png filter=lfs diff=lfs merge=lfs -text
146
+ LanPaint/examples/Original_Load_Me_in_Loader_example19.gif filter=lfs diff=lfs merge=lfs -text
147
+ LanPaint/examples/Original_No_Mask-example18.gif filter=lfs diff=lfs merge=lfs -text
148
+ LanPaint/examples/Original_No_Mask_example17.gif filter=lfs diff=lfs merge=lfs -text
149
+ LanPaint/examples/Outpainted_40frames_Drag_Me_to_ComfyUI_example19.gif filter=lfs diff=lfs merge=lfs -text
150
+ LanPaint/Nodes.JPG filter=lfs diff=lfs merge=lfs -text
LanPaint/.editorconfig ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # http://editorconfig.org
2
+
3
+ root = true
4
+
5
+ [*]
6
+ indent_style = space
7
+ indent_size = 4
8
+ trim_trailing_whitespace = true
9
+ insert_final_newline = true
10
+ charset = utf-8
11
+ end_of_line = lf
12
+
13
+ [*.bat]
14
+ indent_style = tab
15
+ end_of_line = crlf
16
+
17
+ [LICENSE]
18
+ insert_final_newline = false
19
+
20
+ [Makefile]
21
+ indent_style = tab
LanPaint/.github/ISSUE_TEMPLATE.md ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ * LanPaint version:
2
+ * Python version:
3
+ * Operating System:
4
+
5
+ ### Description
6
+
7
+ Describe what you were trying to get done.
8
+ Tell us what happened, what went wrong, and what you expected to happen.
9
+
10
+ ### What I Did
11
+
12
+ ```
13
+ Paste the command(s) you ran and the output.
14
+ If there was a crash, please include the traceback here.
15
+ ```
LanPaint/.github/workflows/build-pipeline.yml ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # GitHub CI build pipeline
2
+ name: LanPaint CI build
3
+
4
+ on:
5
+ pull_request:
6
+ branches:
7
+ - master
8
+ - main
9
+ jobs:
10
+ build:
11
+ runs-on: ${{ matrix.os }}
12
+ env:
13
+ PYTHONIOENCODING: "utf8"
14
+ strategy:
15
+ matrix:
16
+ os: [ubuntu-latest]
17
+ python-version: ["3.12"]
18
+
19
+ steps:
20
+ - uses: actions/checkout@v4
21
+ - name: Set up Python
22
+ uses: actions/setup-python@v5
23
+ with:
24
+ python-version: ${{ matrix.python-version }}
25
+ - name: Install dependencies
26
+ run: |
27
+ python -m pip install --upgrade pip
28
+ pip install .[dev]
29
+ pip install torch --extra-index-url https://download.pytorch.org/whl/cpu
30
+ - name: Run Linting
31
+ run: |
32
+ ruff check .
33
+ - name: Run Tests
34
+ run: |
35
+ pytest tests/
LanPaint/.github/workflows/publish_action.yml ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: Publish to Comfy registry
2
+ on:
3
+ workflow_dispatch:
4
+ push:
5
+ branches:
6
+ - main
7
+ paths:
8
+ - "pyproject.toml"
9
+
10
+ permissions:
11
+ issues: write
12
+
13
+ jobs:
14
+ publish-node:
15
+ name: Publish Custom Node to registry
16
+ runs-on: ubuntu-latest
17
+ if: ${{ github.repository_owner == 'scraed' }}
18
+ steps:
19
+ - name: Check out code
20
+ uses: actions/checkout@v4
21
+ - name: Publish Custom Node
22
+ uses: Comfy-Org/publish-node-action@v1
23
+ with:
24
+ personal_access_token: ${{ secrets.REGISTRY_ACCESS_TOKEN }} ## Add your own personal access token to your Github Repository secrets and reference it here.
LanPaint/.github/workflows/publish_node.yml ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: 📦 Publish to Comfy registry
2
+ on:
3
+ workflow_dispatch:
4
+ push:
5
+ tags:
6
+ - '*'
7
+
8
+ permissions:
9
+ issues: write
10
+
11
+ jobs:
12
+ publish-node:
13
+ name: Publish Custom Node to registry
14
+ runs-on: ubuntu-latest
15
+ steps:
16
+ - name: ♻️ Check out code
17
+ uses: actions/checkout@v4
18
+ - name: 📦 Publish Custom Node
19
+ uses: Comfy-Org/publish-node-action@main
20
+ with:
21
+ personal_access_token: ${{ secrets.REGISTRY_ACCESS_TOKEN }}
LanPaint/.github/workflows/validate.yml ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: Validate backwards compatibility
2
+
3
+ on:
4
+ pull_request:
5
+ branches:
6
+ - master
7
+ - main
8
+
9
+ jobs:
10
+ validate:
11
+ runs-on: ubuntu-latest
12
+ steps:
13
+ - uses: comfy-org/node-diff@main
14
+ with:
15
+ base_ref: ${{ github.event.repository.default_branch }}
LanPaint/.gitignore ADDED
@@ -0,0 +1,102 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+
6
+ # OSX useful to ignore
7
+ *.DS_Store
8
+ .AppleDouble
9
+ .LSOverride
10
+
11
+ # Thumbnails
12
+ ._*
13
+
14
+ # Files that might appear in the root of a volume
15
+ .DocumentRevisions-V100
16
+ .fseventsd
17
+ .Spotlight-V100
18
+ .TemporaryItems
19
+ .Trashes
20
+ .VolumeIcon.icns
21
+ .com.apple.timemachine.donotpresent
22
+
23
+ # Directories potentially created on remote AFP share
24
+ .AppleDB
25
+ .AppleDesktop
26
+ Network Trash Folder
27
+ Temporary Items
28
+ .apdisk
29
+
30
+ # C extensions
31
+ *.so
32
+
33
+ # Distribution / packaging
34
+ .Python
35
+ env/
36
+ venv/
37
+ build/
38
+ develop-eggs/
39
+ dist/
40
+ downloads/
41
+ eggs/
42
+ .eggs/
43
+ lib/
44
+ lib64/
45
+ parts/
46
+ sdist/
47
+ var/
48
+ *.egg-info/
49
+ .installed.cfg
50
+ *.egg
51
+
52
+ # PyInstaller
53
+ # Usually these files are written by a python script from a template
54
+ # before PyInstaller builds the exe, so as to inject date/other infos into it.
55
+ *.manifest
56
+ *.spec
57
+
58
+ # Installer logs
59
+ pip-log.txt
60
+ pip-delete-this-directory.txt
61
+
62
+ # Unit test / coverage reports
63
+ htmlcov/
64
+ .tox/
65
+ .coverage
66
+ .coverage.*
67
+ .cache
68
+ nosetests.xml
69
+ coverage.xml
70
+ *,cover
71
+ .hypothesis/
72
+ .pytest_cache/
73
+
74
+ # Translations
75
+ *.mo
76
+ *.pot
77
+
78
+ # Django stuff:
79
+ *.log
80
+
81
+ # Sphinx documentation
82
+ docs/_build/
83
+
84
+ # IntelliJ Idea
85
+ .idea
86
+ *.iml
87
+ *.ipr
88
+ *.iws
89
+
90
+ # PyBuilder
91
+ target/
92
+
93
+ # Cookiecutter
94
+ output/
95
+ python_boilerplate/
96
+ cookiecutter-pypackage-env/
97
+
98
+ # vscode settings
99
+ .history/
100
+ *.code-workspace
101
+ .vscode/
102
+ /.vscode
LanPaint/.pre-commit-config.yaml ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ repos:
2
+ - repo: https://github.com/astral-sh/ruff-pre-commit
3
+ # Ruff version.
4
+ rev: v0.4.9
5
+ hooks:
6
+ # Run the linter.
7
+ - id: ruff
8
+ args: [ --fix ]
9
+ # Run the formatter.
10
+ - id: ruff-format
LanPaint/.tracking ADDED
@@ -0,0 +1,155 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .editorconfig
2
+ .github/ISSUE_TEMPLATE.md
3
+ .github/workflows/build-pipeline.yml
4
+ .github/workflows/publish_action.yml
5
+ .github/workflows/publish_node.yml
6
+ .github/workflows/validate.yml
7
+ .gitignore
8
+ .pre-commit-config.yaml
9
+ .vscode/settings.json
10
+ Example.JPG
11
+ LICENSE
12
+ MANIFEST.in
13
+ Nodes.JPG
14
+ README.md
15
+ __init__.py
16
+ example_workflows/Flux.2.Dev_Inpaint.jpg
17
+ example_workflows/Flux.2.Dev_Inpaint.json
18
+ example_workflows/Flux2_Klein_inpainting.jpg
19
+ example_workflows/Flux2_Klein_inpainting.json
20
+ example_workflows/Flux_Inpaint.jpg
21
+ example_workflows/Flux_Inpaint.json
22
+ example_workflows/Hunyuan_Inpaint.jpg
23
+ example_workflows/Hunyuan_Inpaint.json
24
+ example_workflows/Masked_Qwen_Image_Edit.jpg
25
+ example_workflows/Masked_Qwen_Image_Edit.json
26
+ example_workflows/Masked_Qwen_Image_Edit_2509.jpg
27
+ example_workflows/Masked_Qwen_Image_Edit_2509.json
28
+ example_workflows/Qwen_Image_Inpaint.jpg
29
+ example_workflows/Qwen_Image_Inpaint.json
30
+ example_workflows/Qwen_Image_Outpaint.jpg
31
+ example_workflows/Qwen_Image_Outpaint.json
32
+ example_workflows/SDXL_Inpaint.jpg
33
+ example_workflows/SDXL_Inpaint.json
34
+ example_workflows/Z_image_Inpaint.jpg
35
+ example_workflows/Z_image_Inpaint.json
36
+ example_workflows/Z_image_base_Inpaint.jpg
37
+ example_workflows/Z_image_base_Inpaint.json
38
+ example_workflows/wan2_2_T2I_Inpaint.jpg
39
+ example_workflows/wan2_2_T2I_Inpaint.json
40
+ example_workflows/wan2_2_T2I_Partial_Inpaint.jpg
41
+ example_workflows/wan2_2_T2I_Partial_Inpaint.json
42
+ examples/Example_1/InPainted_Drag_Me_to_ComfyUI.png
43
+ examples/Example_1/Masked_Load_Me_in_Loader.png
44
+ examples/Example_1/Original_No_Mask.png
45
+ examples/Example_10/InPainted_Drag_Me_to_ComfyUI.png
46
+ examples/Example_10/Masked_Load_Me_in_Loader.png
47
+ examples/Example_11/InPainted_Drag_Me_to_ComfyUI.png
48
+ examples/Example_11/Masked_Load_Me_in_Loader.png
49
+ examples/Example_12/InPainted_Drag_Me_to_ComfyUI.png
50
+ examples/Example_12/Masked_Load_Me_in_Loader.png
51
+ examples/Example_13/InPainted_Drag_Me_to_ComfyUI.png
52
+ examples/Example_13/Masked_Load_Me_in_Loader.png
53
+ examples/Example_13/Original_No_Mask.png
54
+ examples/Example_14/InPainted_Drag_Me_to_ComfyUI.png
55
+ examples/Example_14/Masked_Load_Me_in_Loader.png
56
+ examples/Example_14/Original_No_Mask.png
57
+ examples/Example_14/QwenEdit_2509_InPainted_Drag_Me_to_ComfyUI.png
58
+ examples/Example_15/InPainted_Drag_Me_to_ComfyUI.png
59
+ examples/Example_15/Masked_Load_Me_in_Loader.png
60
+ examples/Example_15/Original_No_Mask.png
61
+ examples/Example_16/InPainted_Drag_Me_to_ComfyUI.png
62
+ examples/Example_16/Masked_Load_Me_in_Loader.png
63
+ examples/Example_16/Original_No_Mask.png
64
+ examples/Example_17/Inpainted_40frames_Drag_Me_to_ComfyUI.mp4
65
+ examples/Example_17/Masked_Load_Me_in_Loader.png
66
+ examples/Example_17/Original_No_Mask.mp4
67
+ examples/Example_17/Wan22_ 5B_Inpainted_40frames_Drag_Me_to_ComfyUI.mp4
68
+ examples/Example_18/Inpainted_40frames_Drag_Me_to_ComfyUI.mp4
69
+ examples/Example_18/Inpainted_81frames_Drag_Me_to_ComfyUI.mp4
70
+ examples/Example_18/Masked_Load_Me_in_Loader.png
71
+ examples/Example_18/Original_No_Mask.mp4
72
+ examples/Example_19/Original_Load_Me_in_Loader.mp4
73
+ examples/Example_19/Outpainted_40frames_Drag_Me_to_ComfyUI.mp4
74
+ examples/Example_19/Outpainted_41frames_Drag_Me_to_ComfyUI.mp4
75
+ examples/Example_2/InPainted_Drag_Me_to_ComfyUI.png
76
+ examples/Example_2/Masked_Load_Me_in_Loader.png
77
+ examples/Example_2/Original_No_Mask.png
78
+ examples/Example_20/InPainted_Drag_Me_to_ComfyUI.png
79
+ examples/Example_20/Masked_Load_Me_in_Loader.png
80
+ examples/Example_20/Original_No_Mask.png
81
+ examples/Example_21/InPainted_Drag_Me_to_ComfyUI.png
82
+ examples/Example_21/Masked_Load_Me_in_Loader.png
83
+ examples/Example_21/Original_No_Mask.png
84
+ examples/Example_22/InPainted_Drag_Me_to_ComfyUI.png
85
+ examples/Example_22/Masked_Load_Me_in_Loader.png
86
+ examples/Example_22/Original_No_Mask.png
87
+ examples/Example_23/InPainted_Drag_Me_to_ComfyUI.png
88
+ examples/Example_23/Masked_Load_Me_in_Loader.png
89
+ examples/Example_23/Original_No_Mask.png
90
+ examples/Example_24/InPainted_Drag_Me_to_ComfyUI.png
91
+ examples/Example_24/Masked_Load_Me_in_Loader.png
92
+ examples/Example_24/Original_No_Mask.png
93
+ examples/Example_25/InPainted_Drag_Me_to_ComfyUI.png
94
+ examples/Example_25/Masked_Load_Me_in_Loader.png
95
+ examples/Example_25/Original_No_Mask.png
96
+ examples/Example_3/InPainted_Drag_Me_to_ComfyUI.png
97
+ examples/Example_3/Masked_Load_Me_in_Loader.png
98
+ examples/Example_3/Original_No_Mask.png
99
+ examples/Example_4/InPainted_Drag_Me_to_ComfyUI.png
100
+ examples/Example_4/Masked_Load_Me_in_Loader.png
101
+ examples/Example_4/Original_No_Mask.png
102
+ examples/Example_5/InPainted_Drag_Me_to_ComfyUI.png
103
+ examples/Example_5/Masked_Load_Me_in_Loader.png
104
+ examples/Example_5/Original_No_Mask.png
105
+ examples/Example_6/InPainted_Drag_Me_to_ComfyUI.png
106
+ examples/Example_6/Masked_Load_Me_in_Loader.png
107
+ examples/Example_6/Original_No_Mask.png
108
+ examples/Example_7/InPainted_Drag_Me_to_ComfyUI.png
109
+ examples/Example_7/Masked_Load_Me_in_Loader.png
110
+ examples/Example_7/Original_No_Mask.png
111
+ examples/Example_8/InPainted_Drag_Me_to_ComfyUI.png
112
+ examples/Example_8/Masked_Load_Me_in_Loader.png
113
+ examples/Example_8/Original_No_Mask.png
114
+ examples/Example_9/InPainted_Drag_Me_to_ComfyUI.png
115
+ examples/Example_9/Masked_Load_Me_in_Loader.png
116
+ examples/Example_9/Original_No_Mask.png
117
+ examples/InpaintChara_04.jpg
118
+ examples/InpaintChara_05.jpg
119
+ examples/InpaintChara_06.jpg
120
+ examples/InpaintChara_07.jpg
121
+ examples/InpaintChara_08.jpg
122
+ examples/InpaintChara_09.jpg
123
+ examples/InpaintChara_10.jpg
124
+ examples/InpaintChara_11.jpg
125
+ examples/InpaintChara_12.jpg
126
+ examples/InpaintChara_13(1).jpg
127
+ examples/InpaintChara_13.jpg
128
+ examples/InpaintChara_14.jpg
129
+ examples/InpaintChara_45.jpg
130
+ examples/InpaintChara_46.jpg
131
+ examples/Inpainted_40frames_Drag_Me_to_ComfyUI_example17.gif
132
+ examples/Inpainted_81frames_Drag_Me_to_ComfyUI_example18.gif
133
+ examples/LanPaintQwen_01.jpg
134
+ examples/LanPaintQwen_03.jpg
135
+ examples/LanPaintQwen_04.jpg
136
+ examples/Mask_Example19_.png
137
+ examples/Original_Load_Me_in_Loader_example19.gif
138
+ examples/Original_No_Mask-example18.gif
139
+ examples/Original_No_Mask_example17.gif
140
+ examples/Outpainted_40frames_Drag_Me_to_ComfyUI_example19.gif
141
+ pyproject.toml
142
+ src/LanPaint/__init__.py
143
+ src/LanPaint/earlystop.py
144
+ src/LanPaint/lanpaint.py
145
+ src/LanPaint/nodes.py
146
+ src/LanPaint/types.py
147
+ src/LanPaint/utils.py
148
+ tests/__init__.py
149
+ tests/conftest.py
150
+ tests/pytest.ini
151
+ tests/test_LanPaint.py
152
+ tests/test_lanpaint_semantic_stop.py
153
+ tests/test_reshape_mask.py
154
+ tests/test_sho_regression.py
155
+ web/js/example.js
LanPaint/.vscode/settings.json ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ // Required - change /PATH/TO to the absolute path to ComfyUI. Windows e.g.: D:/My Folder/ComfyUI/
3
+ // This pulls in ComfyUI Python types for the extension.
4
+ "python.analysis.extraPaths": [
5
+ "/PATH/TO/ComfyUI/",
6
+ "/PATH/TO/ComfyUI/custom_nodes/"
7
+ ],
8
+ "cursorpyright.analysis.extraPaths": [
9
+ "/PATH/TO/ComfyUI/",
10
+ "/PATH/TO/ComfyUI/custom_nodes/"
11
+ ],
12
+ }
LanPaint/Example.JPG ADDED

Git LFS Details

  • SHA256: b4d1cea87e113c420e58a70bababfb8b0e9f7683d6fcbed9ab3704f851dce816
  • Pointer size: 131 Bytes
  • Size of remote file: 250 kB
LanPaint/LICENSE ADDED
@@ -0,0 +1,674 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ GNU GENERAL PUBLIC LICENSE
2
+ Version 3, 29 June 2007
3
+
4
+ Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
5
+ Everyone is permitted to copy and distribute verbatim copies
6
+ of this license document, but changing it is not allowed.
7
+
8
+ Preamble
9
+
10
+ The GNU General Public License is a free, copyleft license for
11
+ software and other kinds of works.
12
+
13
+ The licenses for most software and other practical works are designed
14
+ to take away your freedom to share and change the works. By contrast,
15
+ the GNU General Public License is intended to guarantee your freedom to
16
+ share and change all versions of a program--to make sure it remains free
17
+ software for all its users. We, the Free Software Foundation, use the
18
+ GNU General Public License for most of our software; it applies also to
19
+ any other work released this way by its authors. You can apply it to
20
+ your programs, too.
21
+
22
+ When we speak of free software, we are referring to freedom, not
23
+ price. Our General Public Licenses are designed to make sure that you
24
+ have the freedom to distribute copies of free software (and charge for
25
+ them if you wish), that you receive source code or can get it if you
26
+ want it, that you can change the software or use pieces of it in new
27
+ free programs, and that you know you can do these things.
28
+
29
+ To protect your rights, we need to prevent others from denying you
30
+ these rights or asking you to surrender the rights. Therefore, you have
31
+ certain responsibilities if you distribute copies of the software, or if
32
+ you modify it: responsibilities to respect the freedom of others.
33
+
34
+ For example, if you distribute copies of such a program, whether
35
+ gratis or for a fee, you must pass on to the recipients the same
36
+ freedoms that you received. You must make sure that they, too, receive
37
+ or can get the source code. And you must show them these terms so they
38
+ know their rights.
39
+
40
+ Developers that use the GNU GPL protect your rights with two steps:
41
+ (1) assert copyright on the software, and (2) offer you this License
42
+ giving you legal permission to copy, distribute and/or modify it.
43
+
44
+ For the developers' and authors' protection, the GPL clearly explains
45
+ that there is no warranty for this free software. For both users' and
46
+ authors' sake, the GPL requires that modified versions be marked as
47
+ changed, so that their problems will not be attributed erroneously to
48
+ authors of previous versions.
49
+
50
+ Some devices are designed to deny users access to install or run
51
+ modified versions of the software inside them, although the manufacturer
52
+ can do so. This is fundamentally incompatible with the aim of
53
+ protecting users' freedom to change the software. The systematic
54
+ pattern of such abuse occurs in the area of products for individuals to
55
+ use, which is precisely where it is most unacceptable. Therefore, we
56
+ have designed this version of the GPL to prohibit the practice for those
57
+ products. If such problems arise substantially in other domains, we
58
+ stand ready to extend this provision to those domains in future versions
59
+ of the GPL, as needed to protect the freedom of users.
60
+
61
+ Finally, every program is threatened constantly by software patents.
62
+ States should not allow patents to restrict development and use of
63
+ software on general-purpose computers, but in those that do, we wish to
64
+ avoid the special danger that patents applied to a free program could
65
+ make it effectively proprietary. To prevent this, the GPL assures that
66
+ patents cannot be used to render the program non-free.
67
+
68
+ The precise terms and conditions for copying, distribution and
69
+ modification follow.
70
+
71
+ TERMS AND CONDITIONS
72
+
73
+ 0. Definitions.
74
+
75
+ "This License" refers to version 3 of the GNU General Public License.
76
+
77
+ "Copyright" also means copyright-like laws that apply to other kinds of
78
+ works, such as semiconductor masks.
79
+
80
+ "The Program" refers to any copyrightable work licensed under this
81
+ License. Each licensee is addressed as "you". "Licensees" and
82
+ "recipients" may be individuals or organizations.
83
+
84
+ To "modify" a work means to copy from or adapt all or part of the work
85
+ in a fashion requiring copyright permission, other than the making of an
86
+ exact copy. The resulting work is called a "modified version" of the
87
+ earlier work or a work "based on" the earlier work.
88
+
89
+ A "covered work" means either the unmodified Program or a work based
90
+ on the Program.
91
+
92
+ To "propagate" a work means to do anything with it that, without
93
+ permission, would make you directly or secondarily liable for
94
+ infringement under applicable copyright law, except executing it on a
95
+ computer or modifying a private copy. Propagation includes copying,
96
+ distribution (with or without modification), making available to the
97
+ public, and in some countries other activities as well.
98
+
99
+ To "convey" a work means any kind of propagation that enables other
100
+ parties to make or receive copies. Mere interaction with a user through
101
+ a computer network, with no transfer of a copy, is not conveying.
102
+
103
+ An interactive user interface displays "Appropriate Legal Notices"
104
+ to the extent that it includes a convenient and prominently visible
105
+ feature that (1) displays an appropriate copyright notice, and (2)
106
+ tells the user that there is no warranty for the work (except to the
107
+ extent that warranties are provided), that licensees may convey the
108
+ work under this License, and how to view a copy of this License. If
109
+ the interface presents a list of user commands or options, such as a
110
+ menu, a prominent item in the list meets this criterion.
111
+
112
+ 1. Source Code.
113
+
114
+ The "source code" for a work means the preferred form of the work
115
+ for making modifications to it. "Object code" means any non-source
116
+ form of a work.
117
+
118
+ A "Standard Interface" means an interface that either is an official
119
+ standard defined by a recognized standards body, or, in the case of
120
+ interfaces specified for a particular programming language, one that
121
+ is widely used among developers working in that language.
122
+
123
+ The "System Libraries" of an executable work include anything, other
124
+ than the work as a whole, that (a) is included in the normal form of
125
+ packaging a Major Component, but which is not part of that Major
126
+ Component, and (b) serves only to enable use of the work with that
127
+ Major Component, or to implement a Standard Interface for which an
128
+ implementation is available to the public in source code form. A
129
+ "Major Component", in this context, means a major essential component
130
+ (kernel, window system, and so on) of the specific operating system
131
+ (if any) on which the executable work runs, or a compiler used to
132
+ produce the work, or an object code interpreter used to run it.
133
+
134
+ The "Corresponding Source" for a work in object code form means all
135
+ the source code needed to generate, install, and (for an executable
136
+ work) run the object code and to modify the work, including scripts to
137
+ control those activities. However, it does not include the work's
138
+ System Libraries, or general-purpose tools or generally available free
139
+ programs which are used unmodified in performing those activities but
140
+ which are not part of the work. For example, Corresponding Source
141
+ includes interface definition files associated with source files for
142
+ the work, and the source code for shared libraries and dynamically
143
+ linked subprograms that the work is specifically designed to require,
144
+ such as by intimate data communication or control flow between those
145
+ subprograms and other parts of the work.
146
+
147
+ The Corresponding Source need not include anything that users
148
+ can regenerate automatically from other parts of the Corresponding
149
+ Source.
150
+
151
+ The Corresponding Source for a work in source code form is that
152
+ same work.
153
+
154
+ 2. Basic Permissions.
155
+
156
+ All rights granted under this License are granted for the term of
157
+ copyright on the Program, and are irrevocable provided the stated
158
+ conditions are met. This License explicitly affirms your unlimited
159
+ permission to run the unmodified Program. The output from running a
160
+ covered work is covered by this License only if the output, given its
161
+ content, constitutes a covered work. This License acknowledges your
162
+ rights of fair use or other equivalent, as provided by copyright law.
163
+
164
+ You may make, run and propagate covered works that you do not
165
+ convey, without conditions so long as your license otherwise remains
166
+ in force. You may convey covered works to others for the sole purpose
167
+ of having them make modifications exclusively for you, or provide you
168
+ with facilities for running those works, provided that you comply with
169
+ the terms of this License in conveying all material for which you do
170
+ not control copyright. Those thus making or running the covered works
171
+ for you must do so exclusively on your behalf, under your direction
172
+ and control, on terms that prohibit them from making any copies of
173
+ your copyrighted material outside their relationship with you.
174
+
175
+ Conveying under any other circumstances is permitted solely under
176
+ the conditions stated below. Sublicensing is not allowed; section 10
177
+ makes it unnecessary.
178
+
179
+ 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
180
+
181
+ No covered work shall be deemed part of an effective technological
182
+ measure under any applicable law fulfilling obligations under article
183
+ 11 of the WIPO copyright treaty adopted on 20 December 1996, or
184
+ similar laws prohibiting or restricting circumvention of such
185
+ measures.
186
+
187
+ When you convey a covered work, you waive any legal power to forbid
188
+ circumvention of technological measures to the extent such circumvention
189
+ is effected by exercising rights under this License with respect to
190
+ the covered work, and you disclaim any intention to limit operation or
191
+ modification of the work as a means of enforcing, against the work's
192
+ users, your or third parties' legal rights to forbid circumvention of
193
+ technological measures.
194
+
195
+ 4. Conveying Verbatim Copies.
196
+
197
+ You may convey verbatim copies of the Program's source code as you
198
+ receive it, in any medium, provided that you conspicuously and
199
+ appropriately publish on each copy an appropriate copyright notice;
200
+ keep intact all notices stating that this License and any
201
+ non-permissive terms added in accord with section 7 apply to the code;
202
+ keep intact all notices of the absence of any warranty; and give all
203
+ recipients a copy of this License along with the Program.
204
+
205
+ You may charge any price or no price for each copy that you convey,
206
+ and you may offer support or warranty protection for a fee.
207
+
208
+ 5. Conveying Modified Source Versions.
209
+
210
+ You may convey a work based on the Program, or the modifications to
211
+ produce it from the Program, in the form of source code under the
212
+ terms of section 4, provided that you also meet all of these conditions:
213
+
214
+ a) The work must carry prominent notices stating that you modified
215
+ it, and giving a relevant date.
216
+
217
+ b) The work must carry prominent notices stating that it is
218
+ released under this License and any conditions added under section
219
+ 7. This requirement modifies the requirement in section 4 to
220
+ "keep intact all notices".
221
+
222
+ c) You must license the entire work, as a whole, under this
223
+ License to anyone who comes into possession of a copy. This
224
+ License will therefore apply, along with any applicable section 7
225
+ additional terms, to the whole of the work, and all its parts,
226
+ regardless of how they are packaged. This License gives no
227
+ permission to license the work in any other way, but it does not
228
+ invalidate such permission if you have separately received it.
229
+
230
+ d) If the work has interactive user interfaces, each must display
231
+ Appropriate Legal Notices; however, if the Program has interactive
232
+ interfaces that do not display Appropriate Legal Notices, your
233
+ work need not make them do so.
234
+
235
+ A compilation of a covered work with other separate and independent
236
+ works, which are not by their nature extensions of the covered work,
237
+ and which are not combined with it such as to form a larger program,
238
+ in or on a volume of a storage or distribution medium, is called an
239
+ "aggregate" if the compilation and its resulting copyright are not
240
+ used to limit the access or legal rights of the compilation's users
241
+ beyond what the individual works permit. Inclusion of a covered work
242
+ in an aggregate does not cause this License to apply to the other
243
+ parts of the aggregate.
244
+
245
+ 6. Conveying Non-Source Forms.
246
+
247
+ You may convey a covered work in object code form under the terms
248
+ of sections 4 and 5, provided that you also convey the
249
+ machine-readable Corresponding Source under the terms of this License,
250
+ in one of these ways:
251
+
252
+ a) Convey the object code in, or embodied in, a physical product
253
+ (including a physical distribution medium), accompanied by the
254
+ Corresponding Source fixed on a durable physical medium
255
+ customarily used for software interchange.
256
+
257
+ b) Convey the object code in, or embodied in, a physical product
258
+ (including a physical distribution medium), accompanied by a
259
+ written offer, valid for at least three years and valid for as
260
+ long as you offer spare parts or customer support for that product
261
+ model, to give anyone who possesses the object code either (1) a
262
+ copy of the Corresponding Source for all the software in the
263
+ product that is covered by this License, on a durable physical
264
+ medium customarily used for software interchange, for a price no
265
+ more than your reasonable cost of physically performing this
266
+ conveying of source, or (2) access to copy the
267
+ Corresponding Source from a network server at no charge.
268
+
269
+ c) Convey individual copies of the object code with a copy of the
270
+ written offer to provide the Corresponding Source. This
271
+ alternative is allowed only occasionally and noncommercially, and
272
+ only if you received the object code with such an offer, in accord
273
+ with subsection 6b.
274
+
275
+ d) Convey the object code by offering access from a designated
276
+ place (gratis or for a charge), and offer equivalent access to the
277
+ Corresponding Source in the same way through the same place at no
278
+ further charge. You need not require recipients to copy the
279
+ Corresponding Source along with the object code. If the place to
280
+ copy the object code is a network server, the Corresponding Source
281
+ may be on a different server (operated by you or a third party)
282
+ that supports equivalent copying facilities, provided you maintain
283
+ clear directions next to the object code saying where to find the
284
+ Corresponding Source. Regardless of what server hosts the
285
+ Corresponding Source, you remain obligated to ensure that it is
286
+ available for as long as needed to satisfy these requirements.
287
+
288
+ e) Convey the object code using peer-to-peer transmission, provided
289
+ you inform other peers where the object code and Corresponding
290
+ Source of the work are being offered to the general public at no
291
+ charge under subsection 6d.
292
+
293
+ A separable portion of the object code, whose source code is excluded
294
+ from the Corresponding Source as a System Library, need not be
295
+ included in conveying the object code work.
296
+
297
+ A "User Product" is either (1) a "consumer product", which means any
298
+ tangible personal property which is normally used for personal, family,
299
+ or household purposes, or (2) anything designed or sold for incorporation
300
+ into a dwelling. In determining whether a product is a consumer product,
301
+ doubtful cases shall be resolved in favor of coverage. For a particular
302
+ product received by a particular user, "normally used" refers to a
303
+ typical or common use of that class of product, regardless of the status
304
+ of the particular user or of the way in which the particular user
305
+ actually uses, or expects or is expected to use, the product. A product
306
+ is a consumer product regardless of whether the product has substantial
307
+ commercial, industrial or non-consumer uses, unless such uses represent
308
+ the only significant mode of use of the product.
309
+
310
+ "Installation Information" for a User Product means any methods,
311
+ procedures, authorization keys, or other information required to install
312
+ and execute modified versions of a covered work in that User Product from
313
+ a modified version of its Corresponding Source. The information must
314
+ suffice to ensure that the continued functioning of the modified object
315
+ code is in no case prevented or interfered with solely because
316
+ modification has been made.
317
+
318
+ If you convey an object code work under this section in, or with, or
319
+ specifically for use in, a User Product, and the conveying occurs as
320
+ part of a transaction in which the right of possession and use of the
321
+ User Product is transferred to the recipient in perpetuity or for a
322
+ fixed term (regardless of how the transaction is characterized), the
323
+ Corresponding Source conveyed under this section must be accompanied
324
+ by the Installation Information. But this requirement does not apply
325
+ if neither you nor any third party retains the ability to install
326
+ modified object code on the User Product (for example, the work has
327
+ been installed in ROM).
328
+
329
+ The requirement to provide Installation Information does not include a
330
+ requirement to continue to provide support service, warranty, or updates
331
+ for a work that has been modified or installed by the recipient, or for
332
+ the User Product in which it has been modified or installed. Access to a
333
+ network may be denied when the modification itself materially and
334
+ adversely affects the operation of the network or violates the rules and
335
+ protocols for communication across the network.
336
+
337
+ Corresponding Source conveyed, and Installation Information provided,
338
+ in accord with this section must be in a format that is publicly
339
+ documented (and with an implementation available to the public in
340
+ source code form), and must require no special password or key for
341
+ unpacking, reading or copying.
342
+
343
+ 7. Additional Terms.
344
+
345
+ "Additional permissions" are terms that supplement the terms of this
346
+ License by making exceptions from one or more of its conditions.
347
+ Additional permissions that are applicable to the entire Program shall
348
+ be treated as though they were included in this License, to the extent
349
+ that they are valid under applicable law. If additional permissions
350
+ apply only to part of the Program, that part may be used separately
351
+ under those permissions, but the entire Program remains governed by
352
+ this License without regard to the additional permissions.
353
+
354
+ When you convey a copy of a covered work, you may at your option
355
+ remove any additional permissions from that copy, or from any part of
356
+ it. (Additional permissions may be written to require their own
357
+ removal in certain cases when you modify the work.) You may place
358
+ additional permissions on material, added by you to a covered work,
359
+ for which you have or can give appropriate copyright permission.
360
+
361
+ Notwithstanding any other provision of this License, for material you
362
+ add to a covered work, you may (if authorized by the copyright holders of
363
+ that material) supplement the terms of this License with terms:
364
+
365
+ a) Disclaiming warranty or limiting liability differently from the
366
+ terms of sections 15 and 16 of this License; or
367
+
368
+ b) Requiring preservation of specified reasonable legal notices or
369
+ author attributions in that material or in the Appropriate Legal
370
+ Notices displayed by works containing it; or
371
+
372
+ c) Prohibiting misrepresentation of the origin of that material, or
373
+ requiring that modified versions of such material be marked in
374
+ reasonable ways as different from the original version; or
375
+
376
+ d) Limiting the use for publicity purposes of names of licensors or
377
+ authors of the material; or
378
+
379
+ e) Declining to grant rights under trademark law for use of some
380
+ trade names, trademarks, or service marks; or
381
+
382
+ f) Requiring indemnification of licensors and authors of that
383
+ material by anyone who conveys the material (or modified versions of
384
+ it) with contractual assumptions of liability to the recipient, for
385
+ any liability that these contractual assumptions directly impose on
386
+ those licensors and authors.
387
+
388
+ All other non-permissive additional terms are considered "further
389
+ restrictions" within the meaning of section 10. If the Program as you
390
+ received it, or any part of it, contains a notice stating that it is
391
+ governed by this License along with a term that is a further
392
+ restriction, you may remove that term. If a license document contains
393
+ a further restriction but permits relicensing or conveying under this
394
+ License, you may add to a covered work material governed by the terms
395
+ of that license document, provided that the further restriction does
396
+ not survive such relicensing or conveying.
397
+
398
+ If you add terms to a covered work in accord with this section, you
399
+ must place, in the relevant source files, a statement of the
400
+ additional terms that apply to those files, or a notice indicating
401
+ where to find the applicable terms.
402
+
403
+ Additional terms, permissive or non-permissive, may be stated in the
404
+ form of a separately written license, or stated as exceptions;
405
+ the above requirements apply either way.
406
+
407
+ 8. Termination.
408
+
409
+ You may not propagate or modify a covered work except as expressly
410
+ provided under this License. Any attempt otherwise to propagate or
411
+ modify it is void, and will automatically terminate your rights under
412
+ this License (including any patent licenses granted under the third
413
+ paragraph of section 11).
414
+
415
+ However, if you cease all violation of this License, then your
416
+ license from a particular copyright holder is reinstated (a)
417
+ provisionally, unless and until the copyright holder explicitly and
418
+ finally terminates your license, and (b) permanently, if the copyright
419
+ holder fails to notify you of the violation by some reasonable means
420
+ prior to 60 days after the cessation.
421
+
422
+ Moreover, your license from a particular copyright holder is
423
+ reinstated permanently if the copyright holder notifies you of the
424
+ violation by some reasonable means, this is the first time you have
425
+ received notice of violation of this License (for any work) from that
426
+ copyright holder, and you cure the violation prior to 30 days after
427
+ your receipt of the notice.
428
+
429
+ Termination of your rights under this section does not terminate the
430
+ licenses of parties who have received copies or rights from you under
431
+ this License. If your rights have been terminated and not permanently
432
+ reinstated, you do not qualify to receive new licenses for the same
433
+ material under section 10.
434
+
435
+ 9. Acceptance Not Required for Having Copies.
436
+
437
+ You are not required to accept this License in order to receive or
438
+ run a copy of the Program. Ancillary propagation of a covered work
439
+ occurring solely as a consequence of using peer-to-peer transmission
440
+ to receive a copy likewise does not require acceptance. However,
441
+ nothing other than this License grants you permission to propagate or
442
+ modify any covered work. These actions infringe copyright if you do
443
+ not accept this License. Therefore, by modifying or propagating a
444
+ covered work, you indicate your acceptance of this License to do so.
445
+
446
+ 10. Automatic Licensing of Downstream Recipients.
447
+
448
+ Each time you convey a covered work, the recipient automatically
449
+ receives a license from the original licensors, to run, modify and
450
+ propagate that work, subject to this License. You are not responsible
451
+ for enforcing compliance by third parties with this License.
452
+
453
+ An "entity transaction" is a transaction transferring control of an
454
+ organization, or substantially all assets of one, or subdividing an
455
+ organization, or merging organizations. If propagation of a covered
456
+ work results from an entity transaction, each party to that
457
+ transaction who receives a copy of the work also receives whatever
458
+ licenses to the work the party's predecessor in interest had or could
459
+ give under the previous paragraph, plus a right to possession of the
460
+ Corresponding Source of the work from the predecessor in interest, if
461
+ the predecessor has it or can get it with reasonable efforts.
462
+
463
+ You may not impose any further restrictions on the exercise of the
464
+ rights granted or affirmed under this License. For example, you may
465
+ not impose a license fee, royalty, or other charge for exercise of
466
+ rights granted under this License, and you may not initiate litigation
467
+ (including a cross-claim or counterclaim in a lawsuit) alleging that
468
+ any patent claim is infringed by making, using, selling, offering for
469
+ sale, or importing the Program or any portion of it.
470
+
471
+ 11. Patents.
472
+
473
+ A "contributor" is a copyright holder who authorizes use under this
474
+ License of the Program or a work on which the Program is based. The
475
+ work thus licensed is called the contributor's "contributor version".
476
+
477
+ A contributor's "essential patent claims" are all patent claims
478
+ owned or controlled by the contributor, whether already acquired or
479
+ hereafter acquired, that would be infringed by some manner, permitted
480
+ by this License, of making, using, or selling its contributor version,
481
+ but do not include claims that would be infringed only as a
482
+ consequence of further modification of the contributor version. For
483
+ purposes of this definition, "control" includes the right to grant
484
+ patent sublicenses in a manner consistent with the requirements of
485
+ this License.
486
+
487
+ Each contributor grants you a non-exclusive, worldwide, royalty-free
488
+ patent license under the contributor's essential patent claims, to
489
+ make, use, sell, offer for sale, import and otherwise run, modify and
490
+ propagate the contents of its contributor version.
491
+
492
+ In the following three paragraphs, a "patent license" is any express
493
+ agreement or commitment, however denominated, not to enforce a patent
494
+ (such as an express permission to practice a patent or covenant not to
495
+ sue for patent infringement). To "grant" such a patent license to a
496
+ party means to make such an agreement or commitment not to enforce a
497
+ patent against the party.
498
+
499
+ If you convey a covered work, knowingly relying on a patent license,
500
+ and the Corresponding Source of the work is not available for anyone
501
+ to copy, free of charge and under the terms of this License, through a
502
+ publicly available network server or other readily accessible means,
503
+ then you must either (1) cause the Corresponding Source to be so
504
+ available, or (2) arrange to deprive yourself of the benefit of the
505
+ patent license for this particular work, or (3) arrange, in a manner
506
+ consistent with the requirements of this License, to extend the patent
507
+ license to downstream recipients. "Knowingly relying" means you have
508
+ actual knowledge that, but for the patent license, your conveying the
509
+ covered work in a country, or your recipient's use of the covered work
510
+ in a country, would infringe one or more identifiable patents in that
511
+ country that you have reason to believe are valid.
512
+
513
+ If, pursuant to or in connection with a single transaction or
514
+ arrangement, you convey, or propagate by procuring conveyance of, a
515
+ covered work, and grant a patent license to some of the parties
516
+ receiving the covered work authorizing them to use, propagate, modify
517
+ or convey a specific copy of the covered work, then the patent license
518
+ you grant is automatically extended to all recipients of the covered
519
+ work and works based on it.
520
+
521
+ A patent license is "discriminatory" if it does not include within
522
+ the scope of its coverage, prohibits the exercise of, or is
523
+ conditioned on the non-exercise of one or more of the rights that are
524
+ specifically granted under this License. You may not convey a covered
525
+ work if you are a party to an arrangement with a third party that is
526
+ in the business of distributing software, under which you make payment
527
+ to the third party based on the extent of your activity of conveying
528
+ the work, and under which the third party grants, to any of the
529
+ parties who would receive the covered work from you, a discriminatory
530
+ patent license (a) in connection with copies of the covered work
531
+ conveyed by you (or copies made from those copies), or (b) primarily
532
+ for and in connection with specific products or compilations that
533
+ contain the covered work, unless you entered into that arrangement,
534
+ or that patent license was granted, prior to 28 March 2007.
535
+
536
+ Nothing in this License shall be construed as excluding or limiting
537
+ any implied license or other defenses to infringement that may
538
+ otherwise be available to you under applicable patent law.
539
+
540
+ 12. No Surrender of Others' Freedom.
541
+
542
+ If conditions are imposed on you (whether by court order, agreement or
543
+ otherwise) that contradict the conditions of this License, they do not
544
+ excuse you from the conditions of this License. If you cannot convey a
545
+ covered work so as to satisfy simultaneously your obligations under this
546
+ License and any other pertinent obligations, then as a consequence you may
547
+ not convey it at all. For example, if you agree to terms that obligate you
548
+ to collect a royalty for further conveying from those to whom you convey
549
+ the Program, the only way you could satisfy both those terms and this
550
+ License would be to refrain entirely from conveying the Program.
551
+
552
+ 13. Use with the GNU Affero General Public License.
553
+
554
+ Notwithstanding any other provision of this License, you have
555
+ permission to link or combine any covered work with a work licensed
556
+ under version 3 of the GNU Affero General Public License into a single
557
+ combined work, and to convey the resulting work. The terms of this
558
+ License will continue to apply to the part which is the covered work,
559
+ but the special requirements of the GNU Affero General Public License,
560
+ section 13, concerning interaction through a network will apply to the
561
+ combination as such.
562
+
563
+ 14. Revised Versions of this License.
564
+
565
+ The Free Software Foundation may publish revised and/or new versions of
566
+ the GNU General Public License from time to time. Such new versions will
567
+ be similar in spirit to the present version, but may differ in detail to
568
+ address new problems or concerns.
569
+
570
+ Each version is given a distinguishing version number. If the
571
+ Program specifies that a certain numbered version of the GNU General
572
+ Public License "or any later version" applies to it, you have the
573
+ option of following the terms and conditions either of that numbered
574
+ version or of any later version published by the Free Software
575
+ Foundation. If the Program does not specify a version number of the
576
+ GNU General Public License, you may choose any version ever published
577
+ by the Free Software Foundation.
578
+
579
+ If the Program specifies that a proxy can decide which future
580
+ versions of the GNU General Public License can be used, that proxy's
581
+ public statement of acceptance of a version permanently authorizes you
582
+ to choose that version for the Program.
583
+
584
+ Later license versions may give you additional or different
585
+ permissions. However, no additional obligations are imposed on any
586
+ author or copyright holder as a result of your choosing to follow a
587
+ later version.
588
+
589
+ 15. Disclaimer of Warranty.
590
+
591
+ THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
592
+ APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
593
+ HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
594
+ OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
595
+ THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
596
+ PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
597
+ IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
598
+ ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
599
+
600
+ 16. Limitation of Liability.
601
+
602
+ IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
603
+ WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
604
+ THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
605
+ GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
606
+ USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
607
+ DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
608
+ PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
609
+ EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
610
+ SUCH DAMAGES.
611
+
612
+ 17. Interpretation of Sections 15 and 16.
613
+
614
+ If the disclaimer of warranty and limitation of liability provided
615
+ above cannot be given local legal effect according to their terms,
616
+ reviewing courts shall apply local law that most closely approximates
617
+ an absolute waiver of all civil liability in connection with the
618
+ Program, unless a warranty or assumption of liability accompanies a
619
+ copy of the Program in return for a fee.
620
+
621
+ END OF TERMS AND CONDITIONS
622
+
623
+ How to Apply These Terms to Your New Programs
624
+
625
+ If you develop a new program, and you want it to be of the greatest
626
+ possible use to the public, the best way to achieve this is to make it
627
+ free software which everyone can redistribute and change under these terms.
628
+
629
+ To do so, attach the following notices to the program. It is safest
630
+ to attach them to the start of each source file to most effectively
631
+ state the exclusion of warranty; and each file should have at least
632
+ the "copyright" line and a pointer to where the full notice is found.
633
+
634
+ <one line to give the program's name and a brief idea of what it does.>
635
+ Copyright (C) <year> <name of author>
636
+
637
+ This program is free software: you can redistribute it and/or modify
638
+ it under the terms of the GNU General Public License as published by
639
+ the Free Software Foundation, either version 3 of the License, or
640
+ (at your option) any later version.
641
+
642
+ This program is distributed in the hope that it will be useful,
643
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
644
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
645
+ GNU General Public License for more details.
646
+
647
+ You should have received a copy of the GNU General Public License
648
+ along with this program. If not, see <https://www.gnu.org/licenses/>.
649
+
650
+ Also add information on how to contact you by electronic and paper mail.
651
+
652
+ If the program does terminal interaction, make it output a short
653
+ notice like this when it starts in an interactive mode:
654
+
655
+ <program> Copyright (C) <year> <name of author>
656
+ This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
657
+ This is free software, and you are welcome to redistribute it
658
+ under certain conditions; type `show c' for details.
659
+
660
+ The hypothetical commands `show w' and `show c' should show the appropriate
661
+ parts of the General Public License. Of course, your program's commands
662
+ might be different; for a GUI interface, you would use an "about box".
663
+
664
+ You should also get your employer (if you work as a programmer) or school,
665
+ if any, to sign a "copyright disclaimer" for the program, if necessary.
666
+ For more information on this, and how to apply and follow the GNU GPL, see
667
+ <https://www.gnu.org/licenses/>.
668
+
669
+ The GNU General Public License does not permit incorporating your program
670
+ into proprietary programs. If your program is a subroutine library, you
671
+ may consider it more useful to permit linking proprietary applications with
672
+ the library. If this is what you want to do, use the GNU Lesser General
673
+ Public License instead of this License. But first, please read
674
+ <https://www.gnu.org/licenses/why-not-lgpl.html>.
LanPaint/MANIFEST.in ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ include LICENSE
2
+ include README.md
3
+
4
+ recursive-exclude * __pycache__
5
+ recursive-exclude * *.py[co]
6
+
7
+ recursive-include docs *.rst conf.py Makefile make.bat *.jpg *.png *.gif
8
+
9
+ graft src/LanPaint/web
LanPaint/Nodes.JPG ADDED

Git LFS Details

  • SHA256: 5371453dbf997f4684a0712e19558c7c1592fc1c7cd57321aba00975689136cb
  • Pointer size: 131 Bytes
  • Size of remote file: 122 kB
LanPaint/README.md ADDED
@@ -0,0 +1,565 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div align="center">
2
+
3
+ # LanPaint: Universal Inpainting Sampler with "Think Mode"
4
+ [![TMLR PDF](https://img.shields.io/badge/TMLR-PDF-8A2BE2?logo=openreview&logoColor=white)](https://openreview.net/pdf?id=JPC8JyOUSW)
5
+ [![Python Benchmark](https://img.shields.io/badge/🐍-Python_Benchmark-3776AB?logo=python)](https://github.com/scraed/LanPaintBench)
6
+ [![ComfyUI Extension](https://img.shields.io/badge/ComfyUI-Extension-7B5DFF)](https://github.com/comfyanonymous/ComfyUI)
7
+ [![Hugging Face](https://img.shields.io/badge/Hugging%20Face-yellow?logo=huggingface&logoColor=white)](https://huggingface.co/charrywhite/LanPaint)
8
+ [![Blog](https://img.shields.io/badge/📝-Blog-9cf)](https://scraed.github.io/scraedBlog/)
9
+ [![GitHub stars](https://img.shields.io/github/stars/scraed/LanPaint)](https://github.com/scraed/LanPaint/stargazers)
10
+ [![Discord](https://img.shields.io/badge/Discord-5865F2?style=for-the-badge&logo=discord&logoColor=white)](https://discord.gg/yN5wYDE6W4)
11
+ </div>
12
+
13
+
14
+ Universally applicable inpainting ability for every model. LanPaint sampler lets the model "think" through multiple iterations before denoising, enabling you to invest more computation time for superior inpainting quality.
15
+
16
+ This is the official implementation of ["LanPaint: Training-Free Diffusion Inpainting with Asymptotically Exact and Fast Conditional Sampling"](https://arxiv.org/abs/2502.03491), accepted by TMLR.
17
+
18
+ The repository is for ComfyUI extension.
19
+
20
+ Diffusers Support: [LanPaint-Diffusers](https://github.com/charrywhite/LanPaint-diffusers) by [@charrywhite](https://github.com/charrywhite/)
21
+
22
+ Benchmark code for paper reproduce: [LanPaintBench](https://github.com/scraed/LanPaintBench).
23
+
24
+ ## Citation
25
+
26
+ ```
27
+ @article{
28
+ zheng2025lanpaint,
29
+ title={LanPaint: Training-Free Diffusion Inpainting with Asymptotically Exact and Fast Conditional Sampling},
30
+ author={Candi Zheng and Yuan Lan and Yang Wang},
31
+ journal={Transactions on Machine Learning Research},
32
+ issn={2835-8856},
33
+ year={2025},
34
+ url={https://openreview.net/forum?id=JPC8JyOUSW},
35
+ note={}
36
+ }
37
+ ```
38
+ **🎉 NEW 2026: Join our discord!**
39
+
40
+ [Join our Discord](https://discord.gg/yN5wYDE6W4) to share experiences, discuss features, and explore future development.
41
+
42
+ **🎬 NEW: LanPaint now supports inpainting and outpainting based on Z-Image!**
43
+
44
+ `v1.5.0` fixes an important hidden bug that reduced performance and could blur images (especially with `z-image-base`) and also boosts overall LanPaint performance across other models.
45
+
46
+ | Original | Masked | Inpainted |
47
+ |:--------:|:------:|:---------:|
48
+ | ![Original Z-image](https://github.com/scraed/LanPaint/blob/master/examples/Example_21/Original_No_Mask.png) | ![Masked Z-image](https://github.com/scraed/LanPaint/blob/master/examples/Example_21/Masked_Load_Me_in_Loader.png) | ![Inpainted Z-image](https://github.com/scraed/LanPaint/blob/master/examples/Example_21/InPainted_Drag_Me_to_ComfyUI.png) |
49
+
50
+ **🎬 NEW: LanPaint now supports Z-Image-Base too!**
51
+
52
+ | Original | Masked | Inpainted |
53
+ |:--------:|:------:|:---------:|
54
+ | ![Original Z-image-base](https://github.com/scraed/LanPaint/blob/master/examples/Example_25/Original_No_Mask.png) | ![Masked Z-image-base](https://github.com/scraed/LanPaint/blob/master/examples/Example_25/Masked_Load_Me_in_Loader.png) | ![Inpainted Z-image-base](https://github.com/scraed/LanPaint/blob/master/examples/Example_25/InPainted_Drag_Me_to_ComfyUI.png) |
55
+
56
+
57
+ **🎬 NEW: LanPaint now supports video inpainting and outpainting based on Wan 2.2!**
58
+
59
+ <div align="center">
60
+
61
+ | Original Video | Mask (edit T-shirt text) | Inpainted Result |
62
+ |:--------------:|:----:|:----------------:|
63
+ | ![Original](https://github.com/scraed/LanPaint/blob/master/examples/Original_No_Mask-example18.gif) | ![Mask](https://github.com/scraed/LanPaint/blob/master/examples/Example_18/Masked_Load_Me_in_Loader.png) | ![Result](https://github.com/scraed/LanPaint/blob/master/examples/Inpainted_81frames_Drag_Me_to_ComfyUI_example18.gif) |
64
+
65
+ *Video Inpainting Example: 81 frames with temporal consistency*
66
+
67
+ </div>
68
+
69
+ Check our latest [Wan 2.2 Video Examples](#video-examples-beta), [Wan 2.2 Image Examples](#example-wan22-inpaintlanpaint-k-sampler-5-steps-of-thinking), and
70
+ [Qwen Image Edit 2509](#example-qwen-edit-2509-inpaint) support.
71
+
72
+
73
+ ## Table of Contents
74
+ - [Features](#features)
75
+ - [Quickstart](#quickstart)
76
+ - [How to Use Examples](#how-to-use-examples)
77
+ - [Video Examples (Beta)](#video-examples-beta)
78
+ - [Wan 2.2 Video Inpainting](#wan-22-video-inpainting)
79
+ - [Wan 2.2 5B Video Inpainting](#wan-22-5b-video-inpainting)
80
+ - [Wan 2.2 Video Outpainting](#wan-22-video-outpainting)
81
+ - [Resource Consumption](#resource-consumption)
82
+ - [Image Examples](#image-examples)
83
+ - [Flux.2.Dev](#example-flux2dev-inpaintlanpaint-k-sampler-5-steps-of-thinking)
84
+ - [Flux 2 klein](#example-flux-2-klein-inpaintlanpaint-k-sampler-2-steps-of-thinking)
85
+ - [Z-image](#example-z-image-inpaintlanpaint-k-sampler-5-steps-of-thinking)
86
+ - [Z-image-base](#example-z-image-base-inpaintlanpaint-k-sampler-3-steps-of-thinking)
87
+ - [Hunyuan T2I](#example-hunyuan-t2i-inpaintlanpaint-k-sampler-5-steps-of-thinking)
88
+ - [Wan 2.2 T2I](#example-wan22-inpaintlanpaint-k-sampler-5-steps-of-thinking)
89
+ - [Wan 2.2 T2I with reference](#example-wan22-partial-inpaintlanpaint-k-sampler-5-steps-of-thinking)
90
+ - [Qwen Image Edit 2511 2509](#example-qwen-edit-2509-inpaint)
91
+ - [Qwen Image Edit 2508](#example-qwen-edit-2508-inpaint)
92
+ - [Qwen Image](#example-qwen-image-inpaintlanpaint-k-sampler-5-steps-of-thinking)
93
+ - [HiDream](#example-hidream-inpaint-lanpaint-k-sampler-5-steps-of-thinking)
94
+ - [SD 3.5](#example-sd-35-inpaintlanpaint-k-sampler-5-steps-of-thinking)
95
+ - [Flux](#example-flux-inpaintlanpaint-k-sampler-5-steps-of-thinking)
96
+ - [SDXL](#example-sdxl-0-character-consistency-side-view-generation-lanpaint-k-sampler-5-steps-of-thinking)
97
+ - [Usage](#usage)
98
+ - [Basic Sampler](#basic-sampler)
99
+ - [Advanced Sampler](#lanpaint-ksampler-advanced)
100
+ - [Tuning Guide](#lanpaint-ksampler-advanced-tuning-guide)
101
+ - [Community Showcase](#community-showcase-)
102
+ - [FAQ](#faq)
103
+ - [Updates](#updates)
104
+ - [ToDo](#todo)
105
+ - [Citation](#citation)
106
+
107
+ ## Features
108
+
109
+ - **Universal Compatibility** – Works instantly with almost any model (**Z-image, Z-image-base, Hunyuan, Wan 2.2, Qwen Image/Edit, HiDream, SD 3.5, Flux-series, SDXL, SD 1.5 or custom LoRAs**) and ControlNet.
110
+ ![Inpainting Result 13](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_13.jpg)
111
+ - **No Training Needed** – Works out of the box with your existing model.
112
+ - **Easy to Use** – Same workflow as standard ComfyUI KSampler.
113
+ - **Flexible Masking** – Supports any mask shape, size, or position for inpainting/outpainting.
114
+ - **No Workarounds** – Generates 100% new content (no blending or smoothing) without relying on partial denoising.
115
+ - **Beyond Inpainting** – You can even use it as a simple way to generate consistent characters.
116
+
117
+ **Warning**: LanPaint has degraded performance on distillation models, such as Flux.dev, due to a similar [issue with LORA training](https://medium.com/@zhiwangshi28/why-flux-lora-so-hard-to-train-and-how-to-overcome-it-a0c70bc59eaf). Please use low flux guidance (1.0-2.0) to mitigate this [issue](https://github.com/scraed/LanPaint/issues/30).
118
+
119
+ ## Quickstart
120
+
121
+ 1. **Install ComfyUI**: Follow the official [ComfyUI installation guide](https://docs.comfy.org/get_started) to set up ComfyUI on your system. Or ensure your ComfyUI version > 0.3.11.
122
+ 2. **Install ComfyUI-Manager**: Add the [ComfyUI-Manager](https://github.com/ltdrdata/ComfyUI-Manager) for easy extension management.
123
+ 3. **Install LanPaint Nodes**:
124
+ - **Via ComfyUI-Manager**: Search for "[LanPaint](https://registry.comfy.org/publishers/scraed/nodes/LanPaint)" in the manager and install it directly.
125
+ - **Manually**: Click "Install via Git URL" in ComfyUI-Manager and input the GitHub repository link:
126
+ ```
127
+ https://github.com/scraed/LanPaint.git
128
+ ```
129
+ Alternatively, clone this repository into the `ComfyUI/custom_nodes` folder.
130
+ 4. **Restart ComfyUI**: Restart ComfyUI to load the LanPaint nodes.
131
+
132
+ Once installed, you'll find the LanPaint nodes under the "sampling" category in ComfyUI. Use them just like the default KSampler for high-quality inpainting!
133
+
134
+
135
+ ## **How to Use Examples:**
136
+ 1. Navigate to the **example** folder (i.e example_1), download all pictures.
137
+ 2. Drag **InPainted_Drag_Me_to_ComfyUI.png** into ComfyUI to load the workflow.
138
+ 3. Download the required model (i.e clicking **Model Used in This Example**).
139
+ 4. Load the model in ComfyUI.
140
+ 5. Upload **Masked_Load_Me_in_Loader.png** to the **"Load image"** node in the **"Mask image for inpainting"** group (second from left), or the **Prepare Image** node.
141
+ 7. Queue the task, you will get inpainted results from LanPaint. Some example also gives you inpainted results from the following methods for comparison:
142
+ - **[VAE Encode for Inpainting](https://comfyanonymous.github.io/ComfyUI_examples/inpaint/)**
143
+ - **[Set Latent Noise Mask](https://comfyui-wiki.com/en/tutorial/basic/how-to-inpaint-an-image-in-comfyui)**
144
+
145
+ ## Video Examples (Beta)
146
+
147
+ LanPaint now supports video inpainting with Wan 2.2, enabling you to seamlessly inpaint masked regions across video frames while maintaining temporal consistency.
148
+
149
+ **Note:** LanPaint supports video inpainting for longer sequences (e.g., 81 frames), but processing time increases significantly (please check the [Resource Consumption](#resource-consumption) section for details) and performance may become unstable. For optimal results and stability, we recommend limiting video inpainting to **40 frames or fewer**.
150
+
151
+ ### Wan 2.2 Video Inpainting
152
+
153
+ *Example: Wan2.2 t2v 14B, 480p video (11:6), 40 frames, LanPaint K Sampler, 2 steps of thinking*
154
+
155
+ | Original Video | Mask (Add a white hat) | Inpainted Result |
156
+ |:--------------:|:----:|:----------------:|
157
+ | ![Original Video](https://github.com/scraed/LanPaint/blob/master/examples/Original_No_Mask_example17.gif) | ![Mask](https://github.com/scraed/LanPaint/blob/master/examples/Example_17/Masked_Load_Me_in_Loader.png) | ![Inpainted Result](https://github.com/scraed/LanPaint/blob/master/examples/Inpainted_40frames_Drag_Me_to_ComfyUI_example17.gif) |
158
+
159
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_17)
160
+
161
+ You need to follow the ComfyUI version of [Wan2.2 T2V workflow](https://docs.comfy.org/tutorials/video/wan/wan2_2) to download and install the T2V model.
162
+
163
+ ### Wan 2.2 5B Video Inpainting
164
+
165
+ Similar to Wan 2.2 14B with slightly different workflow. [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_17)
166
+
167
+ ### Wan 2.2 Video Outpainting
168
+
169
+ Extend your videos beyond their original boundaries with LanPaint's video outpainting capability based on Wan 2.2. This feature allows you to expand the canvas of your videos while maintaining coherent motion and context.
170
+
171
+ *Example: Wan2.2 t2v 14B, 480p video (1:1 outpaint to 11:6), 40 frames, LanPaint K Sampler, 2 steps of thinking*
172
+
173
+ | Original Video | Mask (Expand to 880x480) | Outpainted Result |
174
+ |:--------------:|:----:|:-----------------:|
175
+ | ![Original Video](https://github.com/scraed/LanPaint/blob/master/examples/Original_Load_Me_in_Loader_example19.gif) | ![Mask](https://github.com/scraed/LanPaint/blob/master/examples/Mask_Example19_.png) | ![Outpainted Result](https://github.com/scraed/LanPaint/blob/master/examples/Outpainted_40frames_Drag_Me_to_ComfyUI_example19.gif) |
176
+
177
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_19)
178
+
179
+ You need to follow the ComfyUI version of [Wan2.2 T2V workflow](https://docs.comfy.org/tutorials/video/wan/wan2_2) to download and install the T2V model.
180
+
181
+ ### Resource Consumption
182
+
183
+
184
+ <table>
185
+ <thead>
186
+ <tr>
187
+ <th align="left">Processing Mode</th>
188
+ <th align="left">Resolution</th>
189
+ <th align="left">Frames Processed</th>
190
+ <th align="left">VRAM Required</th>
191
+ <th align="left">Total Runtime (20 steps)</th>
192
+ </tr>
193
+ </thead>
194
+ <tbody>
195
+ <tr style="background-color: #e8f4f8;">
196
+ <td><strong>Inpainting</strong></td>
197
+ <td>880×480 (11:6)</td>
198
+ <td>40 frames</td>
199
+ <td>39.8 GB</td>
200
+ <td><strong>05:37 min</strong></td>
201
+ </tr>
202
+ <tr style="background-color: #e8f4f8;">
203
+ <td><strong>Inpainting</strong></td>
204
+ <td>480×480 (1:1)</td>
205
+ <td>40 frames</td>
206
+ <td>38.0 GB</td>
207
+ <td><strong>05:35 min</strong></td>
208
+ </tr>
209
+ <tr style="background-color: #e8f4f8;">
210
+ <td><strong>Outpainting</strong></td>
211
+ <td>880×480 (11:6)</td>
212
+ <td>40 frames</td>
213
+ <td>40.2 GB</td>
214
+ <td><strong>05:36 min</strong></td>
215
+ </tr>
216
+ <tr style="background-color: #fff4e6;">
217
+ <td><strong>Inpainting</strong></td>
218
+ <td>880×480 (11:6)</td>
219
+ <td>81 frames</td>
220
+ <td>43.3 GB</td>
221
+ <td><strong>16:23 min</strong></td>
222
+ </tr>
223
+ <tr style="background-color: #fff4e6;">
224
+ <td><strong>Inpainting</strong></td>
225
+ <td>480×480 (1:1)</td>
226
+ <td>81 frames</td>
227
+ <td>39.8 GB</td>
228
+ <td><strong>14:25 min</strong></td>
229
+ </tr>
230
+ <tr style="background-color: #fff4e6;">
231
+ <td><strong>Outpainting</strong></td>
232
+ <td>880×480 (11:6)</td>
233
+ <td>81 frames</td>
234
+ <td>42.6 GB</td>
235
+ <td><strong>13:46 min</strong></td>
236
+ </tr>
237
+ </tbody>
238
+ </table>
239
+
240
+ <sub>**Test Platform**: All tests were conducted on an NVIDIA RTX Pro 6000.<br>
241
+ **Model Used**: `wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors` and `wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors`.<br>
242
+ **Processing Steps**: 20 sampling steps x 2 (LanPaint steps of thinking).</sub>
243
+
244
+ **Note:** Vram is required by the model, not LanPaint. To further reduce VRAM requirements, we recommend generating less frames and loading CLIP on CPU.
245
+
246
+ ## Image Examples
247
+
248
+ ### Example Hunyuan T2I: InPaint(LanPaint K Sampler, 5 steps of thinking)
249
+ We are excited to announce that LanPaint now supports inpainting with Hunyuan text to image generation.
250
+
251
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_20)
252
+
253
+
254
+ You need to follow the ComfyUI version of [Hunyuan workflow](https://docs.comfy.org/tutorials/video/hunyuan-video#hunyuan-text-to-video-workflow) to download and install the model.
255
+
256
+ ### Example Wan2.2: InPaint(LanPaint K Sampler, 5 steps of thinking)
257
+ We are excited to announce that LanPaint now supports Wan2.2 text to image generation with Wan2.2 T2V model.
258
+
259
+ ![Inpainting Result 45](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_45.jpg)
260
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_15)
261
+
262
+
263
+ You need to follow the ComfyUI version of [Wan2.2 T2V workflow](https://docs.comfy.org/tutorials/video/wan/wan2_2) to download and install the T2V model.
264
+
265
+ ### Example Z-image: InPaint(LanPaint K Sampler, 5 steps of thinking)
266
+ LanPaint also supports inpainting with the Z-image text-to-image model.
267
+
268
+ <details open>
269
+ <summary>View Original / Masked / Inpainted Comparison</summary>
270
+
271
+ | Original | Masked | Inpainted |
272
+ |:--------:|:------:|:---------:|
273
+ | ![Original Z-image](https://github.com/scraed/LanPaint/blob/master/examples/Example_21/Original_No_Mask.png) | ![Masked Z-image](https://github.com/scraed/LanPaint/blob/master/examples/Example_21/Masked_Load_Me_in_Loader.png) | ![Inpainted Z-image](https://github.com/scraed/LanPaint/blob/master/examples/Example_21/InPainted_Drag_Me_to_ComfyUI.png) |
274
+
275
+ </details>
276
+
277
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_21)
278
+
279
+ <details open>
280
+ <summary>View Z-image Outpainting (Original / Masked / Outpainted)</summary>
281
+
282
+ | Original | Masked | Outpainted |
283
+ |:--------:|:------:|:----------:|
284
+ | ![Original Z-image Outpaint](https://github.com/scraed/LanPaint/blob/master/examples/Example_22/Original_No_Mask.png) | ![Masked Z-image Outpaint](https://github.com/scraed/LanPaint/blob/master/examples/Example_22/Masked_Load_Me_in_Loader.png) | ![Outpainted Z-image](https://github.com/scraed/LanPaint/blob/master/examples/Example_22/InPainted_Drag_Me_to_ComfyUI.png) |
285
+
286
+ </details>
287
+
288
+ [View Outpaint Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_22)
289
+
290
+ You can download the Z-image model for ComfyUI from [Z-image](https://docs.comfy.org/zh-CN/tutorials/image/z-image/z-image-turbo).
291
+
292
+ ### Example Z-image-base: InPaint(LanPaint K Sampler, 3 steps of thinking)
293
+ LanPaint also supports inpainting with the Z-image-base model.
294
+
295
+ **Warning (stability)**: Z-image-base can easily diverge with LanPaint. Start with **small `LanPaint_StepSize`** and **fewer thinking iterations** (lower `LanPaint_NumSteps`) and increase gradually only if stable.
296
+
297
+ <details open>
298
+ <summary>View Original / Masked / Inpainted Comparison</summary>
299
+
300
+ | Original | Masked | Inpainted |
301
+ |:--------:|:------:|:---------:|
302
+ | ![Original Z-image-base](https://github.com/scraed/LanPaint/blob/master/examples/Example_25/Original_No_Mask.png) | ![Masked Z-image-base](https://github.com/scraed/LanPaint/blob/master/examples/Example_25/Masked_Load_Me_in_Loader.png) | ![Inpainted Z-image-base](https://github.com/scraed/LanPaint/blob/master/examples/Example_25/InPainted_Drag_Me_to_ComfyUI.png) |
303
+
304
+ </details>
305
+
306
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_25)
307
+
308
+ Workflow template (JSON): [Z_image_base_Inpaint.json](https://github.com/scraed/LanPaint/blob/master/example_workflows/Z_image_base_Inpaint.json)
309
+
310
+ ### Example Wan2.2: Partial InPaint(LanPaint K Sampler, 5 steps of thinking)
311
+ Sometimes we don't want to inpaint completely new content, but rather let the inpainted image reference the original image. One option to achieve this is to inpaint with an edit model like Qwen Image Edit. Another option is to perform a partial inpaint: allowing the diffusion process to start at some middle steps rather than from 0.
312
+
313
+ ![Inpainting Result 46](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_46.jpg)
314
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_16)
315
+
316
+
317
+ You need to follow the ComfyUI version of [Wan2.2 T2V workflow](https://docs.comfy.org/tutorials/video/wan/wan2_2) to download and install the T2V model.
318
+
319
+
320
+ ### Example Qwen Edit 2509: InPaint
321
+ Check our latest updated [Mased Qwen Edit Workflow](https://github.com/scraed/LanPaint/tree/master/examples/Example_14) for Qwen Image Edit 2509. Download the model at [Qwen Image Edit 2509 Comfy](https://huggingface.co/Comfy-Org/Qwen-Image-Edit_ComfyUI/tree/main/split_files/diffusion_models). This workflow also supports Qwen Image Edit 2511.
322
+
323
+ ![Qwen Result 3](https://github.com/scraed/LanPaint/blob/master/examples/LanPaintQwen_04.jpg)
324
+
325
+ ### Example Qwen Edit 2508: InPaint
326
+ ![Qwen Result 2](https://github.com/scraed/LanPaint/blob/master/examples/LanPaintQwen_03.jpg)
327
+ Check [Mased Qwen Edit Workflow](https://github.com/scraed/LanPaint/tree/master/examples/Example_14). You need to follow the ComfyUI version of [Qwen Image Edit workflow](https://docs.comfy.org/tutorials/image/qwen/qwen-image-edit) to download and install the model.
328
+
329
+
330
+
331
+ ### Example Qwen Image: InPaint(LanPaint K Sampler, 5 steps of thinking)
332
+
333
+ ![Inpainting Result 14](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_14.jpg)
334
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_11)
335
+
336
+
337
+ You need to follow the ComfyUI version of [Qwen Image workflow](https://docs.comfy.org/tutorials/image/qwen/qwen-image) to download and install the model.
338
+
339
+ The following examples utilize a random seed of 0 to generate a batch of 4 images for variance demonstration and fair comparison. (Note: Generating 4 images may exceed your GPU memory; please adjust the batch size as necessary.)
340
+
341
+ ![Qwen Result 1](https://github.com/scraed/LanPaint/blob/master/examples/LanPaintQwen_01.jpg)
342
+ Also check [Qwen Inpaint Workflow](https://github.com/scraed/LanPaint/tree/master/examples/Example_13) and [Qwen Outpaint Workflow](https://github.com/scraed/LanPaint/tree/master/examples/Example_12). You need to follow the ComfyUI version of [Qwen Image workflow](https://docs.comfy.org/tutorials/image/qwen/qwen-image) to download and install the model.
343
+
344
+ ### Example HiDream: InPaint (LanPaint K Sampler, 5 steps of thinking)
345
+ ![Inpainting Result 8](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_11.jpg)
346
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_8)
347
+
348
+ You need to follow the ComfyUI version of [HiDream workflow](https://docs.comfy.org/tutorials/image/hidream/hidream-i1) to download and install the model.
349
+
350
+ ### Example HiDream: OutPaint(LanPaint K Sampler, 5 steps of thinking)
351
+ ![Inpainting Result 8](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_13(1).jpg)
352
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_10)
353
+
354
+ You need to follow the ComfyUI version of [HiDream workflow](https://docs.comfy.org/tutorials/image/hidream/hidream-i1) to download and install the model. Thanks [Amazon90](https://github.com/Amazon90) for providing this example.
355
+
356
+ ### Example SD 3.5: InPaint(LanPaint K Sampler, 5 steps of thinking)
357
+ ![Inpainting Result 8](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_12.jpg)
358
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_9)
359
+
360
+ You need to follow the ComfyUI version of [SD 3.5 workflow](https://comfyui-wiki.com/en/tutorial/advanced/stable-diffusion-3-5-comfyui-workflow) to download and install the model.
361
+
362
+ ### Example Flux.2.Dev: InPaint(LanPaint K Sampler, 5 steps of thinking)
363
+
364
+ <details open>
365
+ <summary>View Original / Masked / Inpainted Comparison</summary>
366
+
367
+ | Original | Masked | Inpainted |
368
+ |:--------:|:------:|:---------:|
369
+ | ![Original Flux.2.Dev](https://github.com/scraed/LanPaint/blob/master/examples/Example_23/Original_No_Mask.png) | ![Masked Flux.2.Dev](https://github.com/scraed/LanPaint/blob/master/examples/Example_23/Masked_Load_Me_in_Loader.png) | ![Inpainted Flux.2.Dev](https://github.com/scraed/LanPaint/blob/master/examples/Example_23/InPainted_Drag_Me_to_ComfyUI.png) |
370
+
371
+ </details>
372
+
373
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_23)
374
+
375
+ [Model Used in This Example](https://huggingface.co/Comfy-Org/flux2-dev)
376
+
377
+ (Note: Prompt First mode is disabled on Flux.2.Dev. As it does not use CFG guidance.)
378
+
379
+ ### Example Flux 2 klein: InPaint(LanPaint K Sampler, 2 steps of thinking)
380
+
381
+ <details open>
382
+ <summary>View Original / Masked / Inpainted Comparison</summary>
383
+
384
+ | Original | Masked | Inpainted |
385
+ |:--------:|:------:|:---------:|
386
+ | ![Original Flux 2 klein](https://github.com/scraed/LanPaint/blob/master/examples/Example_24/Original_No_Mask.png) | ![Masked Flux 2 klein](https://github.com/scraed/LanPaint/blob/master/examples/Example_24/Masked_Load_Me_in_Loader.png) | ![Inpainted Flux 2 klein](https://github.com/scraed/LanPaint/blob/master/examples/Example_24/InPainted_Drag_Me_to_ComfyUI.png) |
387
+
388
+ </details>
389
+
390
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_24)
391
+
392
+ [Model Used in This Example](https://docs.comfy.org/zh-CN/tutorials/flux/flux-2-klein). If you have quality problem on Comfy 0.11 and 0.12, check [this issue](https://github.com/scraed/LanPaint/issues/80).
393
+
394
+
395
+ ### Example Flux: InPaint(LanPaint K Sampler, 5 steps of thinking)
396
+ ![Inpainting Result 7](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_10.jpg)
397
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_7)
398
+ [Model Used in This Example](https://huggingface.co/Comfy-Org/flux1-dev/blob/main/flux1-dev-fp8.safetensors)
399
+ (Note: Prompt First mode is disabled on Flux. As it does not use CFG guidance.)
400
+
401
+ ### Example SDXL 0: Character Consistency (Side View Generation) (LanPaint K Sampler, 5 steps of thinking)
402
+ ![Inpainting Result 6](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_09.jpg)
403
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_6)
404
+ [Model Used in This Example](https://civitai.com/models/1188071?modelVersionId=1408658)
405
+
406
+ (Tricks 1: You can emphasize the character by copy it's image multiple times with Photoshop. Here I have made one extra copy.)
407
+
408
+ (Tricks 2: Use prompts like multiple views, multiple angles, clone, turnaround. Use LanPaint's Prompt first mode (does not support Flux))
409
+
410
+ (Tricks 3: Remeber LanPaint can in-paint: Mask non-consistent regions and try again!)
411
+
412
+
413
+ ### Example SDXL 1: Basket to Basket Ball (LanPaint K Sampler, 2 steps of thinking).
414
+ ![Inpainting Result 1](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_04.jpg)
415
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_1)
416
+ [Model Used in This Example](https://civitai.com/models/1188071?modelVersionId=1408658)
417
+ ### Example SDXL 2: White Shirt to Blue Shirt (LanPaint K Sampler, 5 steps of thinking)
418
+ ![Inpainting Result 2](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_05.jpg)
419
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_2)
420
+ [Model Used in This Example](https://civitai.com/models/1188071?modelVersionId=1408658)
421
+ ### Example SDXL 3: Smile to Sad (LanPaint K Sampler, 5 steps of thinking)
422
+ ![Inpainting Result 3](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_06.jpg)
423
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_3)
424
+ [Model Used in This Example](https://civitai.com/models/133005/juggernaut-xl)
425
+ ### Example SDXL 4: Damage Restoration (LanPaint K Sampler, 5 steps of thinking)
426
+ ![Inpainting Result 4](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_07.jpg)
427
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_4)
428
+ [Model Used in This Example](https://civitai.com/models/133005/juggernaut-xl)
429
+ ### Example SDXL 5: Huge Damage Restoration (LanPaint K Sampler, 20 steps of thinking)
430
+ ![Inpainting Result 5](https://github.com/scraed/LanPaint/blob/master/examples/InpaintChara_08.jpg)
431
+ [View Workflow & Masks](https://github.com/scraed/LanPaint/tree/master/examples/Example_5)
432
+ [Model Used in This Example](https://civitai.com/models/133005/juggernaut-xl)
433
+
434
+ Check more for use cases like inpaint on [fine tuned models](https://github.com/scraed/LanPaint/issues/12#issuecomment-2938662021) and [face swapping](https://github.com/scraed/LanPaint/issues/12#issuecomment-2938723501), thanks to [Amazon90](https://github.com/Amazon90).
435
+
436
+
437
+ ## Usage
438
+
439
+ **Workflow Setup**
440
+ Same as default ComfyUI KSampler - simply replace with LanPaint KSampler nodes. The inpainting workflow is the same as the [SetLatentNoiseMask](https://comfyui-wiki.com/zh/comfyui-nodes/latent/inpaint/set-latent-noise-mask) inpainting workflow.
441
+
442
+ **Note**
443
+ - LanPaint requires binary masks (values of 0 or 1) without opacity or smoothing. To ensure compatibility, set the mask's **opacity and hardness to maximum** in your mask editor. During inpainting, any mask with smoothing or gradients will automatically be converted to a binary mask.
444
+ - LanPaint relies heavily on your text prompts to guide inpainting - explicitly describe the content you want generated in the masked area. If results show artifacts or mismatched elements, counteract them with targeted negative prompts.
445
+
446
+ ## Basic Sampler
447
+ ![Samplers](https://github.com/scraed/LanPaint/blob/master/Nodes.JPG)
448
+
449
+ - LanPaint KSampler: The most basic and easy to use sampler for inpainting.
450
+ - LanPaint KSampler (Advanced): Full control of all parameters.
451
+
452
+ ### LanPaint KSampler
453
+ Simplified interface with recommended defaults:
454
+
455
+ - Steps: 20 - 50. More steps will give more "thinking" and better results.
456
+ - LanPaint NumSteps: The turns of thinking before denoising. Recommend 5 for most of tasks ( which means 5 times slower than sampling without thinking). Use 10 for more challenging tasks.
457
+ - LanPaint Prompt mode: Image First mode and Prompt First mode. Image First mode focuses on the image, inpaint based on image context (maybe ignore prompt), while Prompt First mode focuses more on the prompt. Use Prompt First mode for tasks like character consistency. (Technically, it Prompt First mode change CFG scale to negative value in the BIG score to emphasis prompt, which will costs image quality.)
458
+
459
+ ### LanPaint KSampler (Advanced)
460
+ Full parameter control:
461
+ **Key Parameters**
462
+
463
+ | Parameter | Range | Description |
464
+ |-----------|-------|-------------|
465
+ | `Steps` | 0-100 | Total steps of diffusion sampling. Higher means better inpainting. Recommend 20-50. |
466
+ | `LanPaint_NumSteps` | 0-20 | Reasoning iterations per denoising step ("thinking depth"). Easy task: 2-5. Hard task: 5-10 |
467
+ | `LanPaint_Lambda` | 0.1-50 | Content alignment strength (higher = stricter). Recommend 4.0 - 10.0 |
468
+ | `LanPaint_StepSize` | 0.1-1.0 | The StepSize of each thinking step. Recommend 0.1-0.5. |
469
+ | `LanPaint_Beta` | 0.1-2.0 | The StepSize ratio between masked / unmasked region. Small value can compensate high lambda values. Recommend 1.0 |
470
+ | `LanPaint_Friction` | 0.0-100.0 | The friction of Langevin dynamics. Higher means more slow but stable, lower means fast but unstable. Recommend 10.0 - 20.0|
471
+ | `LanPaint_EarlyStop` | 0-10 | Stop LanPaint iteration before the final sampling step. Helps to remove artifacts in some cases. Recommend 1-5|
472
+ | `LanPaint_PromptMode` | Image First / Prompt First | Image First mode focuses on the image context, maybe ignore prompt. Prompt First mode focuses more on the prompt. |
473
+
474
+ For detailed descriptions of each parameter, simply hover your mouse over the corresponding input field to view tooltips with additional information.
475
+
476
+ ### LanPaint Mask Blend
477
+ This node blends the original image with the inpainted image based on the mask. It is useful if you want the unmasked region to match the original image pixel perfectly.
478
+
479
+ ## LanPaint KSampler (Advanced) Tuning Guide
480
+ For challenging inpainting tasks:
481
+
482
+ 1️⃣ **Boost Quality**
483
+ Increase **total number of sampling steps** (very important!), **LanPaint_NumSteps** (thinking iterations) or **LanPaint_Lambda** if the inpainted result does not meet your expectations.
484
+
485
+ 2️⃣ **Boost Speed**
486
+ Decrease **LanPaint_NumSteps** to accelerate generation! If you want better results but still need fewer steps, consider:
487
+ - **Increasing LanPaint_StepSize** to speed up the thinking process.
488
+ - **Decreasing LanPaint_Friction** to make the Langevin dynamics converges more faster.
489
+
490
+ 3️⃣ **Fix Unstability**:
491
+ If you find the results have wired texture, try
492
+ - Reduce **LanPaint_Friction** to make the Langevin dynamics more stable.
493
+ - Reduce **LanPaint_StepSize** to use smaller step size.
494
+ - Reduce **LanPaint_Beta** if you are using a high lambda value.
495
+
496
+ ⚠️ **Notes**:
497
+ - For effective tuning, **fix the seed** and adjust parameters incrementally while observing the results. This helps isolate the impact of each setting. Better to do it with a batche of images to avoid overfitting on a single image.
498
+
499
+ ## Community Showcase [](#community-showcase-)
500
+
501
+ Discover how the community is using LanPaint! Here are some user-created tutorials:
502
+
503
+ - [Ai绘画进阶148-三大王炸!庆祝高允贞出道6周年!T8即将直播?当AI绘画学会深度思考?!万能修复神器LanPaint,万物皆可修!-T8 Comfyui教程](https://www.youtube.com/watch?v=Z4DSTv3UPJo)
504
+ - [Ai绘画进阶151-真相了!T8竟是个AI?!LanPaint进阶(二),人物一致性,多视角实验性测试,新参数讲解,工作流分享-T8 Comfyui教程](https://www.youtube.com/watch?v=landiRhvF3k)
505
+ - [重绘和三视图角色一致性解决新方案!LanPaint节点尝试](https://www.youtube.com/watch?v=X0WbXdm6FA0)
506
+ - [ComfyUI: HiDream with Perturbation Upscale, LanPaint Inpainting (Workflow Tutorial)](https://www.youtube.com/watch?v=2-mGe4QVIIw&t=2785s)
507
+ - [ComfyUI必备LanPaint插件超详细使用教程](https://plugin.aix.ink/archives/lanpaint)
508
+
509
+ Submit a PR to add your tutorial/video here, or open an [Issue](https://github.com/scraed/LanPaint/issues) with details!
510
+
511
+ ## FAQ
512
+ [Working togather with crop&stitch](https://github.com/scraed/LanPaint/issues/46)
513
+
514
+ ## Updates
515
+ - 2026/03/02
516
+ - `v1.5.0`: Fixed a hidden bug that hurt performance and caused image blur (especially on `z-image-base`), and improved overall LanPaint performance on other models too.
517
+ - 2026/01/30
518
+ - Add Z-image-base documentation and Example_25 workflow images.
519
+ - 2025/08/08
520
+ - Add Qwen image support
521
+ - 2025/06/21
522
+ - Update the algorithm with enhanced stability and outpaint performance.
523
+ - Add outpaint example
524
+ - Supports Sampler Custom (Thanks to [MINENEMA](https://github.com/MINENEMA))
525
+ - 2025/06/04
526
+ - Add more sampler support.
527
+ - Add early stopping to advanced sampler.
528
+ - 2025/05/28
529
+ - Major update on the Langevin solver. It is now much faster and more stable.
530
+ - Greatly simplified the parameters for advanced sampler.
531
+ - Fix performance issue on Flux and SD 3.5
532
+ - 2025/04/16
533
+ - Added Primary HiDream support
534
+ - 2025/03/22
535
+ - Added Primary Flux support
536
+ - Added Tease Mode
537
+ - 2025/03/10
538
+ - LanPaint has received a major update! All examples now use the LanPaint K Sampler, offering a simplified interface with enhanced performance and stability.
539
+ - 2025/03/06:
540
+ - Bug Fix for str not callable error and unpack error. Big thanks to [jamesWalker55](https://github.com/jamesWalker55) and [EricBCoding](https://github.com/EricBCoding).
541
+
542
+ ## ToDo
543
+ - Try Implement Detailer
544
+ - ~~Provide inference code on without GUI.~~ Check our local Python benchmark code [LanPaintBench](https://github.com/scraed/LanPaintBench).
545
+
546
+
547
+ ## Citation
548
+
549
+ ```
550
+ @article{
551
+ zheng2025lanpaint,
552
+ title={LanPaint: Training-Free Diffusion Inpainting with Asymptotically Exact and Fast Conditional Sampling},
553
+ author={Candi Zheng and Yuan Lan and Yang Wang},
554
+ journal={Transactions on Machine Learning Research},
555
+ issn={2835-8856},
556
+ year={2025},
557
+ url={https://openreview.net/forum?id=JPC8JyOUSW},
558
+ note={}
559
+ }
560
+ ```
561
+
562
+
563
+
564
+
565
+
LanPaint/__init__.py ADDED
@@ -0,0 +1,94 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """Top-level package for LanPaint."""
2
+
3
+ __all__ = [
4
+ "NODE_CLASS_MAPPINGS",
5
+ "NODE_DISPLAY_NAME_MAPPINGS",
6
+ "WEB_DIRECTORY",
7
+ ]
8
+
9
+ __author__ = """LanPaint"""
10
+ __email__ = "czhengac@connect.ust.hk"
11
+ __version__ = "0.0.1"
12
+
13
+
14
+ def _install_lightweight_runtime_stubs() -> None:
15
+ """Install lightweight stubs so tooling can import this package without ComfyUI.
16
+
17
+ This is used by CI tooling (e.g., comfy-org/node-diff) that imports NODE_CLASS_MAPPINGS
18
+ in an environment where ComfyUI isn't installed.
19
+ """
20
+ import sys
21
+ import types
22
+
23
+ # `src/LanPaint/nodes.py` uses `torch.Tensor` in type annotations.
24
+ try:
25
+ import torch # noqa: F401
26
+ except ModuleNotFoundError:
27
+ torch_mod = types.ModuleType("torch")
28
+
29
+ class Tensor: # noqa: N801 (match torch naming)
30
+ pass
31
+
32
+ torch_mod.Tensor = Tensor
33
+ torch_mod.nn = types.SimpleNamespace(functional=types.SimpleNamespace())
34
+ sys.modules["torch"] = torch_mod
35
+
36
+ if "comfyui_version" not in sys.modules:
37
+ comfyui_version_mod = types.ModuleType("comfyui_version")
38
+ comfyui_version_mod.__version__ = "0.0.0"
39
+ sys.modules["comfyui_version"] = comfyui_version_mod
40
+
41
+ sys.modules.setdefault("nodes", types.ModuleType("nodes"))
42
+ sys.modules.setdefault("latent_preview", types.ModuleType("latent_preview"))
43
+
44
+ if "comfy" not in sys.modules:
45
+ comfy_mod = types.ModuleType("comfy")
46
+ comfy_mod.__path__ = []
47
+
48
+ comfy_utils_mod = types.ModuleType("comfy.utils")
49
+
50
+ def repeat_to_batch_size(tensor, batch_size): # type: ignore[no-untyped-def]
51
+ if getattr(tensor, "shape", ())[0] == batch_size:
52
+ return tensor
53
+ return tensor
54
+
55
+ comfy_utils_mod.repeat_to_batch_size = repeat_to_batch_size
56
+
57
+ comfy_samplers_mod = types.ModuleType("comfy.samplers")
58
+
59
+ class DummyKSAMPLER: # noqa: N801 (match ComfyUI naming)
60
+ pass
61
+
62
+ comfy_samplers_mod.KSAMPLER = DummyKSAMPLER
63
+
64
+ comfy_model_base_mod = types.ModuleType("comfy.model_base")
65
+
66
+ class ModelType: # noqa: N801 (match ComfyUI naming)
67
+ FLUX = "FLUX"
68
+ FLOW = "FLOW"
69
+
70
+ class WAN22: # noqa: N801 (match ComfyUI naming)
71
+ pass
72
+
73
+ comfy_model_base_mod.ModelType = ModelType
74
+ comfy_model_base_mod.WAN22 = WAN22
75
+
76
+ comfy_mod.utils = comfy_utils_mod
77
+ comfy_mod.samplers = comfy_samplers_mod
78
+ comfy_mod.model_base = comfy_model_base_mod
79
+
80
+ sys.modules["comfy"] = comfy_mod
81
+ sys.modules["comfy.utils"] = comfy_utils_mod
82
+ sys.modules["comfy.samplers"] = comfy_samplers_mod
83
+ sys.modules["comfy.model_base"] = comfy_model_base_mod
84
+
85
+
86
+ try:
87
+ from .src.LanPaint.nodes import NODE_CLASS_MAPPINGS
88
+ from .src.LanPaint.nodes import NODE_DISPLAY_NAME_MAPPINGS
89
+ except ModuleNotFoundError:
90
+ _install_lightweight_runtime_stubs()
91
+ from .src.LanPaint.nodes import NODE_CLASS_MAPPINGS
92
+ from .src.LanPaint.nodes import NODE_DISPLAY_NAME_MAPPINGS
93
+
94
+ WEB_DIRECTORY = "./web"
LanPaint/__pycache__/__init__.cpython-312.pyc ADDED
Binary file (3.88 kB). View file
 
LanPaint/build/lib/LanPaint/__init__.py ADDED
File without changes
LanPaint/build/lib/LanPaint/earlystop.py ADDED
@@ -0,0 +1,337 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Early Stop Logic Contributed by `https://github.com/godnight10061`.
3
+ """
4
+
5
+ import inspect
6
+ from typing import Any, Callable, Optional
7
+
8
+ import torch
9
+
10
+ from .types import LangevinState
11
+
12
+
13
+ def _clamp01(val: float) -> float:
14
+ if val <= 0.0:
15
+ return 0.0
16
+ if val >= 1.0:
17
+ return 1.0
18
+ return val
19
+
20
+
21
+ def _abt_scale(abt_val: float) -> float:
22
+ """
23
+ Smooth, parameter-free scale based on outer-step noise level.
24
+
25
+ - 0 at abt=0/1 (disable at extreme noise / extreme tail)
26
+ - 1 at abt=0.5 (mid-schedule)
27
+ """
28
+ abt_val = _clamp01(abt_val)
29
+ return _clamp01(4.0 * abt_val * (1.0 - abt_val))
30
+
31
+
32
+ def _boundary_weight(latent_mask: torch.Tensor, inpaint_weight: torch.Tensor) -> Optional[torch.Tensor]:
33
+ """
34
+ Return a 4-neighbor boundary weight: unknown pixels adjacent to known pixels.
35
+
36
+ This replaces the previous dilation-based "ring" (kernel/padding) and has no tunable hyperparameters.
37
+ """
38
+ if latent_mask.dim() != 4:
39
+ return None
40
+
41
+ known = latent_mask > 0.5
42
+ neighbor_known = torch.zeros_like(known)
43
+ neighbor_known[:, :, 1:, :] |= known[:, :, :-1, :]
44
+ neighbor_known[:, :, :-1, :] |= known[:, :, 1:, :]
45
+ neighbor_known[:, :, :, 1:] |= known[:, :, :, :-1]
46
+ neighbor_known[:, :, :, :-1] |= known[:, :, :, 1:]
47
+
48
+ boundary = (~known) & neighbor_known
49
+ return boundary.to(dtype=torch.float32) * inpaint_weight
50
+
51
+
52
+ def _weighted_mse(t1: torch.Tensor, t2: torch.Tensor, weight: torch.Tensor) -> float:
53
+ diff_sq = (t1.to(dtype=torch.float32) - t2.to(dtype=torch.float32)) ** 2
54
+ denom = torch.sum(weight) + 1e-12
55
+ return float((torch.sum(diff_sq * weight) / denom).item())
56
+
57
+
58
+ class LanPaintEarlyStopper:
59
+ """
60
+ Per-step early-stop logic for LanPaint inner (Langevin) iterations.
61
+ """
62
+
63
+ @classmethod
64
+ def from_options(
65
+ cls,
66
+ *,
67
+ model_options: Optional[dict],
68
+ latent_mask: torch.Tensor,
69
+ abt: torch.Tensor,
70
+ default_threshold: float,
71
+ default_patience: int,
72
+ default_distance_fn: Optional[Callable[..., Any]],
73
+ ) -> Optional["LanPaintEarlyStopper"]:
74
+ semantic_stop = model_options.get("lanpaint_semantic_stop") if isinstance(model_options, dict) else None
75
+
76
+ threshold = float(default_threshold)
77
+ patience = int(default_patience)
78
+ distance_fn = default_distance_fn
79
+ # distance_fn contract: return None (use default metric) or a scalar (Python number / 0-d (1-element) torch.Tensor)
80
+
81
+ if isinstance(semantic_stop, dict):
82
+ threshold = float(semantic_stop.get("threshold", threshold))
83
+ patience = int(semantic_stop.get("patience", patience))
84
+ distance_fn = semantic_stop.get("distance_fn", distance_fn)
85
+
86
+ # Backward compatibility: map legacy 'min_steps' to a patience floor so it is not an independent knob.
87
+ if patience > 0:
88
+ min_steps = semantic_stop.get("min_steps")
89
+ if min_steps is not None:
90
+ try:
91
+ min_steps_int = int(min_steps)
92
+ except (TypeError, ValueError):
93
+ min_steps_int = 0
94
+ if min_steps_int > 1:
95
+ patience = max(patience, min_steps_int - 1)
96
+
97
+ enabled_early_stop = (threshold > 0.0) and (patience > 0)
98
+ # Require N+1 consecutive stable checks:
99
+ # - the first stable step sets patience_counter to 1
100
+ # - `patience=1` therefore stops after 2 stable steps
101
+ patience_eff = max(1, patience) + 1
102
+ threshold_eff = threshold
103
+ inpaint_weight = ring_weight = trace = abt_val = None
104
+
105
+ if enabled_early_stop:
106
+ try:
107
+ abt_val = float(torch.mean(abt).item())
108
+ except (TypeError, ValueError):
109
+ abt_val = 0.0
110
+
111
+ threshold_eff = threshold * _abt_scale(abt_val)
112
+ if threshold_eff <= 0.0:
113
+ enabled_early_stop = False
114
+ else:
115
+ inpaint_weight = (1 - latent_mask).to(dtype=torch.float32)
116
+ if float(torch.sum(inpaint_weight).item()) < 1e-6:
117
+ enabled_early_stop = False
118
+ else:
119
+ ring_weight = _boundary_weight(latent_mask, inpaint_weight)
120
+ if isinstance(model_options, dict):
121
+ trace = model_options.get("lanpaint_semantic_trace")
122
+
123
+ if not enabled_early_stop:
124
+ return None
125
+
126
+ # Pre-fetch trace keys to avoid repeated dict lookups
127
+ bench_case_id = bench_outer_step = bench_timestep = None
128
+ if isinstance(trace, list) and isinstance(model_options, dict):
129
+ bench_case_id = model_options.get("bench_case_id")
130
+ bench_outer_step = model_options.get("bench_outer_step")
131
+ bench_timestep = model_options.get("bench_timestep")
132
+
133
+ return cls(
134
+ enabled=enabled_early_stop,
135
+ threshold=threshold,
136
+ threshold_eff=threshold_eff,
137
+ patience_eff=patience_eff,
138
+ inpaint_weight=inpaint_weight,
139
+ ring_weight=ring_weight,
140
+ distance_fn=distance_fn,
141
+ trace=trace,
142
+ bench_case_id=bench_case_id,
143
+ bench_outer_step=bench_outer_step,
144
+ bench_timestep=bench_timestep,
145
+ abt_val=abt_val,
146
+ )
147
+
148
+ def __init__(
149
+ self,
150
+ *,
151
+ enabled: bool,
152
+ threshold: float,
153
+ threshold_eff: float,
154
+ patience_eff: int,
155
+ inpaint_weight: Optional[torch.Tensor],
156
+ ring_weight: Optional[torch.Tensor],
157
+ distance_fn: Optional[Callable[..., Any]] = None,
158
+ trace: Optional[list] = None,
159
+ bench_case_id: Any = None,
160
+ bench_outer_step: Any = None,
161
+ bench_timestep: Any = None,
162
+ abt_val: Optional[float] = None,
163
+ ) -> None:
164
+ self.enabled = bool(enabled)
165
+ self.threshold = float(threshold)
166
+ self.threshold_eff = float(threshold_eff)
167
+ self.patience_eff = int(patience_eff)
168
+
169
+ self.inpaint_weight = inpaint_weight
170
+ self.ring_weight = ring_weight
171
+
172
+ self.trace = trace
173
+ self.bench_case_id = bench_case_id
174
+ self.bench_outer_step = bench_outer_step
175
+ self.bench_timestep = bench_timestep
176
+ self.abt_val = abt_val
177
+
178
+ self.patience_counter = 0
179
+ self.x0_anchor = None
180
+
181
+ self._dist_wrapper = self._wrap_distance_fn(distance_fn) if self.enabled else None
182
+
183
+ @property
184
+ def has_custom_distance_fn(self) -> bool:
185
+ return self._dist_wrapper is not None
186
+
187
+ @staticmethod
188
+ def _wrap_distance_fn(distance_fn: Optional[Callable[..., Any]]):
189
+ """
190
+ Wrap a user-provided `distance_fn` into a normalized callable: fn(prev, cur, ctx) -> dist|None.
191
+
192
+ Supported signatures:
193
+ - 3+ positional (or *args): `distance_fn(prev, cur, ctx)`
194
+ - explicit / **kwargs ctx: `distance_fn(prev, cur, ctx=ctx)`
195
+ - default 2-arg: `distance_fn(cur, prev)`
196
+
197
+ Return contract: None (use default metric) or a scalar (Python number / 0-d (1-element) torch.Tensor).
198
+ """
199
+ if not callable(distance_fn):
200
+ return None
201
+
202
+ try:
203
+ sig = inspect.signature(distance_fn)
204
+ params = list(sig.parameters.values())
205
+
206
+ has_ctx_param = "ctx" in sig.parameters
207
+ has_var_kw = any(p.kind == inspect.Parameter.VAR_KEYWORD for p in params)
208
+ has_var_pos = any(p.kind == inspect.Parameter.VAR_POSITIONAL for p in params)
209
+
210
+ pos_params = [
211
+ p
212
+ for p in params
213
+ if p.kind in (inspect.Parameter.POSITIONAL_ONLY, inspect.Parameter.POSITIONAL_OR_KEYWORD)
214
+ ]
215
+
216
+ if len(pos_params) >= 3 or has_var_pos:
217
+ # 3-arg positional: fn(prev, cur, ctx)
218
+ return lambda p, c, ctx: distance_fn(p, c, ctx)
219
+ if has_ctx_param or has_var_kw:
220
+ # keyword ctx: fn(prev, cur, ctx=ctx)
221
+ return lambda p, c, ctx: distance_fn(p, c, ctx=ctx)
222
+
223
+ # Default 2-arg: fn(cur, prev)
224
+ return lambda p, c, ctx: distance_fn(c, p)
225
+ except (ValueError, TypeError):
226
+ # Fallback for built-ins or complex callables.
227
+ def fallback_wrapper(p, c, ctx):
228
+ try:
229
+ return distance_fn(p, c, ctx)
230
+ except TypeError as e:
231
+ tb = e.__traceback__
232
+ if tb is not None and tb.tb_frame.f_code is not fallback_wrapper.__code__:
233
+ raise
234
+ return distance_fn(c, p)
235
+
236
+ return fallback_wrapper
237
+
238
+ def step(
239
+ self,
240
+ *,
241
+ i: int,
242
+ n_steps: int,
243
+ x_t_before: torch.Tensor,
244
+ x_t_after: torch.Tensor,
245
+ x_t_prev_for_custom: Optional[torch.Tensor],
246
+ prev_args: Any,
247
+ args: Any,
248
+ ctx: dict,
249
+ ) -> bool:
250
+ if not self.enabled:
251
+ return False
252
+
253
+ # 'inpaint_weight' is guaranteed to be set when enabled is True in the caller.
254
+ inpaint = self.inpaint_weight
255
+ if inpaint is None:
256
+ return False
257
+
258
+ dist = None
259
+ custom_dist = False
260
+ dist_inpaint = dist_ring = dist_drift = x0_prev = x0_cur = None
261
+
262
+ if self._dist_wrapper is not None:
263
+ dist = self._dist_wrapper(x_t_prev_for_custom, x_t_after, ctx)
264
+ if dist is not None:
265
+ if isinstance(dist, torch.Tensor):
266
+ if dist.numel() != 1:
267
+ raise TypeError("distance_fn must return None or a scalar / 0-d (1-element) tensor")
268
+ dist = float(dist.item())
269
+ else:
270
+ dist = float(dist)
271
+ custom_dist = dist is not None
272
+
273
+ if dist is None:
274
+ def _get_x0(arg: Any) -> Optional[torch.Tensor]:
275
+ if isinstance(arg, LangevinState):
276
+ return arg.x0
277
+ if isinstance(arg, tuple) and len(arg) >= 3:
278
+ return arg[2]
279
+ return None
280
+
281
+ x0_prev = _get_x0(prev_args)
282
+ x0_cur = _get_x0(args)
283
+
284
+ if x0_prev is not None and x0_cur is not None:
285
+ dist_inpaint = _weighted_mse(x0_cur, x0_prev, inpaint)
286
+ dist_ring = _weighted_mse(x0_cur, x0_prev, self.ring_weight) if self.ring_weight is not None else None
287
+ dist = dist_inpaint if dist_ring is None else max(dist_inpaint, dist_ring)
288
+ else:
289
+ dist_inpaint = _weighted_mse(x_t_after, x_t_before, inpaint)
290
+ dist = dist_inpaint
291
+
292
+ threshold_used = self.threshold if custom_dist else self.threshold_eff
293
+
294
+ # Drift guard (only for default metric with x0_cur).
295
+ if x0_cur is not None and not custom_dist:
296
+ if dist <= threshold_used:
297
+ if self.x0_anchor is None:
298
+ self.x0_anchor = x0_cur.detach()
299
+ else:
300
+ drift_inpaint = _weighted_mse(x0_cur, self.x0_anchor, inpaint)
301
+ drift_ring = _weighted_mse(x0_cur, self.x0_anchor, self.ring_weight) if self.ring_weight is not None else None
302
+ dist_drift = drift_inpaint if drift_ring is None else max(drift_inpaint, drift_ring)
303
+ dist = max(dist, dist_drift)
304
+ else:
305
+ self.x0_anchor = None
306
+
307
+ if dist <= threshold_used:
308
+ self.patience_counter += 1
309
+ else:
310
+ self.patience_counter = 0
311
+ self.x0_anchor = None
312
+
313
+ should_stop = self.patience_counter >= self.patience_eff
314
+
315
+ if isinstance(self.trace, list):
316
+ self.trace.append(
317
+ {
318
+ "case_id": self.bench_case_id,
319
+ "outer_step": self.bench_outer_step,
320
+ "bench_timestep": self.bench_timestep,
321
+ "inner_step": i + 1,
322
+ "dist": dist,
323
+ "dist_inpaint": None if dist_inpaint is None else float(dist_inpaint),
324
+ "dist_ring": None if dist_ring is None else float(dist_ring),
325
+ "dist_drift": None if dist_drift is None else float(dist_drift),
326
+ "threshold": float(threshold_used),
327
+ "threshold_eff": float(self.threshold_eff),
328
+ "patience_counter": int(self.patience_counter),
329
+ "patience_eff": int(self.patience_eff),
330
+ "abt": None if self.abt_val is None else float(self.abt_val),
331
+ "custom_dist": bool(custom_dist),
332
+ "stopped": bool(should_stop),
333
+ }
334
+ )
335
+
336
+ return bool(should_stop)
337
+
LanPaint/build/lib/LanPaint/lanpaint.py ADDED
@@ -0,0 +1,272 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import torch
2
+ from .utils import StochasticHarmonicOscillator
3
+ from functools import partial
4
+ from .earlystop import LanPaintEarlyStopper
5
+ from .types import LangevinState
6
+
7
+ class LanPaint():
8
+ def __init__(self, Model, NSteps, Friction, Lambda, Beta, StepSize, IS_FLUX = False, IS_FLOW = False, EarlyStopThreshold = 0.0, EarlyStopPatience = 1, EarlyStopHook = None):
9
+ self.n_steps = NSteps
10
+ self.chara_lamb = Lambda
11
+ self.IS_FLUX = IS_FLUX
12
+ self.IS_FLOW = IS_FLOW
13
+ self.step_size = StepSize
14
+ self.inner_model = Model
15
+ self.friction = Friction
16
+ self.chara_beta = Beta
17
+ self.img_dim_size = None
18
+ self.early_stop_threshold = EarlyStopThreshold
19
+ self.early_stop_patience = EarlyStopPatience
20
+ self.early_stop_hook = EarlyStopHook
21
+
22
+ def add_none_dims(self, array):
23
+ # Create a tuple with ':' for the first dimension and 'None' repeated num_nones times
24
+ index = (slice(None),) + (None,) * (self.img_dim_size-1)
25
+ return array[index]
26
+ def remove_none_dims(self, array):
27
+ # Create a tuple with ':' for the first dimension and 'None' repeated num_nones times
28
+ index = (slice(None),) + (0,) * (self.img_dim_size-1)
29
+ return array[index]
30
+ def __call__(self, x, latent_image, noise, sigma, latent_mask, current_times, model_options, seed, n_steps=None):
31
+ self.img_dim_size = len(x.shape)
32
+ self.latent_image = latent_image
33
+ self.noise = noise
34
+ if torch.mean(torch.abs(self.noise)) < 1e-8:
35
+ self.noise = torch.randn_like(self.noise)
36
+ if n_steps is None:
37
+ n_steps = self.n_steps
38
+ return self.LanPaint(x, sigma, latent_mask, current_times, n_steps, model_options, seed, self.IS_FLUX, self.IS_FLOW)
39
+ def LanPaint(self, x, sigma, latent_mask, current_times, n_steps, model_options, seed, IS_FLUX, IS_FLOW):
40
+ input_x = x
41
+ VE_Sigma, abt, Flow_t = current_times
42
+
43
+ step_size = self.step_size * (1 - abt)
44
+ step_size = self.add_none_dims(step_size)
45
+ # self.inner_model.inner_model.scale_latent_inpaint returns variance exploding x_t values
46
+ # This is the replace step
47
+ def scale_latent_inpaint(x, sigma, noise, latent_image):
48
+ return self.inner_model.inner_model.model_sampling.noise_scaling(sigma.reshape([sigma.shape[0]] + [1] * (len(noise.shape) - 1)), noise, latent_image)
49
+
50
+ x = x * (1 - latent_mask) + scale_latent_inpaint(x=x, sigma=sigma, noise=self.noise, latent_image=self.latent_image)* latent_mask
51
+
52
+ if IS_FLUX or IS_FLOW:
53
+ x_t = x * ( self.add_none_dims(abt)**0.5 + (1-self.add_none_dims(abt))**0.5 )
54
+ else:
55
+ x_t = x / ( 1+self.add_none_dims(VE_Sigma)**2 )**0.5 # switch to variance perserving x_t values
56
+
57
+ ############ LanPaint Iterations Start ###############
58
+ # after noise_scaling, noise = latent_image + noise * sigma, which is x_t in the variance exploding diffusion model notation for the known region.
59
+ args = None
60
+ stopper = LanPaintEarlyStopper.from_options(
61
+ model_options=model_options if isinstance(model_options, dict) else None,
62
+ latent_mask=latent_mask,
63
+ abt=abt,
64
+ default_threshold=self.early_stop_threshold,
65
+ default_patience=self.early_stop_patience,
66
+ default_distance_fn=self.early_stop_hook,
67
+ )
68
+
69
+ for i in range(n_steps):
70
+ score_func = partial( self.score_model, y = self.latent_image, mask = latent_mask, abt = self.add_none_dims(abt), sigma = self.add_none_dims(VE_Sigma), tflow = self.add_none_dims(Flow_t), model_options = model_options, seed = seed )
71
+
72
+ prev_args = args
73
+ x_t_prev = x_t.detach() if (stopper is not None and stopper.has_custom_distance_fn) else None
74
+ x_t_before = x_t if (stopper is not None and stopper.enabled) else None
75
+
76
+ x_t, args = self.langevin_dynamics(x_t, score_func , latent_mask, step_size , current_times, sigma_x = self.add_none_dims(self.sigma_x(abt)), sigma_y = self.add_none_dims(self.sigma_y(abt)), args = args)
77
+
78
+ if stopper is not None:
79
+ ctx = {
80
+ "step": i,
81
+ "steps_done": i + 1,
82
+ "n_steps": n_steps,
83
+ "mask": latent_mask,
84
+ "latent_image": self.latent_image,
85
+ "current_times": current_times,
86
+ "seed": seed,
87
+ }
88
+ if stopper.step(
89
+ i=i,
90
+ n_steps=n_steps,
91
+ x_t_before=x_t_before,
92
+ x_t_after=x_t,
93
+ x_t_prev_for_custom=x_t_prev,
94
+ prev_args=prev_args,
95
+ args=args,
96
+ ctx=ctx,
97
+ ):
98
+ break
99
+
100
+ if IS_FLUX or IS_FLOW:
101
+ x = x_t / ( self.add_none_dims(abt)**0.5 + (1-self.add_none_dims(abt))**0.5 )
102
+ else:
103
+ x = x_t * ( 1+self.add_none_dims(VE_Sigma)**2 )**0.5 # switch to variance perserving x_t values
104
+ ############ LanPaint Iterations End ###############
105
+ # out is x_0
106
+
107
+ out, _ = self.inner_model(x, sigma, model_options=model_options, seed=seed)
108
+ out = out * (1-latent_mask) + self.latent_image * latent_mask
109
+
110
+ input_x.copy_(x)
111
+ return out
112
+
113
+ def score_model(self, x_t, y, mask, abt, sigma, tflow, model_options, seed):
114
+ lamb = self.chara_lamb
115
+ if self.IS_FLUX or self.IS_FLOW:
116
+ # compute t for flow model, with a small epsilon compensating for numerical error.
117
+ x = x_t / ( abt**0.5 + (1-abt)**0.5 ) # switch to Gaussian flow matching
118
+ x_0, x_0_BIG = self.inner_model(x, self.remove_none_dims(tflow), model_options=model_options, seed=seed)
119
+ else:
120
+ x = x_t * ( 1+sigma**2 )**0.5 # switch to variance exploding
121
+ x_0, x_0_BIG = self.inner_model(x, self.remove_none_dims(sigma), model_options=model_options, seed=seed)
122
+
123
+ score_x = -(x_t - x_0)
124
+ score_y = - (1 + lamb) * ( x_t - y ) + lamb * (x_t - x_0_BIG)
125
+ return score_x * (1 - mask) + score_y * mask
126
+ def sigma_x(self, abt):
127
+ # the time scale for the x_t update
128
+ return abt**0
129
+ def sigma_y(self, abt):
130
+ beta = self.chara_beta * abt ** 0
131
+ return beta
132
+
133
+ def langevin_dynamics(self, x_t, score, mask, step_size, current_times, sigma_x=1, sigma_y=0, args=None):
134
+ if args is not None and not isinstance(args, LangevinState):
135
+ if isinstance(args, tuple):
136
+ if len(args) == 2:
137
+ # Backwards compat: older state was (v, C) without x0.
138
+ args = LangevinState(args[0], args[1], None)
139
+ elif len(args) >= 3:
140
+ args = LangevinState(args[0], args[1], args[2])
141
+ # prepare the step size and time parameters
142
+ with torch.autocast(device_type=x_t.device.type, dtype=torch.float32):
143
+ step_sizes = self.prepare_step_size(current_times, step_size, sigma_x, sigma_y)
144
+ sigma, abt, dtx, dty, Gamma_x, Gamma_y, A_x, A_y, D_x, D_y = step_sizes
145
+ # print('mask',mask.device)
146
+ if torch.mean(dtx) <= 0.:
147
+ return x_t, args
148
+ # -------------------------------------------------------------------------
149
+ # Compute the Langevin dynamics update in variance perserving notation
150
+ # -------------------------------------------------------------------------
151
+ #x0 = self.x0_evalutation(x_t, score, sigma, args)
152
+ #C = abt**0.5 * x0 / (1-abt)
153
+ A = A_x * (1-mask) + A_y * mask
154
+ D = D_x * (1-mask) + D_y * mask
155
+ dt = dtx * (1-mask) + dty * mask
156
+ Gamma = Gamma_x * (1-mask) + Gamma_y * mask
157
+
158
+ def Coef_C(x_t):
159
+ x0 = x_t + score(x_t)
160
+ C = (abt**0.5 * x0 - x_t )/ (1-abt) + A * x_t
161
+ return C, x0
162
+ def advance_time(x_t, v, dt, Gamma, A, C, D):
163
+ dtype = x_t.dtype
164
+ with torch.autocast(device_type=x_t.device.type, dtype=torch.float32):
165
+ osc = StochasticHarmonicOscillator(Gamma, A, C, D )
166
+ x_t, v = osc.dynamics(x_t, v, dt )
167
+ x_t = x_t.to(dtype)
168
+ v = v.to(dtype)
169
+ return x_t, v
170
+
171
+ def advance_time_overdamped(x_t, dt, A, C, D):
172
+ """
173
+ Overdamped (Gamma -> infinity) limit:
174
+ dx = -A x dt + C dt + D dW_t
175
+ with C treated as constant over this substep.
176
+ """
177
+ dtype = x_t.dtype
178
+ with torch.autocast(device_type=x_t.device.type, dtype=torch.float32):
179
+ A_dt = A * dt
180
+ exp_neg = torch.exp(-A_dt)
181
+
182
+ eps = 1e-8
183
+ abs_A = torch.abs(A)
184
+ # k = (1 - exp(-A dt)) / A -> dt when A -> 0
185
+ k = torch.where(abs_A < eps, dt, (-torch.expm1(-A_dt)) / A)
186
+ # k2 = (1 - exp(-2 A dt)) / (2 A) -> dt when A -> 0
187
+ k2 = torch.where(abs_A < eps, dt, (-torch.expm1(-2 * A_dt)) / (2 * A))
188
+
189
+ mean = exp_neg * x_t + k * C
190
+ var = (D ** 2) * k2
191
+ noise = torch.randn_like(x_t) * torch.sqrt(torch.clamp(var, min=0.0))
192
+ x_t = mean + noise
193
+ return x_t.to(dtype)
194
+
195
+ def run_damped(x_t, args):
196
+ if args is None:
197
+ v = None
198
+ C, x0 = Coef_C(x_t)
199
+ x_t, v = advance_time(x_t, v, dt, Gamma, A, C, D)
200
+ else:
201
+ v = args.v
202
+ C = args.C
203
+ x_t, v = advance_time(x_t, v, dt/2, Gamma, A, C, D)
204
+ C_new, x0 = Coef_C(x_t)
205
+ v = v + Gamma**0.5 * ( C_new - C) *dt
206
+ x_t, v = advance_time(x_t, v, dt/2, Gamma, A, C, D)
207
+ C = C_new
208
+ # args is (v, C, x0) for the next inner step.
209
+ return x_t, LangevinState(v, C, x0)
210
+
211
+ def run_overdamped(x_t, args):
212
+ if args is None:
213
+ C, x0 = Coef_C(x_t)
214
+ x_t = advance_time_overdamped(x_t, dt, A, C, D)
215
+ else:
216
+ C = args.C
217
+ x_t = advance_time_overdamped(x_t, dt / 2, A, C, D)
218
+ C_new, x0 = Coef_C(x_t)
219
+ x_t = x_t + (C_new - C) * dt
220
+ x_t = advance_time_overdamped(x_t, dt / 2, A, C, D)
221
+ C = C_new
222
+ # args is (v, C, x0); v is None in the overdamped fallback.
223
+ return x_t, LangevinState(None, C, x0)
224
+
225
+ try:
226
+ x_t_next, state = run_damped(x_t, args)
227
+
228
+ v_next = state.v
229
+ if torch.isnan(x_t_next).any() or (v_next is not None and torch.isnan(v_next).any()):
230
+ raise ValueError("NaN detected")
231
+
232
+ x_t = x_t_next
233
+ except Exception:
234
+ x_t, state = run_overdamped(x_t, args)
235
+
236
+ # args is (v, C, x0); v can be None if we fell back to the overdamped update.
237
+ return x_t, state
238
+
239
+ def prepare_step_size(self, current_times, step_size, sigma_x, sigma_y):
240
+ # -------------------------------------------------------------------------
241
+ # Unpack current times parameters (sigma and abt)
242
+ sigma, abt, flow_t = current_times
243
+ sigma = self.add_none_dims(sigma)
244
+ abt = self.add_none_dims(abt)
245
+ # Compute time step (dtx, dty) for x and y branches.
246
+ dtx = 2 * step_size * sigma_x
247
+ dty = 2 * step_size * sigma_y
248
+
249
+ # -------------------------------------------------------------------------
250
+ # Define friction parameter Gamma_hat for each branch.
251
+ # Using dtx**0 provides a tensor of the proper device/dtype.
252
+
253
+ Gamma_hat_x = self.friction **2 * self.step_size * sigma_x / 0.1 * sigma**0
254
+ Gamma_hat_y = self.friction **2 * self.step_size * sigma_y / 0.1 * sigma**0
255
+ #print("Gamma_hat_x", torch.mean(Gamma_hat_x).item(), "Gamma_hat_y", torch.mean(Gamma_hat_y).item())
256
+ # adjust dt to match denoise-addnoise steps sizes
257
+ Gamma_hat_x /= 2.
258
+ Gamma_hat_y /= 2.
259
+ A_t_x = (1) / ( 1 - abt ) * dtx / 2
260
+ A_t_y = (1+self.chara_lamb) / ( 1 - abt ) * dty / 2
261
+
262
+
263
+ A_x = A_t_x / (dtx/2)
264
+ A_y = A_t_y / (dty/2)
265
+ Gamma_x = Gamma_hat_x / (dtx/2)
266
+ Gamma_y = Gamma_hat_y / (dty/2)
267
+
268
+ #D_x = (2 * (1 + sigma**2) )**0.5
269
+ #D_y = (2 * (1 + sigma**2) )**0.5
270
+ D_x = (2 * abt**0 )**0.5
271
+ D_y = (2 * abt**0 )**0.5
272
+ return sigma, abt, dtx/2, dty/2, Gamma_x, Gamma_y, A_x, A_y, D_x, D_y
LanPaint/build/lib/LanPaint/nodes.py ADDED
@@ -0,0 +1,648 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from contextlib import contextmanager
2
+ import math
3
+ # import nodes.py
4
+ import comfy
5
+ import nodes
6
+ import latent_preview
7
+ import torch
8
+ from comfy.utils import repeat_to_batch_size
9
+ from comfy.samplers import *
10
+ from comfy.model_base import ModelType
11
+ from .lanpaint import LanPaint
12
+ from comfy.model_base import WAN22
13
+ import comfyui_version
14
+
15
+ def _version_tuple(value):
16
+ return tuple(int(part) if part.isdigit() else 0 for part in value.split("."))
17
+
18
+ COMFYUI_VERSION_060_OR_NEWER = _version_tuple(comfyui_version.__version__) >= (0, 6, 0)
19
+
20
+ def reshape_mask(input_mask, output_shape,video_inpainting=False):
21
+ dims = len(output_shape) - 2
22
+ print('output shape',output_shape)
23
+ scale_mode = "nearest-exact"
24
+ print('input mask',input_mask.shape,type(input_mask),torch.max(input_mask),torch.min(input_mask))
25
+ print('target output_shape',output_shape)
26
+ print('input_mask.ndim:', input_mask.ndim, 'output_shape len:', len(output_shape))
27
+
28
+ # Handle input mask dimensions
29
+ if input_mask.ndim == 2:
30
+ input_mask = input_mask.unsqueeze(0).unsqueeze(0)
31
+ elif input_mask.ndim == 3:
32
+ input_mask = input_mask.unsqueeze(1)
33
+
34
+ # Handle 5D output shape (B, C, F, H, W) by ensuring input is 5D
35
+ if len(output_shape) == 5 and input_mask.ndim == 4:
36
+ if COMFYUI_VERSION_060_OR_NEWER:
37
+ input_mask = input_mask.unsqueeze(2) # (B, C, 1, H, W)
38
+
39
+ # Handle video case with temporal dimension
40
+ if video_inpainting: # Video case: (batch, channels, frames, height, width)
41
+ target_frames = output_shape[2]
42
+ target_height, target_width = output_shape[-2:]
43
+
44
+ print('Video case - input_mask initial shape:', input_mask.shape)
45
+
46
+ # First reshape input_mask to have proper dimensions for video processing
47
+ # Assume input is (frames, channels, height, width) -> (1, channels, frames, height, width)
48
+ ## if comfy version < 0.6.0
49
+ if not COMFYUI_VERSION_060_OR_NEWER:
50
+ input_mask = input_mask.permute(1, 0, 2, 3).unsqueeze(0)
51
+ print('Video case - input_mask after reshaping:', input_mask.shape)
52
+ # Ensure we have the correct 5D shape: (batch, channels, frames, height, width)
53
+ batch_size, channels, frames, height, width = input_mask.shape
54
+ print('Video case - dimensions: batch_size={}, channels={}, frames={}, height={}, width={}'.format(batch_size, channels, frames, height, width))
55
+ print('Video case - target size:', (target_frames, target_height, target_width))
56
+
57
+ # 3D nearest-exact interpolation: (batch, channels, frames, height, width) -> (batch, channels, target_frames, target_height, target_width)
58
+ temp_mask = torch.nn.functional.interpolate(
59
+ input_mask,
60
+ size=(target_frames, target_height, target_width),
61
+ mode=scale_mode,
62
+ )
63
+
64
+ # temp_mask is already 5D: (batch, channels, target_frames, target_height, target_width)
65
+ mask = temp_mask
66
+ print('after mask',mask.shape)
67
+ # Handle channel dimension expansion if needed
68
+ if mask.shape[1] < output_shape[1]:
69
+ mask = mask.repeat(1, output_shape[1], 1, 1, 1)[:, :output_shape[1]]
70
+ # Handle batch dimension
71
+ mask = repeat_to_batch_size(mask, output_shape[0])
72
+ else: # Original 2D image case
73
+ if not COMFYUI_VERSION_060_OR_NEWER:
74
+ mask = torch.nn.functional.interpolate(input_mask, size=output_shape[-2:], mode=scale_mode)
75
+ else:
76
+ mask = torch.nn.functional.interpolate(input_mask, size=output_shape[2:], mode=scale_mode)
77
+ if mask.shape[1] < output_shape[1]:
78
+ mask = mask.repeat((1, output_shape[1]) + (1,) * dims)[:,:output_shape[1]]
79
+ mask = repeat_to_batch_size(mask, output_shape[0])
80
+
81
+
82
+ return mask
83
+ def prepare_mask(noise_mask, shape, device,video_inpainting=False):
84
+ return reshape_mask(noise_mask, shape,video_inpainting).to(device)
85
+ def sampling_function_LanPaint(model, x, timestep, uncond, cond, cond_scale, cond_scale_BIG, model_options={}, seed=None):
86
+ if math.isclose(cond_scale, 1.0) and model_options.get("disable_cfg1_optimization", False) == False:
87
+ uncond_ = None
88
+ else:
89
+ uncond_ = uncond
90
+
91
+ conds = [cond, uncond_]
92
+ out = calc_cond_batch(model, conds, x, timestep, model_options)
93
+
94
+ for fn in model_options.get("sampler_pre_cfg_function", []):
95
+ args = {"conds":conds, "conds_out": out, "cond_scale": cond_scale, "timestep": timestep,
96
+ "input": x, "sigma": timestep, "model": model, "model_options": model_options}
97
+ out = fn(args)
98
+
99
+ return cfg_function(model, out[0], out[1], cond_scale, x, timestep, model_options=model_options, cond=cond, uncond=uncond_), cfg_function(model, out[0], out[1], cond_scale_BIG, x, timestep, model_options=model_options, cond=cond, uncond=uncond_)
100
+
101
+
102
+ class CFGGuider_LanPaint:
103
+ def outer_sample(self, noise, latent_image, sampler, sigmas, denoise_mask=None, callback=None, disable_pbar=False, seed=None, **kwargs):
104
+ print("CFGGuider outer_sample")
105
+ self.inner_model, self.conds, self.loaded_models = comfy.sampler_helpers.prepare_sampling(self.model_patcher, noise.shape, self.conds, self.model_options)
106
+ device = self.model_patcher.load_device
107
+
108
+ if isinstance(self.inner_model, WAN22):
109
+ print("WAN22 detected")
110
+ self.inner_model.extra_conds = super(WAN22, self.inner_model).extra_conds
111
+
112
+ if denoise_mask is not None:
113
+ video_inpainting = self.model_options.get("video_inpainting", False)
114
+ denoise_mask = prepare_mask(denoise_mask, noise.shape, device, video_inpainting)
115
+
116
+ noise = noise.to(device)
117
+ latent_image = latent_image.to(device)
118
+ sigmas = sigmas.to(device)
119
+ cast_to_load_options(self.model_options, device=device, dtype=self.model_patcher.model_dtype())
120
+
121
+ try:
122
+ self.model_patcher.pre_run()
123
+ output = self.inner_sample(noise, latent_image, device, sampler, sigmas, denoise_mask, callback, disable_pbar, seed, **kwargs)
124
+ finally:
125
+ self.model_patcher.cleanup()
126
+
127
+ comfy.sampler_helpers.cleanup_models(self.conds, self.loaded_models)
128
+ del self.inner_model
129
+ del self.loaded_models
130
+ return output
131
+ def predict_noise(self, x, timestep, model_options={}, seed=None):
132
+ return sampling_function_LanPaint(self.inner_model, x, timestep, self.conds.get("negative", None), self.conds.get("positive", None), self.cfg, self.cfg_BIG, model_options=model_options, seed=seed)
133
+
134
+ #CFGGuider.outer_sample = CFGGuider_LanPaint.outer_sample
135
+ #CFGGuider.predict_noise = CFGGuider_LanPaint.predict_noise
136
+
137
+ class KSamplerX0Inpaint:
138
+ def __init__(self, model, sigmas):
139
+ self.inner_model = model
140
+ self.sigmas = sigmas
141
+ #self.model_sigmas = torch.cat( (torch.tensor([0.], device = sigmas.device) , torch.tensor( self.inner_model.model_patcher.get_model_object("model_sampling").sigmas, device = sigmas.device) ) )
142
+ #self.model_sigmas = torch.tensor( self.model_sigmas, dtype = self.sigmas.dtype )
143
+ def __call__(self, x, sigma, denoise_mask, model_options={}, seed=None,**kwargs):
144
+ ### For 1.5 and XL model
145
+ # x is x_t in the notation of variance exploding diffusion model, x_t = x_0 + sigma * noise
146
+ # sigma is the noise level
147
+ ### For flux model
148
+ # x is rectified flow x_t = sigma * noise + (1.0 - sigma) * x_0
149
+
150
+ IS_FLUX = self.inner_model.inner_model.model_type == ModelType.FLUX
151
+ IS_FLOW = self.inner_model.inner_model.model_type == ModelType.FLOW
152
+ #print("model class", type(self.inner_model.inner_model))
153
+ #print("model type", self.inner_model.inner_model.model_type, "IS_FLUX", IS_FLUX, "IS_FLOW", IS_FLOW)
154
+ #print("sigma", torch.mean(sigma).item(), torch.min(sigma).item(), torch.max(sigma).item())
155
+ # unify the notations into variance exploding diffusion model
156
+ if IS_FLUX or IS_FLOW:
157
+ Flow_t = sigma
158
+ abt = (1 - Flow_t)**2 / ((1 - Flow_t)**2 + Flow_t**2 )
159
+ VE_Sigma = Flow_t / (1 - Flow_t)
160
+ #print("t", torch.mean( sigma ).item(), "VE_Sigma", torch.mean( VE_Sigma ).item())
161
+
162
+
163
+ else:
164
+ VE_Sigma = sigma
165
+ abt = 1/( 1+VE_Sigma**2 )
166
+ Flow_t = (1-abt)**0.5 / ( (1-abt)**0.5 + abt**0.5 )
167
+
168
+ if denoise_mask is not None:
169
+ if "denoise_mask_function" in model_options:
170
+ denoise_mask = model_options["denoise_mask_function"](sigma, denoise_mask, extra_options={"model": self.inner_model, "sigmas": self.sigmas})
171
+
172
+ denoise_mask = (denoise_mask > 0.5).float()
173
+
174
+ latent_mask = 1 - denoise_mask
175
+ current_times = (VE_Sigma, abt, Flow_t)
176
+
177
+ current_step = torch.argmin( torch.abs( self.sigmas - torch.mean(sigma) ) )
178
+ total_steps = len(self.sigmas)-1
179
+
180
+ if total_steps - current_step <= self.LanPaint_early_stop:
181
+ out = self.PaintMethod(x, self.latent_image, self.noise, sigma, latent_mask, current_times, model_options, seed, n_steps=0)
182
+ else:
183
+ out = self.PaintMethod(x, self.latent_image, self.noise, sigma, latent_mask, current_times, model_options, seed)
184
+ else:
185
+ out, _ = self.inner_model(x, sigma, model_options=model_options, seed=seed)
186
+
187
+ # Add TAESD preview support - directly use the latent_preview module
188
+ current_step = model_options.get("i", kwargs.get("i", 0))
189
+ total_steps = model_options.get("total_steps", 0)
190
+
191
+ # Only show preview every few steps to improve performance
192
+ if current_step % 2 == 0:
193
+ # Directly call the preview callback if it exists
194
+ callback = model_options.get("callback", None)
195
+ if callback is not None:
196
+ callback({"i": current_step, "denoised": out, "x": x})
197
+
198
+ return out
199
+
200
+ # Custom sampler class extending ComfyUI's KSAMPLER for LanPaint
201
+ class KSAMPLER(comfy.samplers.KSAMPLER):
202
+ def sample(self, model_wrap, sigmas, extra_args, callback, noise, latent_image=None, denoise_mask=None, disable_pbar=False):
203
+ #noise here is a randn noise from comfy.sample.prepare_noise
204
+ #latent_image is the latent image as input of the KSampler node. For inpainting, it is the masked latent image. Otherwise it is zero tensor.
205
+ extra_args["denoise_mask"] = denoise_mask
206
+ model_k = KSamplerX0Inpaint(model_wrap, sigmas)
207
+ model_k.latent_image = latent_image
208
+ if self.inpaint_options.get("random", False): #TODO: Should this be the default?
209
+ generator = torch.manual_seed(extra_args.get("seed", 41) + 1)
210
+ model_k.noise = torch.randn(noise.shape, generator=generator, device="cpu").to(noise.dtype).to(noise.device)
211
+ else:
212
+ model_k.noise = noise
213
+
214
+ IS_FLUX = model_wrap.inner_model.model_type == ModelType.FLUX
215
+ IS_FLOW = model_wrap.inner_model.model_type == ModelType.FLOW
216
+ # unify the notations into variance exploding diffusion model
217
+ if IS_FLUX:
218
+ model_wrap.cfg_BIG = 1.0
219
+ else:
220
+ model_wrap.cfg_BIG = model_wrap.model_patcher.LanPaint_cfg_BIG
221
+ noise = model_wrap.inner_model.model_sampling.noise_scaling(sigmas[0], noise, latent_image, self.max_denoise(model_wrap, sigmas))
222
+
223
+ model_k.PaintMethod = LanPaint(model_k.inner_model,
224
+ model_wrap.model_patcher.LanPaint_NumSteps,
225
+ model_wrap.model_patcher.LanPaint_Friction,
226
+ model_wrap.model_patcher.LanPaint_Lambda,
227
+ model_wrap.model_patcher.LanPaint_Beta,
228
+ model_wrap.model_patcher.LanPaint_StepSize,
229
+ IS_FLUX = IS_FLUX,
230
+ IS_FLOW = IS_FLOW,
231
+ EarlyStopThreshold = getattr(model_wrap.model_patcher, "LanPaint_InnerThreshold", 0.0),
232
+ EarlyStopPatience = getattr(model_wrap.model_patcher, "LanPaint_InnerPatience", 1),
233
+ EarlyStopHook = extra_args.get("model_options", {}).get("lanpaint_semantic_hook", None))
234
+ model_k.LanPaint_early_stop = model_wrap.model_patcher.LanPaint_EarlyStop
235
+ #if not inpainting, after noise_scaling, noise = noise * sigma, which is the noise added to the clean latent image in the variance exploding diffusion model notation.
236
+ #if inpainting, after noise_scaling, noise = latent_image + noise * sigma, which is x_t in the variance exploding diffusion model notation for the known region.
237
+ k_callback = None
238
+ total_steps = len(sigmas) - 1
239
+ if callback is not None:
240
+ k_callback = lambda x: callback(x["i"], x["denoised"], x["x"], total_steps)
241
+ #print("LanPaint KSampler call sampler_function", self.sampler_function)
242
+ # The main loop!
243
+ #print("##########")
244
+ #print("Sampling with ", self.sampler_function)
245
+ #print("##########")
246
+ samples = self.sampler_function(model_k, noise, sigmas, extra_args=extra_args, callback=k_callback, disable=disable_pbar, **self.extra_options)
247
+ #print("LanPaint KSampler end sampler_function")
248
+ samples = model_wrap.inner_model.model_sampling.inverse_noise_scaling(sigmas[-1], samples)
249
+ return samples
250
+
251
+ @contextmanager
252
+ def override_sample_function():
253
+ original_outer_sample = comfy.samplers.CFGGuider.outer_sample
254
+ comfy.samplers.CFGGuider.outer_sample = CFGGuider_LanPaint.outer_sample
255
+
256
+ original_predict_noise = comfy.samplers.CFGGuider.predict_noise
257
+ comfy.samplers.CFGGuider.predict_noise = CFGGuider_LanPaint.predict_noise
258
+
259
+ original_sample = comfy.samplers.KSAMPLER.sample
260
+ comfy.samplers.KSAMPLER.sample = KSAMPLER.sample
261
+
262
+ try:
263
+ yield
264
+ finally:
265
+ comfy.samplers.KSAMPLER.sample = original_sample
266
+ comfy.samplers.CFGGuider.predict_noise = original_predict_noise
267
+ comfy.samplers.CFGGuider.outer_sample = original_outer_sample
268
+
269
+
270
+ class LanPaint_UpSale_LatentNoiseMask:
271
+ @classmethod
272
+ def INPUT_TYPES(s):
273
+ return {"required": { "samples": ("LATENT",),
274
+ "scale": ("INT", {"default": 2, "min": 2, "max": 8, "step": 1}),
275
+ }}
276
+ RETURN_TYPES = ("LATENT",)
277
+ FUNCTION = "set_mask"
278
+
279
+
280
+ CATEGORY = "latent/inpaint"
281
+
282
+ def set_mask(self, samples, scale):
283
+ s = samples.copy()
284
+ samples = s['samples']
285
+ # generate a mask with every scaleth pixel set to 1
286
+ mask = torch.zeros(samples.shape[0], 1, samples.shape[2], samples.shape[3], device=samples.device) + 1
287
+ mask[:, :, ::scale, ::scale] = 0
288
+ s["noise_mask"] = mask
289
+ return (s,)
290
+
291
+ #KSAMPLER_NAMES = ["euler", "dpmpp_2m", "uni_pc"]
292
+ KSAMPLER_NAMES = ["euler","euler_ancestral", "heun", "heunpp2","dpm_2", "dpm_2_ancestral",
293
+ "dpm_fast", "dpmpp_sde", "dpmpp_sde_gpu",
294
+ "dpmpp_2m", "dpmpp_2m_sde", "dpmpp_2m_sde_gpu", "dpmpp_3m_sde", "dpmpp_3m_sde_gpu", "ddpm",
295
+ "deis", "res_multistep", "res_multistep_ancestral",
296
+ "gradient_estimation", "er_sde", "seeds_2", "seeds_3"]
297
+
298
+ class LanPaint_KSampler():
299
+ @classmethod
300
+ def INPUT_TYPES(s):
301
+ return {
302
+ "required": {
303
+ "model": ("MODEL", {"tooltip": "The model used for denoising the input latent."}),
304
+ "seed": ("INT", {"default": 0, "min": 0, "max": 0xffffffffffffffff, "tooltip": "The random seed used for creating the noise."}),
305
+ "steps": ("INT", {"default": 30, "min": 1, "max": 10000, "tooltip": "The number of steps used in the denoising process."}),
306
+ "cfg": ("FLOAT", {"default": 5.0, "min": 0.0, "max": 100.0, "step":0.1, "round": 0.01, "tooltip": "The Classifier-Free Guidance scale balances creativity and adherence to the prompt. Higher values result in images more closely matching the prompt however too high values will negatively impact quality."}),
307
+ "sampler_name": (KSAMPLER_NAMES, {"tooltip": "Recommended: euler."}),
308
+ "scheduler": (comfy.samplers.KSampler.SCHEDULERS, {"default": "karras", "tooltip": "The scheduler controls how noise is gradually removed to form the image."}),
309
+ "positive": ("CONDITIONING", {"tooltip": "The conditioning describing the attributes you want to include in the image."}),
310
+ "negative": ("CONDITIONING", {"tooltip": "The conditioning describing the attributes you want to exclude from the image."}),
311
+ "latent_image": ("LATENT", {"tooltip": "The latent image to denoise."}),
312
+ "denoise": ("FLOAT", {"default": 1.0, "min": 0.0, "max": 1.0, "step": 0.01, "tooltip": "The amount of denoising applied, lower values will maintain the structure of the initial image allowing for image to image sampling."}),
313
+ "LanPaint_NumSteps": ("INT", {"default": 5, "min": 0, "max": 100, "tooltip": "The number of steps for the Langevin dynamics, representing the turns of thinking per step."}),
314
+ "LanPaint_PromptMode": (["Image First", "Prompt First"], {"tooltip": "Image First: emphasis image quality, Prompt First: emphasis prompt following"}),
315
+ "LanPaint_Info": ("STRING", {"default": "LanPaint KSampler. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!", "multiline": True}),
316
+ "Inpainting_mode": (["🖼️ Image Inpainting", "🎬 Video Inpainting"], {"default": "🖼️ Image Inpainting", "tooltip": "Choose Image mode for photos or Video mode for video frames with temporal consistency"}),
317
+ }
318
+ }
319
+
320
+ RETURN_TYPES = ("LATENT",)
321
+ OUTPUT_TOOLTIPS = ("The denoised latent.",)
322
+ FUNCTION = "sample"
323
+
324
+ CATEGORY = "sampling"
325
+ DESCRIPTION = "Uses the provided model, positive and negative conditioning to denoise the latent image."
326
+
327
+ def sample(self, model, seed, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, denoise=1.0, LanPaint_NumSteps=5, LanPaint_PromptMode="Image First", LanPaint_Info="",Inpainting_mode="🖼️ Image Inpainting"):
328
+
329
+ model.LanPaint_StepSize = 0.2
330
+ model.LanPaint_Lambda = 16.0
331
+ model.LanPaint_Beta = 1.
332
+ model.LanPaint_NumSteps = LanPaint_NumSteps
333
+ model.LanPaint_Friction = 15.
334
+ model.LanPaint_EarlyStop = 1
335
+ model.LanPaint_InnerThreshold = 0.0
336
+ model.LanPaint_InnerPatience = 1
337
+ if LanPaint_PromptMode == "Image First":
338
+ model.LanPaint_cfg_BIG = cfg
339
+ else:
340
+ model.LanPaint_cfg_BIG = 0*cfg - 0.5
341
+
342
+ # Convert inpainting_mode to boolean for video_inpainting
343
+ video_inpainting = (Inpainting_mode == "🎬 Video Inpainting")
344
+ if not hasattr(model, 'model_options') or model.model_options is None:
345
+ model.model_options = {}
346
+ model.model_options["video_inpainting"] = video_inpainting
347
+
348
+ with override_sample_function():
349
+ return nodes.common_ksampler(model, seed, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, denoise=denoise)
350
+ class LanPaint_KSamplerAdvanced:
351
+ @classmethod
352
+ def INPUT_TYPES(s):
353
+ return {"required":
354
+ {"model": ("MODEL",),
355
+ "add_noise": (["enable", "disable"], ),
356
+ "noise_seed": ("INT", {"default": 0, "min": 0, "max": 0xffffffffffffffff}),
357
+ "steps": ("INT", {"default": 30, "min": 1, "max": 10000}),
358
+ "cfg": ("FLOAT", {"default": 5.0, "min": 0.0, "max": 100.0, "step":0.1, "round": 0.01}),
359
+ "sampler_name": (KSAMPLER_NAMES, ),
360
+ "scheduler": (comfy.samplers.KSampler.SCHEDULERS, ),
361
+ "positive": ("CONDITIONING", ),
362
+ "negative": ("CONDITIONING", ),
363
+ "latent_image": ("LATENT", ),
364
+ "start_at_step": ("INT", {"default": 0, "min": 0, "max": 10000}),
365
+ "end_at_step": ("INT", {"default": 10000, "min": 0, "max": 10000}),
366
+ "return_with_leftover_noise": (["disable", "enable"], ),
367
+ "LanPaint_NumSteps": ("INT", {"default": 5, "min": 0, "max": 100, "tooltip": "The number of steps for the Langevin dynamics, representing the turns of thinking per step."}),
368
+ "LanPaint_Lambda": ("FLOAT", {"default": 16., "min": 0.1, "max": 50.0, "step": 0.1, "round": 0.1, "tooltip": "The bidirectional guidance scale. Higher values align with known regions more closely, but may result in instability."}),
369
+ "LanPaint_StepSize": ("FLOAT", {"default": 0.2, "min": 0.0001, "max": 1., "step": 0.01, "round": 0.001, "tooltip": "The step size for the Langevin dynamics. Higher values result in faster convergence but may be unstable."}),
370
+ "LanPaint_Beta": ("FLOAT", {"default": 1., "min": 0.0001, "max": 5, "step": 0.1, "round": 0.1, "tooltip": "The step size ratio between masked / unmasked regions. Lower value can compensate high values of LanPaint_Lambda."}),
371
+ "LanPaint_Friction": ("FLOAT", {"default": 15, "min": 0., "max": 50.0, "step": 0.1, "round": 0.1, "tooltip": "The friction parameter for fast langevin, lower values result in faster convergence but may be unstable."}),
372
+ "LanPaint_PromptMode": (["Image First", "Prompt First"], {"tooltip": "Image First: emphasis image quality, Prompt First: emphasis prompt following"}),
373
+ "LanPaint_EarlyStop": ("INT", {"default": 1, "min": 0, "max": 10000, "tooltip": "The number of steps to stop the LanPaint early, useful for preventing the image from irregular patterns."}),
374
+ "LanPaint_Info": ("STRING", {"default": "LanPaint KSampler Adv. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!", "multiline": True}),
375
+ "Inpainting_mode": (["🖼️ Image Inpainting", "🎬 Video Inpainting"], {"default": "🖼️ Image Inpainting", "tooltip": "Choose Image mode for photos or Video mode for video frames with temporal consistency"}),
376
+ "LanPaint_InnerThreshold": ("FLOAT", {"default": 0.0, "min": 0.0, "max": 1.0, "step": 0.0001, "round": 0.0001, "tooltip": "Early stop threshold for Langevin iterations based on semantic distance. 0.0 to disable. (Contributed by godnight10061)"}),
377
+ "LanPaint_InnerPatience": ("INT", {"default": 1, "min": 1, "max": 100, "tooltip": "Number of consecutive steps below threshold required to stop. (Contributed by godnight10061)"}),
378
+ },
379
+ }
380
+
381
+ RETURN_TYPES = ("LATENT",)
382
+ FUNCTION = "sample"
383
+
384
+ CATEGORY = "sampling"
385
+
386
+ def sample(self, model, add_noise, noise_seed, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, start_at_step, end_at_step, return_with_leftover_noise, LanPaint_NumSteps=5, LanPaint_Lambda=16.0, LanPaint_StepSize=0.2, LanPaint_Beta=1.0, LanPaint_Friction=15.0, LanPaint_PromptMode="Image First", LanPaint_EarlyStop=1, LanPaint_Info="", Inpainting_mode="🖼️ Image Inpainting", LanPaint_InnerThreshold=0.0, LanPaint_InnerPatience=1):
387
+ force_full_denoise = True
388
+ if return_with_leftover_noise == "enable":
389
+ force_full_denoise = False
390
+ disable_noise = False
391
+ if add_noise == "disable":
392
+ disable_noise = True
393
+ model.LanPaint_StepSize = LanPaint_StepSize
394
+ model.LanPaint_Lambda = LanPaint_Lambda
395
+ model.LanPaint_Beta = LanPaint_Beta
396
+ model.LanPaint_NumSteps = LanPaint_NumSteps
397
+ model.LanPaint_Friction = LanPaint_Friction
398
+ model.LanPaint_EarlyStop = LanPaint_EarlyStop
399
+ model.LanPaint_InnerThreshold = LanPaint_InnerThreshold
400
+ model.LanPaint_InnerPatience = LanPaint_InnerPatience
401
+ if LanPaint_PromptMode == "Image First":
402
+ model.LanPaint_cfg_BIG = cfg
403
+ else:
404
+ model.LanPaint_cfg_BIG = 0*cfg - 0.5
405
+
406
+ # Convert inpainting_mode to boolean for video_inpainting
407
+ video_inpainting = (Inpainting_mode == "🎬 Video Inpainting")
408
+ if not hasattr(model, 'model_options') or model.model_options is None:
409
+ model.model_options = {}
410
+ model.model_options["video_inpainting"] = video_inpainting
411
+
412
+ with override_sample_function():
413
+ return nodes.common_ksampler(model, noise_seed, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, denoise=1.0, disable_noise=disable_noise, start_step=start_at_step, last_step=end_at_step, force_full_denoise=force_full_denoise)
414
+
415
+
416
+ class MaskBlend:
417
+ def __init__(self):
418
+ pass
419
+
420
+ @classmethod
421
+ def INPUT_TYPES(s):
422
+ return {
423
+ "required": {
424
+ "image1": ("IMAGE", {"tooltip": "Image before inpaint"}),
425
+ "image2": ("IMAGE", {"tooltip": "Image after inpaint"}),
426
+ "mask": ("MASK",),
427
+ "blend_overlap": ("INT", {"default": 1, "min": 1, "max": 51, "step": 2, "tooltip": "The number of pixels to blend between the two images."})
428
+ },
429
+ }
430
+
431
+ RETURN_TYPES = ("IMAGE",)
432
+ FUNCTION = "blend_images"
433
+
434
+ CATEGORY = "image/postprocessing"
435
+
436
+ def blend_images(self, image1: torch.Tensor, image2: torch.Tensor, mask: torch.Tensor, blend_overlap: int):
437
+ # smooth the binary 01 mask, keep 1 still 1, but smooth the transition from 1 to 0
438
+ # for each mask pixel, find out the nearest 1 pixel, and set the mask value to the distance between the two pixels
439
+ # check the size of mask and image1, image2, if not the same, assert error
440
+ if image1.shape[1] != image2.shape[1] or image1.shape[2] != image2.shape[2]:
441
+ raise ValueError(
442
+ "Image size mismatch: Image1 and Image2 must have the same dimensions.\n"
443
+ "Additionally, ensure both images have width and height that are multiples of 8.\n"
444
+ "This is required because VAE decode always generates images with dimensions that are multiples of 8.\n"
445
+ "If your input images are not multiples of 8, a size mismatch will occur during the decoding process.\n"
446
+ "Please resize your images using an image resize node to ensure compatibility.\n"
447
+ "Current sizes - Image1: {}x{}, Image2: {}x{}".format(
448
+ image1.shape[2], image1.shape[1], image2.shape[2], image2.shape[1]
449
+ )
450
+ )
451
+ mask = mask.float()
452
+ mask = torch.nn.functional.max_pool2d(mask, kernel_size=blend_overlap, stride=1, padding=blend_overlap//2)
453
+ # apply Gaussian blur with kernel size blend_overlap
454
+ kernel = self.gaussian_kernel(blend_overlap)
455
+ kernel = kernel.to(image1.device)
456
+ kernel = kernel[None, None, ...]
457
+
458
+ mask = torch.nn.functional.conv2d(mask[:,None,:,:], kernel, padding=blend_overlap//2)[:,0,:,:]
459
+
460
+
461
+ blended_image = image1 * (1 - mask[...,None]) + image2 * mask[...,None]
462
+ return (blended_image,)
463
+ def gaussian_kernel(self,kernel_size):
464
+ """
465
+ Creates a 2D Gaussian kernel with the given size and standard deviation (sigma).
466
+ """
467
+ sigma = (kernel_size - 1)/4
468
+ # Create a grid of (x, y) coordinates
469
+ x = torch.arange(kernel_size).float() - kernel_size // 2
470
+ y = torch.arange(kernel_size).float() - kernel_size // 2
471
+ x_grid, y_grid = torch.meshgrid(x, y, indexing='ij')
472
+
473
+ # Compute the Gaussian function
474
+ kernel = torch.exp(-(x_grid ** 2 + y_grid ** 2) / (2 * sigma ** 2))
475
+ kernel = kernel / kernel.sum() # Normalize the kernel
476
+
477
+ return kernel
478
+
479
+ class Noise_EmptyNoise:
480
+ def generate_noise(self, latent):
481
+ return torch.zeros_like(latent["samples"])
482
+
483
+ class Noise_RandomNoise:
484
+ def __init__(self, seed):
485
+ self.seed = seed
486
+ def generate_noise(self, latent):
487
+ torch.manual_seed(self.seed)
488
+ return torch.randn_like(latent["samples"])
489
+
490
+ # Custom sampler implementation mimmicking base comfy nodes_custom_sampler.py
491
+ class LanPaint_SamplerCustom:
492
+ @classmethod
493
+ def INPUT_TYPES(s):
494
+ return {"required":
495
+ {"model": ("MODEL",),
496
+ "add_noise": ("BOOLEAN", {"default": True}),
497
+ "noise_seed": ("INT", {"default": 0, "min": 0, "max": 0xffffffffffffffff, "control_after_generate": True}),
498
+ "cfg": ("FLOAT", {"default": 8.0, "min": 0.0, "max": 100.0, "step": 0.1, "round": 0.01}),
499
+ "positive": ("CONDITIONING",),
500
+ "negative": ("CONDITIONING",),
501
+ "sampler": ("SAMPLER",),
502
+ "sigmas": ("SIGMAS",),
503
+ "latent_image": ("LATENT",),
504
+ "LanPaint_NumSteps": ("INT", {"default": 5, "min": 0, "max": 100, "tooltip": "Number of steps for Langevin dynamics, representing turns of thinking per step."}),
505
+ "LanPaint_PromptMode": (["Image First", "Prompt First"], {"tooltip": "Image First: prioritizes image quality; Prompt First: prioritizes prompt adherence."}),
506
+ "LanPaint_Info": ("STRING", {"default": "LanPaint Custom Sampler. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!", "multiline": True}),
507
+ }
508
+ }
509
+
510
+ RETURN_TYPES = ("LATENT", "LATENT")
511
+ RETURN_NAMES = ("output", "denoised_output")
512
+ FUNCTION = "sample"
513
+ CATEGORY = "sampling/custom_sampling"
514
+
515
+ def sample(self, model, sampler, sigmas, add_noise, noise_seed, cfg, positive, negative, latent_image, LanPaint_NumSteps, LanPaint_PromptMode, LanPaint_Info=""):
516
+ model.LanPaint_StepSize = 0.2
517
+ model.LanPaint_Lambda = 16.0
518
+ model.LanPaint_Beta = 1.
519
+ model.LanPaint_NumSteps = LanPaint_NumSteps
520
+ model.LanPaint_Friction = 15.
521
+ model.LanPaint_EarlyStop = 1
522
+ model.LanPaint_InnerThreshold = 0.0
523
+ model.LanPaint_InnerPatience = 1
524
+ if LanPaint_PromptMode == "Image First":
525
+ model.LanPaint_cfg_BIG = cfg
526
+ else:
527
+ model.LanPaint_cfg_BIG = 0 * cfg - 0.5
528
+ with override_sample_function():
529
+ latent = latent_image.copy()
530
+ latent_image = latent["samples"]
531
+ latent_image = comfy.sample.fix_empty_latent_channels(model, latent_image)
532
+ latent["samples"] = latent_image
533
+
534
+ if not add_noise:
535
+ noise = Noise_EmptyNoise().generate_noise(latent)
536
+ else:
537
+ noise = Noise_RandomNoise(noise_seed).generate_noise(latent)
538
+
539
+ noise_mask = None
540
+ if "noise_mask" in latent:
541
+ noise_mask = latent["noise_mask"]
542
+
543
+ x0_output = {}
544
+ callback = latent_preview.prepare_callback(model, sigmas.shape[-1] - 1, x0_output)
545
+ disable_pbar = not comfy.utils.PROGRESS_BAR_ENABLED
546
+
547
+ samples = comfy.sample.sample_custom(model, noise, cfg, sampler, sigmas, positive, negative, latent_image,noise_mask=noise_mask, callback=callback, disable_pbar=disable_pbar, seed=noise_seed)
548
+
549
+ out = latent.copy()
550
+ out["samples"] = samples
551
+ if "x0" in x0_output:
552
+ out_denoised = latent.copy()
553
+ out_denoised["samples"] = model.model.process_latent_out(x0_output["x0"].cpu())
554
+ else:
555
+ out_denoised = out
556
+ return (out, out_denoised)
557
+
558
+ class LanPaint_SamplerCustomAdvanced:
559
+ @classmethod
560
+ def INPUT_TYPES(s):
561
+ return {"required":
562
+ {"noise": ("NOISE",),
563
+ "guider": ("GUIDER", ),
564
+ "sampler": ("SAMPLER", ),
565
+ "sigmas": ("SIGMAS", ),
566
+ "latent_image": ("LATENT", ),
567
+ "LanPaint_NumSteps": ("INT", {"default": 5, "min": 0, "max": 100, "tooltip": "Number of steps for Langevin dynamics, representing turns of thinking per step."}),
568
+ "LanPaint_Lambda": ("FLOAT", {"default": 16.0, "min": 0.1, "max": 50.0, "step": 0.1, "tooltip": "Bidirectional guidance scale. Higher values align with known regions but may cause instability."}),
569
+ "LanPaint_StepSize": ("FLOAT", {"default": 0.2, "min": 0.0001, "max": 1.0, "step": 0.01, "tooltip": "Step size for Langevin dynamics. Higher values speed convergence but may be unstable."}),
570
+ "LanPaint_Beta": ("FLOAT", {"default": 1.0, "min": 0.0001, "max": 5.0, "step": 0.1, "tooltip": "Step size ratio between masked/unmasked regions. Lower values balance high Lambda."}),
571
+ "LanPaint_Friction": ("FLOAT", {"default": 15.0, "min": 0.0, "max": 50.0, "step": 0.1, "tooltip": "Friction parameter for fast Langevin. Lower values speed convergence but may be unstable."}),
572
+ "LanPaint_PromptMode": (["Image First", "Prompt First"], {"tooltip": "Image First: prioritizes image quality; Prompt First: prioritizes prompt adherence."}),
573
+ "LanPaint_EarlyStop": ("INT", {"default": 1, "min": 0, "max": 10000, "tooltip": "Steps to stop LanPaint early, preventing irregular patterns."}),
574
+ "LanPaint_Info": ("STRING", {"default": "LanPaint Custom Sampler Adv. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!", "multiline": True}),
575
+ "LanPaint_InnerThreshold": ("FLOAT", {"default": 0.0, "min": 0.0, "max": 1.0, "step": 0.0001, "round": 0.0001, "tooltip": "Early stop threshold for Langevin iterations based on semantic distance. 0.0 to disable. (Contributed by godnight10061)"}),
576
+ "LanPaint_InnerPatience": ("INT", {"default": 1, "min": 1, "max": 100, "tooltip": "Number of consecutive steps below threshold required to stop. (Contributed by godnight10061)"}),
577
+ }
578
+ }
579
+
580
+ RETURN_TYPES = ("LATENT","LATENT")
581
+ RETURN_NAMES = ("output", "denoised_output")
582
+
583
+ FUNCTION = "sample"
584
+
585
+ CATEGORY = "sampling/custom_sampling"
586
+
587
+ def sample(self, noise, guider, sampler, sigmas, latent_image, LanPaint_NumSteps, LanPaint_Lambda, LanPaint_StepSize, LanPaint_Beta, LanPaint_Friction, LanPaint_PromptMode, LanPaint_EarlyStop, LanPaint_Info="", LanPaint_InnerThreshold=0.0, LanPaint_InnerPatience=1):
588
+ model = guider.model_patcher
589
+ model.LanPaint_StepSize = LanPaint_StepSize
590
+ model.LanPaint_Lambda = LanPaint_Lambda
591
+ model.LanPaint_Beta = LanPaint_Beta
592
+ model.LanPaint_NumSteps = LanPaint_NumSteps
593
+ model.LanPaint_Friction = LanPaint_Friction
594
+ model.LanPaint_EarlyStop = LanPaint_EarlyStop
595
+ model.LanPaint_InnerThreshold = LanPaint_InnerThreshold
596
+ model.LanPaint_InnerPatience = LanPaint_InnerPatience
597
+ if LanPaint_PromptMode == "Image First":
598
+ model.LanPaint_cfg_BIG = guider.cfg
599
+ else:
600
+ model.LanPaint_cfg_BIG = 0 * guider.cfg - 0.5
601
+ with override_sample_function():
602
+ latent = latent_image
603
+ latent_image = latent["samples"]
604
+ latent = latent.copy()
605
+ latent_image = comfy.sample.fix_empty_latent_channels(guider.model_patcher, latent_image)
606
+ latent["samples"] = latent_image
607
+
608
+ noise_mask = None
609
+ if "noise_mask" in latent:
610
+ noise_mask = latent["noise_mask"]
611
+
612
+ x0_output = {}
613
+ callback = latent_preview.prepare_callback(guider.model_patcher, sigmas.shape[-1] - 1, x0_output)
614
+
615
+ disable_pbar = not comfy.utils.PROGRESS_BAR_ENABLED
616
+ samples = guider.sample(noise.generate_noise(latent), latent_image, sampler, sigmas, denoise_mask=noise_mask, callback=callback, disable_pbar=disable_pbar, seed=noise.seed)
617
+ samples = samples.to(comfy.model_management.intermediate_device())
618
+
619
+ out = latent.copy()
620
+ out["samples"] = samples
621
+ if "x0" in x0_output:
622
+ out_denoised = latent.copy()
623
+ out_denoised["samples"] = guider.model_patcher.model.process_latent_out(x0_output["x0"].cpu())
624
+ else:
625
+ out_denoised = out
626
+ return (out, out_denoised)
627
+
628
+
629
+ # A dictionary that contains all nodes you want to export with their names
630
+ # NOTE: names should be globally unique
631
+ NODE_CLASS_MAPPINGS = {
632
+ "LanPaint_KSampler": LanPaint_KSampler,
633
+ "LanPaint_KSamplerAdvanced": LanPaint_KSamplerAdvanced,
634
+ "LanPaint_SamplerCustom" : LanPaint_SamplerCustom,
635
+ "LanPaint_SamplerCustomAdvanced" : LanPaint_SamplerCustomAdvanced,
636
+ "LanPaint_MaskBlend": MaskBlend,
637
+ # "LanPaint_UpSale_LatentNoiseMask": LanPaint_UpSale_LatentNoiseMask,
638
+ }
639
+
640
+ # A dictionary that contains the friendly/humanly readable titles for the nodes
641
+ NODE_DISPLAY_NAME_MAPPINGS = {
642
+ "LanPaint_KSampler": "LanPaint KSampler",
643
+ "LanPaint_KSamplerAdvanced": "LanPaint KSampler (Advanced)",
644
+ "LanPaint_SamplerCustom" : "LanPaint Sampler Custom",
645
+ "LanPaint_SamplerCustomAdvanced" : "LanPaint Sampler Custom (Advanced)",
646
+ "LanPaint_MaskBlend": "LanPaint Mask Blend",
647
+ # "LanPaint_UpSale_LatentNoiseMask": "LanPaint UpSale Latent Noise Mask"
648
+ }
LanPaint/build/lib/LanPaint/types.py ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ from typing import NamedTuple, Optional
2
+
3
+ import torch
4
+
5
+
6
+ class LangevinState(NamedTuple):
7
+ v: Optional[torch.Tensor]
8
+ C: Optional[torch.Tensor]
9
+ x0: Optional[torch.Tensor]
10
+
LanPaint/build/lib/LanPaint/utils.py ADDED
@@ -0,0 +1,300 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import torch
2
+ def epxm1_x(x):
3
+ # Compute the (exp(x) - 1) / x term with a small value to avoid division by zero.
4
+ result = torch.special.expm1(x) / x
5
+ # replace NaN or inf values with 0
6
+ result = torch.where(torch.isfinite(result), result, torch.zeros_like(result))
7
+ mask = torch.abs(x) < 1e-2
8
+ result = torch.where(mask, 1 + x/2. + x**2 / 6., result)
9
+ return result
10
+ def epxm1mx_x2(x):
11
+ # Compute the (exp(x) - 1 - x) / x**2 term with a small value to avoid division by zero.
12
+ result = (torch.special.expm1(x) - x) / x**2
13
+ # replace NaN or inf values with 0
14
+ result = torch.where(torch.isfinite(result), result, torch.zeros_like(result))
15
+ mask = torch.abs(x**2) < 1e-2
16
+ result = torch.where(mask, 1/2. + x/6 + x**2 / 24 + x**3 / 120, result)
17
+ return result
18
+
19
+ def expm1mxmhx2_x3(x):
20
+ # Compute the (exp(x) - 1 - x - x**2 / 2) / x**3 term with a small value to avoid division by zero.
21
+ result = (torch.special.expm1(x) - x - x**2 / 2) / x**3
22
+ # replace NaN or inf values with 0
23
+ result = torch.where(torch.isfinite(result), result, torch.zeros_like(result))
24
+ mask = torch.abs(x**3) < 1e-2
25
+ result = torch.where(mask, 1/6 + x/24 + x**2 / 120 + x**3 / 720 + x**4 / 5040, result)
26
+ return result
27
+
28
+ def exp_1mcosh_GD(gamma_t, delta):
29
+ """
30
+ Compute e^(-Γt) * (1 - cosh(Γt√Δ))/ ( (Γt)**2 Δ )
31
+
32
+ Parameters:
33
+ gamma_t: Γ*t term (could be a scalar or tensor)
34
+ delta: Δ term (could be a scalar or tensor)
35
+
36
+ Returns:
37
+ Result of the computation with numerical stability handling
38
+ """
39
+ # Main computation
40
+ is_positive = delta > 0
41
+ sqrt_abs_delta = torch.sqrt(torch.abs(delta))
42
+ gamma_t_sqrt_delta = gamma_t * sqrt_abs_delta
43
+ numerator_pos = torch.exp(-gamma_t) - (torch.exp(gamma_t * (sqrt_abs_delta - 1)) + torch.exp(gamma_t * (-sqrt_abs_delta - 1))) / 2
44
+ numerator_neg = torch.exp(-gamma_t) * ( 1 - torch.cos(gamma_t * sqrt_abs_delta ) )
45
+ numerator = torch.where(is_positive, numerator_pos, numerator_neg)
46
+ result = numerator / (delta * gamma_t**2 )
47
+ # Handle NaN/inf cases
48
+ result = torch.where(torch.isfinite(result), result, torch.zeros_like(result))
49
+ # Handle numerical instability for small delta
50
+ mask = torch.abs(gamma_t_sqrt_delta**2) < 5e-2
51
+ taylor = ( -0.5 - gamma_t**2 / 24 * delta - gamma_t**4 / 720 * delta**2 ) * torch.exp(-gamma_t)
52
+ result = torch.where(mask, taylor, result)
53
+ return result
54
+
55
+ def exp_sinh_GsqrtD(gamma_t, delta):
56
+ """
57
+ Compute e^(-Γt) * sinh(Γt√Δ) / (Γt√Δ)
58
+
59
+ Parameters:
60
+ gamma_t: Γ*t term (could be a scalar or tensor)
61
+ delta: Δ term (could be a scalar or tensor)
62
+
63
+ Returns:
64
+ Result of the computation with numerical stability handling
65
+ """
66
+ # Main computation
67
+ is_positive = delta > 0
68
+ sqrt_abs_delta = torch.sqrt(torch.abs(delta))
69
+ gamma_t_sqrt_delta = gamma_t * sqrt_abs_delta
70
+ numerator_pos = (torch.exp(gamma_t * (sqrt_abs_delta - 1)) - torch.exp(gamma_t * (-sqrt_abs_delta - 1))) / 2
71
+ result_pos = numerator_pos / gamma_t_sqrt_delta
72
+ result_pos = torch.where(torch.isfinite(result_pos), result_pos, torch.zeros_like(result_pos))
73
+
74
+ # Taylor expansion for small gamma_t_sqrt_delta
75
+ mask = torch.abs(gamma_t_sqrt_delta) < 1e-2
76
+ taylor = ( 1 + gamma_t**2 / 6 * delta + gamma_t**4 / 120 * delta**2 ) * torch.exp(-gamma_t)
77
+ result_pos = torch.where(mask, taylor, result_pos)
78
+
79
+ # Handle negative delta
80
+ result_neg = torch.exp(-gamma_t) * torch.special.sinc(gamma_t_sqrt_delta/torch.pi)
81
+ result = torch.where(is_positive, result_pos, result_neg)
82
+ return result
83
+
84
+ def exp_cosh(gamma_t, delta):
85
+ """
86
+ Compute e^(-Γt) * cosh(Γt√Δ)
87
+
88
+ Parameters:
89
+ gamma_t: Γ*t term (could be a scalar or tensor)
90
+ delta: Δ term (could be a scalar or tensor)
91
+
92
+ Returns:
93
+ Result of the computation with numerical stability handling
94
+ """
95
+ exp_1mcosh_GD_result = exp_1mcosh_GD(gamma_t, delta) # e^(-Γt) * (1 - cosh(Γt√Δ))/ ( (Γt)**2 Δ )
96
+ result = torch.exp(-gamma_t) - gamma_t**2 * delta * exp_1mcosh_GD_result
97
+ return result
98
+ def exp_sinh_sqrtD(gamma_t, delta):
99
+ """
100
+ Compute e^(-Γt) * sinh(Γt√Δ) / √Δ
101
+ Parameters:
102
+ gamma_t: Γ*t term (could be a scalar or tensor)
103
+ delta: Δ term (could be a scalar or tensor)
104
+ Returns:
105
+ Result of the computation with numerical stability handling
106
+ """
107
+ exp_sinh_GsqrtD_result = exp_sinh_GsqrtD(gamma_t, delta) # e^(-Γt) * sinh(Γt√Δ) / (Γt√Δ)
108
+ result = gamma_t * exp_sinh_GsqrtD_result
109
+ return result
110
+
111
+
112
+
113
+ def zeta1(gamma_t, delta):
114
+ # Compute hyperbolic terms and exponential
115
+ half_gamma_t = gamma_t / 2
116
+ exp_cosh_term = exp_cosh(half_gamma_t, delta)
117
+ exp_sinh_term = exp_sinh_sqrtD(half_gamma_t, delta)
118
+
119
+
120
+ # Main computation
121
+ numerator = 1 - (exp_cosh_term + exp_sinh_term)
122
+ denominator = gamma_t * (1 - delta) / 4
123
+ result = 1 - numerator / denominator
124
+
125
+ # Handle numerical instability
126
+ result = torch.where(torch.isfinite(result), result, torch.zeros_like(result))
127
+
128
+ # Taylor expansion for small x (similar to your epxm1Dx approach)
129
+ mask = torch.abs(denominator) < 5e-3
130
+ term1 = epxm1_x(-gamma_t)
131
+ term2 = epxm1mx_x2(-gamma_t)
132
+ term3 = expm1mxmhx2_x3(-gamma_t)
133
+ taylor = term1 + (1/2.+ term1-3*term2)*denominator + (-1/6. + term1/2 - 4 * term2 + 10 * term3) * denominator**2
134
+ result = torch.where(mask, taylor, result)
135
+
136
+ return result
137
+
138
+ def exp_cosh_minus_terms(gamma_t, delta):
139
+ """
140
+ Compute E^(-tΓ) * (Cosh[tΓ] - 1 - (Cosh[tΓ√Δ] - 1)/Δ) / (tΓ(1 - Δ))
141
+
142
+ Parameters:
143
+ gamma_t: Γ*t term (could be a scalar or tensor)
144
+ delta: Δ term (could be a scalar or tensor)
145
+
146
+ Returns:
147
+ Result of the computation with numerical stability handling
148
+ """
149
+ exp_term = torch.exp(-gamma_t)
150
+ # Compute individual terms
151
+ exp_cosh_term = exp_cosh(gamma_t, gamma_t**0) - exp_term # E^(-tΓ) (Cosh[tΓ] - 1) term
152
+ exp_cosh_delta_term = - gamma_t**2 * exp_1mcosh_GD(gamma_t, delta) # E^(-tΓ) (Cosh[tΓ√Δ] - 1)/Δ term
153
+
154
+ #exp_1mcosh_GD e^(-Γt) * (1 - cosh(Γt√Δ))/ ( (Γt)**2 Δ )
155
+ # Main computation
156
+ numerator = exp_cosh_term - exp_cosh_delta_term
157
+ denominator = gamma_t * (1 - delta)
158
+
159
+ result = numerator / denominator
160
+
161
+ # Handle numerical instability
162
+ result = torch.where(torch.isfinite(result), result, torch.zeros_like(result))
163
+
164
+ # Taylor expansion for small gamma_t and delta near 1
165
+ mask = (torch.abs(denominator) < 1e-1)
166
+ exp_1mcosh_GD_term = exp_1mcosh_GD(gamma_t, delta**0)
167
+ taylor = (
168
+ gamma_t*exp_1mcosh_GD_term + 0.5 * gamma_t * exp_sinh_GsqrtD(gamma_t, delta**0)
169
+ - denominator / 4 * ( 0.5 * exp_cosh(gamma_t, delta**0) - 4 * exp_1mcosh_GD_term - 5 /2 * exp_sinh_GsqrtD(gamma_t, delta**0) )
170
+ )
171
+ result = torch.where(mask, taylor, result)
172
+
173
+ return result
174
+
175
+
176
+ def zeta2(gamma_t, delta):
177
+ half_gamma_t = gamma_t / 2
178
+ return exp_sinh_GsqrtD(half_gamma_t, delta)
179
+
180
+ def sig11(gamma_t, delta):
181
+ return 1 - torch.exp(-gamma_t) + gamma_t**2 * exp_1mcosh_GD(gamma_t, delta) + exp_sinh_sqrtD(gamma_t, delta)
182
+
183
+
184
+ def Zcoefs(gamma_t, delta):
185
+ Zeta1 = zeta1(gamma_t, delta)
186
+ Zeta2 = zeta2(gamma_t, delta)
187
+
188
+ sq_total = 1 - Zeta1 + gamma_t * (delta - 1) * (Zeta1 - 1)**2 / 8
189
+ amplitude = torch.sqrt(sq_total)
190
+ Zcoef1 = ( gamma_t**0.5 * Zeta2 / 2 **0.5 ) / amplitude
191
+ Zcoef2 = Zcoef1 * gamma_t *( - 2 * exp_1mcosh_GD(gamma_t, delta) / sig11(gamma_t, delta) ) ** 0.5
192
+ #cterm = exp_cosh_minus_terms(gamma_t, delta)
193
+ #sterm = exp_sinh_sqrtD(gamma_t, delta**0) + exp_sinh_sqrtD(gamma_t, delta)
194
+ #Zcoef3 = 2 * torch.sqrt( cterm / ( gamma_t * (1 - delta) * cterm + sterm ) )
195
+ Zcoef3 = torch.sqrt( torch.maximum(1 - Zcoef1**2 - Zcoef2**2, sq_total.new_zeros(sq_total.shape)) )
196
+
197
+ return Zcoef1 * amplitude, Zcoef2 * amplitude, Zcoef3 * amplitude, amplitude
198
+
199
+ def Zcoefs_asymp(gamma_t, delta):
200
+ A_t = (gamma_t * (1 - delta) )/4
201
+ return epxm1_x(- 2 * A_t)
202
+
203
+ class StochasticHarmonicOscillator:
204
+ """
205
+ Simulates a stochastic harmonic oscillator governed by the equations:
206
+ dy(t) = q(t) dt
207
+ dq(t) = -Γ A y(t) dt + Γ C dt + Γ D dw(t) - Γ q(t) dt
208
+
209
+ Also define v(t) = q(t) / √Γ, which is numerically more stable.
210
+
211
+ Where:
212
+ y(t) - Position variable
213
+ q(t) - Velocity variable
214
+ Γ - Damping coefficient
215
+ A - Harmonic potential strength
216
+ C - Constant force term
217
+ D - Noise amplitude
218
+ dw(t) - Wiener process (Brownian motion)
219
+ """
220
+ def __init__(self, Gamma, A, C, D):
221
+ self.Gamma = Gamma
222
+ self.A = A
223
+ self.C = C
224
+ self.D = D
225
+ self.Delta = 1 - 4 * A / Gamma
226
+ def sig11(self, gamma_t, delta):
227
+ return 1 - torch.exp(-gamma_t) + gamma_t**2 * exp_1mcosh_GD(gamma_t, delta) + exp_sinh_sqrtD(gamma_t, delta)
228
+ def sig22(self, gamma_t, delta):
229
+ return 1- zeta1(2*gamma_t, delta) + 2 * gamma_t * exp_1mcosh_GD(gamma_t, delta)
230
+ def dynamics(self, y0, v0, t):
231
+ """
232
+ Calculates the position and velocity variables at time t.
233
+
234
+ Parameters:
235
+ y0 (float): Initial position
236
+ v0 (float): Initial velocity v(0) = q(0) / √Γ
237
+ t (float): Time at which to evaluate the dynamics
238
+ Returns:
239
+ tuple: (y(t), v(t))
240
+ """
241
+
242
+ dummyzero = y0.new_zeros(1) # convert scalar to tensor with same device and dtype as y0
243
+ Delta = self.Delta + dummyzero
244
+ Gamma_hat = self.Gamma * t + dummyzero
245
+ A = self.A + dummyzero
246
+ C = self.C + dummyzero
247
+ D = self.D + dummyzero
248
+ Gamma = self.Gamma + dummyzero
249
+ zeta_1 = zeta1( Gamma_hat, Delta)
250
+ zeta_2 = zeta2( Gamma_hat, Delta)
251
+ EE = 1 - Gamma_hat * zeta_2
252
+
253
+ if v0 is None:
254
+ v0 = torch.randn_like(y0) * D / 2 ** 0.5
255
+ #v0 = (C - A * y0)/Gamma**0.5
256
+
257
+ # Calculate mean position and velocity
258
+ term1 = (1 - zeta_1) * (C * t - A * t * y0) + zeta_2 * (Gamma ** 0.5) * v0 * t
259
+ y_mean = term1 + y0
260
+ v_mean = (1 - EE)*(C - A * y0) / (Gamma ** 0.5) + (EE - A * t * (1 - zeta_1)) * v0
261
+
262
+ cov_yy = D**2 * t * self.sig22(Gamma_hat, Delta)
263
+ cov_vv = D**2 * self.sig11(Gamma_hat, Delta) / 2
264
+ cov_yv = (zeta2(Gamma_hat, Delta) * Gamma_hat * D ) **2 / 2 / (Gamma ** 0.5)
265
+
266
+ # sample new position and velocity with multivariate normal distribution
267
+
268
+ batch_shape = y0.shape
269
+ cov_matrix = torch.zeros(*batch_shape, 2, 2, device=y0.device, dtype=y0.dtype)
270
+ cov_matrix[..., 0, 0] = cov_yy
271
+ cov_matrix[..., 0, 1] = cov_yv
272
+ cov_matrix[..., 1, 0] = cov_yv # symmetric
273
+ cov_matrix[..., 1, 1] = cov_vv
274
+
275
+
276
+
277
+ # Compute the Cholesky decomposition to get scale_tril
278
+ #scale_tril = torch.linalg.cholesky(cov_matrix)
279
+ scale_tril = torch.zeros(*batch_shape, 2, 2, device=y0.device, dtype=y0.dtype)
280
+ tol = 1e-8
281
+ cov_yy = torch.clamp( cov_yy, min = tol )
282
+ sd_yy = torch.sqrt( cov_yy )
283
+ inv_sd_yy = 1/(sd_yy)
284
+
285
+ scale_tril[..., 0, 0] = sd_yy
286
+ scale_tril[..., 0, 1] = 0.
287
+ scale_tril[..., 1, 0] = cov_yv * inv_sd_yy
288
+ scale_tril[..., 1, 1] = torch.clamp( cov_vv - cov_yv**2 / cov_yy, min = tol ) ** 0.5
289
+ # check if it matches torch.linalg.
290
+ #assert torch.allclose(torch.linalg.cholesky(cov_matrix), scale_tril, atol = 1e-4, rtol = 1e-4 )
291
+ # Sample correlated noise from multivariate normal
292
+ mean = torch.zeros(*batch_shape, 2, device=y0.device, dtype=y0.dtype)
293
+ mean[..., 0] = y_mean
294
+ mean[..., 1] = v_mean
295
+ new_yv = torch.distributions.MultivariateNormal(
296
+ loc=mean,
297
+ scale_tril=scale_tril
298
+ ).sample()
299
+
300
+ return new_yv[...,0], new_yv[...,1]
LanPaint/example_workflows/Flux.2.Dev_Inpaint.jpg ADDED

Git LFS Details

  • SHA256: 2c6abff8592790ad97e096538ea2c7e370c3584feb2331619a45b3bd3e96c399
  • Pointer size: 132 Bytes
  • Size of remote file: 1.69 MB
LanPaint/example_workflows/Flux.2.Dev_Inpaint.json ADDED
@@ -0,0 +1,1886 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "7c048efb-a059-44e2-970a-43e1eb472d0d",
3
+ "revision": 0,
4
+ "last_node_id": 96,
5
+ "last_link_id": 216,
6
+ "nodes": [
7
+ {
8
+ "id": 66,
9
+ "type": "MarkdownNote",
10
+ "pos": [
11
+ -1520,
12
+ -90
13
+ ],
14
+ "size": [
15
+ 520,
16
+ 620
17
+ ],
18
+ "flags": {
19
+ "collapsed": false
20
+ },
21
+ "order": 0,
22
+ "mode": 0,
23
+ "inputs": [],
24
+ "outputs": [],
25
+ "title": "Model links",
26
+ "properties": {
27
+ "ue_properties": {
28
+ "widget_ue_connectable": {},
29
+ "version": "7.1",
30
+ "input_ue_unconnectable": {}
31
+ }
32
+ },
33
+ "widgets_values": [
34
+ "We are using quantized weights in this workflow, the original flux 2 repo is [here](https://huggingface.co/black-forest-labs/FLUX.2-dev/)\n\nGuide: [Subgraph](https://docs.comfy.org/interface/features/subgraph)\n\n## Report issue\n\nNote: please update ComfyUI first ([guide](https://docs.comfy.org/zh-CN/installation/update_comfyui)) and prepare the required models. Desktop/Cloud ship stable builds; nightly-supported models may not be included yet, please wait for the next stable release.\n\n- Cannot run / runtime errors: [ComfyUI/issues](https://github.com/comfyanonymous/ComfyUI/issues)\n- UI / frontend issues: [ComfyUI_frontend/issues](https://github.com/Comfy-Org/ComfyUI_frontend/issues)\n- Workflow issues: [workflow_templates/issues](https://github.com/Comfy-Org/workflow_templates/issues)\n\n\n## Model links (for local user)\n\n**text_encoders**\n\n- [mistral_3_small_flux2_bf16.safetensors](https://huggingface.co/Comfy-Org/flux2-dev/resolve/main/split_files/text_encoders/mistral_3_small_flux2_bf16.safetensors)\n\n**loras**\n\n- [Flux_2-Turbo-LoRA_comfyui.safetensors](https://huggingface.co/ByteZSzn/Flux.2-Turbo-ComfyUI/resolve/main/Flux_2-Turbo-LoRA_comfyui.safetensors)\n\n**diffusion_models**\n\n- [flux2_dev_fp8mixed.safetensors](https://huggingface.co/Comfy-Org/flux2-dev/resolve/main/split_files/diffusion_models/flux2_dev_fp8mixed.safetensors)\n\n**vae**\n\n- [flux2-vae.safetensors](https://huggingface.co/Comfy-Org/flux2-dev/resolve/main/split_files/vae/flux2-vae.safetensors)\n\n\nModel Storage Location\n\n```\n📂 ComfyUI/\n├── 📂 models/\n│ ├── 📂 text_encoders/\n│ │ └── mistral_3_small_flux2_bf16.safetensors\n│ ├── 📂 loras/\n│ │ └── Flux_2-Turbo-LoRA_comfyui.safetensors\n│ ├── 📂 diffusion_models/\n│ │ └── flux2_dev_fp8mixed.safetensors\n│ └── 📂 vae/\n│ └── flux2-vae.safetensors\n```\n"
35
+ ],
36
+ "color": "#432",
37
+ "bgcolor": "#000"
38
+ },
39
+ {
40
+ "id": 79,
41
+ "type": "UNETLoader",
42
+ "pos": [
43
+ -401.41628465424867,
44
+ -156.8843633555234
45
+ ],
46
+ "size": [
47
+ 298.1818181818182,
48
+ 82
49
+ ],
50
+ "flags": {},
51
+ "order": 1,
52
+ "mode": 0,
53
+ "inputs": [],
54
+ "outputs": [
55
+ {
56
+ "name": "MODEL",
57
+ "type": "MODEL",
58
+ "slot_index": 0,
59
+ "links": [
60
+ 185
61
+ ]
62
+ }
63
+ ],
64
+ "properties": {
65
+ "cnr_id": "comfy-core",
66
+ "ver": "0.3.71",
67
+ "Node name for S&R": "UNETLoader",
68
+ "models": [
69
+ {
70
+ "name": "flux2_dev_fp8mixed.safetensors",
71
+ "url": "https://huggingface.co/Comfy-Org/flux2-dev/resolve/main/split_files/diffusion_models/flux2_dev_fp8mixed.safetensors",
72
+ "directory": "diffusion_models"
73
+ },
74
+ {
75
+ "name": "flux2_dev_fp8mixed.safetensors",
76
+ "url": "https://huggingface.co/Comfy-Org/flux2-dev/resolve/main/split_files/diffusion_models/flux2_dev_fp8mixed.safetensors",
77
+ "directory": "diffusion_models"
78
+ }
79
+ ],
80
+ "enableTabs": false,
81
+ "tabWidth": 65,
82
+ "tabXOffset": 10,
83
+ "hasSecondTab": false,
84
+ "secondTabText": "Send Back",
85
+ "secondTabOffset": 80,
86
+ "secondTabWidth": 65,
87
+ "ue_properties": {
88
+ "widget_ue_connectable": {},
89
+ "version": "7.1",
90
+ "input_ue_unconnectable": {}
91
+ }
92
+ },
93
+ "widgets_values": [
94
+ "flux2_dev_fp8mixed.safetensors",
95
+ "default"
96
+ ]
97
+ },
98
+ {
99
+ "id": 81,
100
+ "type": "CLIPLoader",
101
+ "pos": [
102
+ -401.4162846542488,
103
+ -19.521307052209544
104
+ ],
105
+ "size": [
106
+ 298.1818181818182,
107
+ 106
108
+ ],
109
+ "flags": {},
110
+ "order": 2,
111
+ "mode": 0,
112
+ "inputs": [],
113
+ "outputs": [
114
+ {
115
+ "name": "CLIP",
116
+ "type": "CLIP",
117
+ "links": [
118
+ 180
119
+ ]
120
+ }
121
+ ],
122
+ "properties": {
123
+ "cnr_id": "comfy-core",
124
+ "ver": "0.3.71",
125
+ "Node name for S&R": "CLIPLoader",
126
+ "models": [
127
+ {
128
+ "name": "mistral_3_small_flux2_bf16.safetensors",
129
+ "url": "https://huggingface.co/Comfy-Org/flux2-dev/resolve/main/split_files/text_encoders/mistral_3_small_flux2_bf16.safetensors",
130
+ "directory": "text_encoders"
131
+ },
132
+ {
133
+ "name": "mistral_3_small_flux2_bf16.safetensors",
134
+ "url": "https://huggingface.co/Comfy-Org/flux2-dev/resolve/main/split_files/text_encoders/mistral_3_small_flux2_bf16.safetensors",
135
+ "directory": "text_encoders"
136
+ }
137
+ ],
138
+ "enableTabs": false,
139
+ "tabWidth": 65,
140
+ "tabXOffset": 10,
141
+ "hasSecondTab": false,
142
+ "secondTabText": "Send Back",
143
+ "secondTabOffset": 80,
144
+ "secondTabWidth": 65,
145
+ "ue_properties": {
146
+ "widget_ue_connectable": {},
147
+ "version": "7.1",
148
+ "input_ue_unconnectable": {}
149
+ }
150
+ },
151
+ "widgets_values": [
152
+ "mistral_3_small_flux2_fp8.safetensors",
153
+ "flux2",
154
+ "default"
155
+ ]
156
+ },
157
+ {
158
+ "id": 82,
159
+ "type": "RandomNoise",
160
+ "pos": [
161
+ 604.667192628257,
162
+ -167.60127519776313
163
+ ],
164
+ "size": [
165
+ 222.3482666015625,
166
+ 82
167
+ ],
168
+ "flags": {},
169
+ "order": 3,
170
+ "mode": 0,
171
+ "inputs": [],
172
+ "outputs": [
173
+ {
174
+ "name": "NOISE",
175
+ "type": "NOISE",
176
+ "links": [
177
+ 191
178
+ ]
179
+ }
180
+ ],
181
+ "properties": {
182
+ "cnr_id": "comfy-core",
183
+ "ver": "0.3.71",
184
+ "Node name for S&R": "RandomNoise",
185
+ "enableTabs": false,
186
+ "tabWidth": 65,
187
+ "tabXOffset": 10,
188
+ "hasSecondTab": false,
189
+ "secondTabText": "Send Back",
190
+ "secondTabOffset": 80,
191
+ "secondTabWidth": 65,
192
+ "ue_properties": {
193
+ "widget_ue_connectable": {},
194
+ "version": "7.1",
195
+ "input_ue_unconnectable": {}
196
+ }
197
+ },
198
+ "widgets_values": [
199
+ 221284764102256,
200
+ "randomize"
201
+ ]
202
+ },
203
+ {
204
+ "id": 83,
205
+ "type": "BasicGuider",
206
+ "pos": [
207
+ 604.667192628257,
208
+ -47.60127519776313
209
+ ],
210
+ "size": [
211
+ 222.3482666015625,
212
+ 46
213
+ ],
214
+ "flags": {},
215
+ "order": 22,
216
+ "mode": 0,
217
+ "inputs": [
218
+ {
219
+ "name": "model",
220
+ "type": "MODEL",
221
+ "link": 185
222
+ },
223
+ {
224
+ "name": "conditioning",
225
+ "type": "CONDITIONING",
226
+ "link": 184
227
+ }
228
+ ],
229
+ "outputs": [
230
+ {
231
+ "name": "GUIDER",
232
+ "type": "GUIDER",
233
+ "slot_index": 0,
234
+ "links": [
235
+ 192
236
+ ]
237
+ }
238
+ ],
239
+ "properties": {
240
+ "cnr_id": "comfy-core",
241
+ "ver": "0.3.71",
242
+ "Node name for S&R": "BasicGuider",
243
+ "enableTabs": false,
244
+ "tabWidth": 65,
245
+ "tabXOffset": 10,
246
+ "hasSecondTab": false,
247
+ "secondTabText": "Send Back",
248
+ "secondTabOffset": 80,
249
+ "secondTabWidth": 65,
250
+ "ue_properties": {
251
+ "widget_ue_connectable": {},
252
+ "version": "7.1",
253
+ "input_ue_unconnectable": {}
254
+ }
255
+ },
256
+ "widgets_values": []
257
+ },
258
+ {
259
+ "id": 84,
260
+ "type": "KSamplerSelect",
261
+ "pos": [
262
+ 604.667192628257,
263
+ 42.39872480223687
264
+ ],
265
+ "size": [
266
+ 222.3482666015625,
267
+ 58
268
+ ],
269
+ "flags": {},
270
+ "order": 4,
271
+ "mode": 0,
272
+ "inputs": [],
273
+ "outputs": [
274
+ {
275
+ "name": "SAMPLER",
276
+ "type": "SAMPLER",
277
+ "links": [
278
+ 193
279
+ ]
280
+ }
281
+ ],
282
+ "properties": {
283
+ "cnr_id": "comfy-core",
284
+ "ver": "0.3.71",
285
+ "Node name for S&R": "KSamplerSelect",
286
+ "enableTabs": false,
287
+ "tabWidth": 65,
288
+ "tabXOffset": 10,
289
+ "hasSecondTab": false,
290
+ "secondTabText": "Send Back",
291
+ "secondTabOffset": 80,
292
+ "secondTabWidth": 65,
293
+ "ue_properties": {
294
+ "widget_ue_connectable": {},
295
+ "version": "7.1",
296
+ "input_ue_unconnectable": {}
297
+ }
298
+ },
299
+ "widgets_values": [
300
+ "euler"
301
+ ]
302
+ },
303
+ {
304
+ "id": 85,
305
+ "type": "Flux2Scheduler",
306
+ "pos": [
307
+ 599.6491345888401,
308
+ 141.28360079347743
309
+ ],
310
+ "size": [
311
+ 222.3482666015625,
312
+ 106
313
+ ],
314
+ "flags": {},
315
+ "order": 14,
316
+ "mode": 0,
317
+ "inputs": [
318
+ {
319
+ "name": "width",
320
+ "type": "INT",
321
+ "widget": {
322
+ "name": "width"
323
+ },
324
+ "link": 187
325
+ },
326
+ {
327
+ "name": "height",
328
+ "type": "INT",
329
+ "widget": {
330
+ "name": "height"
331
+ },
332
+ "link": 189
333
+ }
334
+ ],
335
+ "outputs": [
336
+ {
337
+ "name": "SIGMAS",
338
+ "type": "SIGMAS",
339
+ "links": [
340
+ 194
341
+ ]
342
+ }
343
+ ],
344
+ "properties": {
345
+ "cnr_id": "comfy-core",
346
+ "ver": "0.3.71",
347
+ "Node name for S&R": "Flux2Scheduler",
348
+ "enableTabs": false,
349
+ "tabWidth": 65,
350
+ "tabXOffset": 10,
351
+ "hasSecondTab": false,
352
+ "secondTabText": "Send Back",
353
+ "secondTabOffset": 80,
354
+ "secondTabWidth": 65,
355
+ "ue_properties": {
356
+ "widget_ue_connectable": {},
357
+ "version": "7.1",
358
+ "input_ue_unconnectable": {}
359
+ }
360
+ },
361
+ "widgets_values": [
362
+ 20,
363
+ 1248,
364
+ 832
365
+ ]
366
+ },
367
+ {
368
+ "id": 78,
369
+ "type": "CLIPTextEncode",
370
+ "pos": [
371
+ 134.66719262825703,
372
+ -138.83597106805018
373
+ ],
374
+ "size": [
375
+ 430,
376
+ 200
377
+ ],
378
+ "flags": {},
379
+ "order": 7,
380
+ "mode": 0,
381
+ "inputs": [
382
+ {
383
+ "name": "clip",
384
+ "type": "CLIP",
385
+ "link": 180
386
+ }
387
+ ],
388
+ "outputs": [
389
+ {
390
+ "name": "CONDITIONING",
391
+ "type": "CONDITIONING",
392
+ "slot_index": 0,
393
+ "links": [
394
+ 176
395
+ ]
396
+ }
397
+ ],
398
+ "title": "CLIP Text Encode (Positive Prompt)",
399
+ "properties": {
400
+ "cnr_id": "comfy-core",
401
+ "ver": "0.3.71",
402
+ "Node name for S&R": "CLIPTextEncode",
403
+ "enableTabs": false,
404
+ "tabWidth": 65,
405
+ "tabXOffset": 10,
406
+ "hasSecondTab": false,
407
+ "secondTabText": "Send Back",
408
+ "secondTabOffset": 80,
409
+ "secondTabWidth": 65,
410
+ "ue_properties": {
411
+ "widget_ue_connectable": {},
412
+ "version": "7.1",
413
+ "input_ue_unconnectable": {}
414
+ }
415
+ },
416
+ "widgets_values": [
417
+ "the woman is wearing a light green dress"
418
+ ],
419
+ "color": "#232",
420
+ "bgcolor": "#353"
421
+ },
422
+ {
423
+ "id": 76,
424
+ "type": "FluxGuidance",
425
+ "pos": [
426
+ 200.2864376852714,
427
+ 104.86432229906939
428
+ ],
429
+ "size": [
430
+ 317.4000244140625,
431
+ 58
432
+ ],
433
+ "flags": {},
434
+ "order": 10,
435
+ "mode": 0,
436
+ "inputs": [
437
+ {
438
+ "name": "conditioning",
439
+ "type": "CONDITIONING",
440
+ "link": 176
441
+ }
442
+ ],
443
+ "outputs": [
444
+ {
445
+ "name": "CONDITIONING",
446
+ "type": "CONDITIONING",
447
+ "slot_index": 0,
448
+ "links": [
449
+ 177
450
+ ]
451
+ }
452
+ ],
453
+ "properties": {
454
+ "cnr_id": "comfy-core",
455
+ "ver": "0.3.71",
456
+ "Node name for S&R": "FluxGuidance",
457
+ "enableTabs": false,
458
+ "tabWidth": 65,
459
+ "tabXOffset": 10,
460
+ "hasSecondTab": false,
461
+ "secondTabText": "Send Back",
462
+ "secondTabOffset": 80,
463
+ "secondTabWidth": 65,
464
+ "ue_properties": {
465
+ "widget_ue_connectable": {},
466
+ "version": "7.1",
467
+ "input_ue_unconnectable": {}
468
+ }
469
+ },
470
+ "widgets_values": [
471
+ 4
472
+ ],
473
+ "color": "#233",
474
+ "bgcolor": "#355"
475
+ },
476
+ {
477
+ "id": 86,
478
+ "type": "EmptyFlux2LatentImage",
479
+ "pos": [
480
+ 734.667192628257,
481
+ 392.39872480223687
482
+ ],
483
+ "size": [
484
+ 270,
485
+ 106
486
+ ],
487
+ "flags": {},
488
+ "order": 15,
489
+ "mode": 0,
490
+ "inputs": [
491
+ {
492
+ "name": "width",
493
+ "type": "INT",
494
+ "widget": {
495
+ "name": "width"
496
+ },
497
+ "link": 188
498
+ },
499
+ {
500
+ "name": "height",
501
+ "type": "INT",
502
+ "widget": {
503
+ "name": "height"
504
+ },
505
+ "link": 190
506
+ }
507
+ ],
508
+ "outputs": [
509
+ {
510
+ "name": "LATENT",
511
+ "type": "LATENT",
512
+ "links": []
513
+ }
514
+ ],
515
+ "properties": {
516
+ "cnr_id": "comfy-core",
517
+ "ver": "0.3.71",
518
+ "Node name for S&R": "EmptyFlux2LatentImage",
519
+ "enableTabs": false,
520
+ "tabWidth": 65,
521
+ "tabXOffset": 10,
522
+ "hasSecondTab": false,
523
+ "secondTabText": "Send Back",
524
+ "secondTabOffset": 80,
525
+ "secondTabWidth": 65,
526
+ "ue_properties": {
527
+ "widget_ue_connectable": {},
528
+ "version": "7.1",
529
+ "input_ue_unconnectable": {}
530
+ }
531
+ },
532
+ "widgets_values": [
533
+ 1248,
534
+ 832,
535
+ 1
536
+ ]
537
+ },
538
+ {
539
+ "id": 88,
540
+ "type": "LanPaint_SamplerCustomAdvanced",
541
+ "pos": [
542
+ 1001.9202375599866,
543
+ -344.1504889090143
544
+ ],
545
+ "size": [
546
+ 400,
547
+ 568
548
+ ],
549
+ "flags": {},
550
+ "order": 23,
551
+ "mode": 0,
552
+ "inputs": [
553
+ {
554
+ "name": "noise",
555
+ "type": "NOISE",
556
+ "link": 191
557
+ },
558
+ {
559
+ "name": "guider",
560
+ "type": "GUIDER",
561
+ "link": 192
562
+ },
563
+ {
564
+ "name": "sampler",
565
+ "type": "SAMPLER",
566
+ "link": 193
567
+ },
568
+ {
569
+ "name": "sigmas",
570
+ "type": "SIGMAS",
571
+ "link": 194
572
+ },
573
+ {
574
+ "name": "latent_image",
575
+ "type": "LATENT",
576
+ "link": 205
577
+ }
578
+ ],
579
+ "outputs": [
580
+ {
581
+ "name": "output",
582
+ "type": "LATENT",
583
+ "links": [
584
+ 196
585
+ ]
586
+ },
587
+ {
588
+ "name": "denoised_output",
589
+ "type": "LATENT",
590
+ "links": []
591
+ }
592
+ ],
593
+ "properties": {
594
+ "cnr_id": "LanPaint",
595
+ "ver": "7b0d144db9aca6a4601e7c179b4c8103036e6e2b",
596
+ "Node name for S&R": "LanPaint_SamplerCustomAdvanced",
597
+ "ue_properties": {
598
+ "widget_ue_connectable": {},
599
+ "version": "7.1",
600
+ "input_ue_unconnectable": {}
601
+ }
602
+ },
603
+ "widgets_values": [
604
+ 5,
605
+ 16,
606
+ 0.15,
607
+ 1,
608
+ 15,
609
+ "Image First",
610
+ 1,
611
+ "LanPaint Custom Sampler Adv. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!",
612
+ "🖼️ Image Inpainting"
613
+ ]
614
+ },
615
+ {
616
+ "id": 9,
617
+ "type": "SaveImage",
618
+ "pos": [
619
+ 2146.7738256571624,
620
+ -100.1827620657212
621
+ ],
622
+ "size": [
623
+ 470,
624
+ 470
625
+ ],
626
+ "flags": {},
627
+ "order": 26,
628
+ "mode": 0,
629
+ "inputs": [
630
+ {
631
+ "name": "images",
632
+ "type": "IMAGE",
633
+ "link": 206
634
+ }
635
+ ],
636
+ "outputs": [],
637
+ "properties": {
638
+ "cnr_id": "comfy-core",
639
+ "ver": "0.3.71",
640
+ "Node name for S&R": "SaveImage",
641
+ "enableTabs": false,
642
+ "tabWidth": 65,
643
+ "tabXOffset": 10,
644
+ "hasSecondTab": false,
645
+ "secondTabText": "Send Back",
646
+ "secondTabOffset": 80,
647
+ "secondTabWidth": 65,
648
+ "ue_properties": {
649
+ "widget_ue_connectable": {},
650
+ "version": "7.1",
651
+ "input_ue_unconnectable": {}
652
+ }
653
+ },
654
+ "widgets_values": [
655
+ "Flux2"
656
+ ]
657
+ },
658
+ {
659
+ "id": 87,
660
+ "type": "VAEDecode",
661
+ "pos": [
662
+ 1486.9921123979855,
663
+ 399.4471845577673
664
+ ],
665
+ "size": [
666
+ 210,
667
+ 46
668
+ ],
669
+ "flags": {},
670
+ "order": 24,
671
+ "mode": 0,
672
+ "inputs": [
673
+ {
674
+ "name": "samples",
675
+ "type": "LATENT",
676
+ "link": 196
677
+ },
678
+ {
679
+ "name": "vae",
680
+ "type": "VAE",
681
+ "link": 179
682
+ }
683
+ ],
684
+ "outputs": [
685
+ {
686
+ "name": "IMAGE",
687
+ "type": "IMAGE",
688
+ "slot_index": 0,
689
+ "links": [
690
+ 203
691
+ ]
692
+ }
693
+ ],
694
+ "properties": {
695
+ "cnr_id": "comfy-core",
696
+ "ver": "0.3.71",
697
+ "Node name for S&R": "VAEDecode",
698
+ "enableTabs": false,
699
+ "tabWidth": 65,
700
+ "tabXOffset": 10,
701
+ "hasSecondTab": false,
702
+ "secondTabText": "Send Back",
703
+ "secondTabOffset": 80,
704
+ "secondTabWidth": 65,
705
+ "ue_properties": {
706
+ "widget_ue_connectable": {},
707
+ "version": "7.1",
708
+ "input_ue_unconnectable": {}
709
+ }
710
+ },
711
+ "widgets_values": []
712
+ },
713
+ {
714
+ "id": 77,
715
+ "type": "VAELoader",
716
+ "pos": [
717
+ -401.41628465424867,
718
+ 115.11563664447654
719
+ ],
720
+ "size": [
721
+ 298.1818181818182,
722
+ 60.429901123046875
723
+ ],
724
+ "flags": {},
725
+ "order": 5,
726
+ "mode": 0,
727
+ "inputs": [],
728
+ "outputs": [
729
+ {
730
+ "name": "VAE",
731
+ "type": "VAE",
732
+ "slot_index": 0,
733
+ "links": [
734
+ 179,
735
+ 181,
736
+ 207,
737
+ 210
738
+ ]
739
+ }
740
+ ],
741
+ "properties": {
742
+ "cnr_id": "comfy-core",
743
+ "ver": "0.3.71",
744
+ "Node name for S&R": "VAELoader",
745
+ "models": [
746
+ {
747
+ "name": "flux2-vae.safetensors",
748
+ "url": "https://huggingface.co/Comfy-Org/flux2-dev/resolve/main/split_files/vae/flux2-vae.safetensors",
749
+ "directory": "vae"
750
+ },
751
+ {
752
+ "name": "flux2-vae.safetensors",
753
+ "url": "https://huggingface.co/Comfy-Org/flux2-dev/resolve/main/split_files/vae/flux2-vae.safetensors",
754
+ "directory": "vae"
755
+ }
756
+ ],
757
+ "enableTabs": false,
758
+ "tabWidth": 65,
759
+ "tabXOffset": 10,
760
+ "hasSecondTab": false,
761
+ "secondTabText": "Send Back",
762
+ "secondTabOffset": 80,
763
+ "secondTabWidth": 65,
764
+ "ue_properties": {
765
+ "widget_ue_connectable": {},
766
+ "version": "7.1",
767
+ "input_ue_unconnectable": {}
768
+ }
769
+ },
770
+ "widgets_values": [
771
+ "flux2-vae.safetensors"
772
+ ]
773
+ },
774
+ {
775
+ "id": 89,
776
+ "type": "ReferenceLatent",
777
+ "pos": [
778
+ 182.88585037431145,
779
+ 261.7022748558416
780
+ ],
781
+ "size": [
782
+ 204.134765625,
783
+ 46
784
+ ],
785
+ "flags": {},
786
+ "order": 21,
787
+ "mode": 4,
788
+ "inputs": [
789
+ {
790
+ "name": "conditioning",
791
+ "type": "CONDITIONING",
792
+ "link": 177
793
+ },
794
+ {
795
+ "name": "latent",
796
+ "shape": 7,
797
+ "type": "LATENT",
798
+ "link": 201
799
+ }
800
+ ],
801
+ "outputs": [
802
+ {
803
+ "name": "CONDITIONING",
804
+ "type": "CONDITIONING",
805
+ "links": [
806
+ 184
807
+ ]
808
+ }
809
+ ],
810
+ "properties": {
811
+ "cnr_id": "comfy-core",
812
+ "ver": "0.3.71",
813
+ "Node name for S&R": "ReferenceLatent",
814
+ "enableTabs": false,
815
+ "tabWidth": 65,
816
+ "tabXOffset": 10,
817
+ "hasSecondTab": false,
818
+ "secondTabText": "Send Back",
819
+ "secondTabOffset": 80,
820
+ "secondTabWidth": 65,
821
+ "ue_properties": {
822
+ "widget_ue_connectable": {},
823
+ "version": "7.1",
824
+ "input_ue_unconnectable": {}
825
+ }
826
+ },
827
+ "widgets_values": []
828
+ },
829
+ {
830
+ "id": 93,
831
+ "type": "LanPaint_MaskBlend",
832
+ "pos": [
833
+ 1918.4282656529942,
834
+ -298.1303483829989
835
+ ],
836
+ "size": [
837
+ 270,
838
+ 98
839
+ ],
840
+ "flags": {},
841
+ "order": 25,
842
+ "mode": 0,
843
+ "inputs": [
844
+ {
845
+ "name": "image1",
846
+ "type": "IMAGE",
847
+ "link": 216
848
+ },
849
+ {
850
+ "name": "image2",
851
+ "type": "IMAGE",
852
+ "link": 203
853
+ },
854
+ {
855
+ "name": "mask",
856
+ "type": "MASK",
857
+ "link": 202
858
+ }
859
+ ],
860
+ "outputs": [
861
+ {
862
+ "name": "IMAGE",
863
+ "type": "IMAGE",
864
+ "links": [
865
+ 206
866
+ ]
867
+ }
868
+ ],
869
+ "properties": {
870
+ "cnr_id": "LanPaint",
871
+ "ver": "7b0d144db9aca6a4601e7c179b4c8103036e6e2b",
872
+ "Node name for S&R": "LanPaint_MaskBlend",
873
+ "ue_properties": {
874
+ "widget_ue_connectable": {
875
+ "blend_overlap": true
876
+ },
877
+ "version": "7.1",
878
+ "input_ue_unconnectable": {}
879
+ }
880
+ },
881
+ "widgets_values": [
882
+ 9
883
+ ]
884
+ },
885
+ {
886
+ "id": 45,
887
+ "type": "ImageScaleToTotalPixels",
888
+ "pos": [
889
+ -942.2953950329953,
890
+ 300.7707910339225
891
+ ],
892
+ "size": [
893
+ 270,
894
+ 106
895
+ ],
896
+ "flags": {},
897
+ "order": 8,
898
+ "mode": 0,
899
+ "inputs": [
900
+ {
901
+ "name": "image",
902
+ "type": "IMAGE",
903
+ "link": 128
904
+ }
905
+ ],
906
+ "outputs": [
907
+ {
908
+ "name": "IMAGE",
909
+ "type": "IMAGE",
910
+ "links": [
911
+ 208,
912
+ 214
913
+ ]
914
+ }
915
+ ],
916
+ "properties": {
917
+ "cnr_id": "comfy-core",
918
+ "ver": "0.3.71",
919
+ "Node name for S&R": "ImageScaleToTotalPixels",
920
+ "enableTabs": false,
921
+ "tabWidth": 65,
922
+ "tabXOffset": 10,
923
+ "hasSecondTab": false,
924
+ "secondTabText": "Send Back",
925
+ "secondTabOffset": 80,
926
+ "secondTabWidth": 65,
927
+ "ue_properties": {
928
+ "widget_ue_connectable": {},
929
+ "version": "7.1",
930
+ "input_ue_unconnectable": {}
931
+ }
932
+ },
933
+ "widgets_values": [
934
+ "lanczos",
935
+ 1,
936
+ 1
937
+ ]
938
+ },
939
+ {
940
+ "id": 94,
941
+ "type": "VAEEncode",
942
+ "pos": [
943
+ -904.8642154697659,
944
+ 545.7584311148781
945
+ ],
946
+ "size": [
947
+ 140,
948
+ 46
949
+ ],
950
+ "flags": {
951
+ "collapsed": true
952
+ },
953
+ "order": 11,
954
+ "mode": 0,
955
+ "inputs": [
956
+ {
957
+ "name": "pixels",
958
+ "type": "IMAGE",
959
+ "link": 208
960
+ },
961
+ {
962
+ "name": "vae",
963
+ "type": "VAE",
964
+ "link": 207
965
+ }
966
+ ],
967
+ "outputs": [
968
+ {
969
+ "name": "LATENT",
970
+ "type": "LATENT",
971
+ "links": [
972
+ 209
973
+ ]
974
+ }
975
+ ],
976
+ "properties": {
977
+ "cnr_id": "comfy-core",
978
+ "ver": "0.3.71",
979
+ "Node name for S&R": "VAEEncode",
980
+ "enableTabs": false,
981
+ "tabWidth": 65,
982
+ "tabXOffset": 10,
983
+ "hasSecondTab": false,
984
+ "secondTabText": "Send Back",
985
+ "secondTabOffset": 80,
986
+ "secondTabWidth": 65,
987
+ "ue_properties": {
988
+ "widget_ue_connectable": {},
989
+ "version": "7.1",
990
+ "input_ue_unconnectable": {}
991
+ }
992
+ },
993
+ "widgets_values": []
994
+ },
995
+ {
996
+ "id": 95,
997
+ "type": "VAEDecode",
998
+ "pos": [
999
+ -922.5241424443258,
1000
+ 609.877550591736
1001
+ ],
1002
+ "size": [
1003
+ 210,
1004
+ 46
1005
+ ],
1006
+ "flags": {},
1007
+ "order": 12,
1008
+ "mode": 0,
1009
+ "inputs": [
1010
+ {
1011
+ "name": "samples",
1012
+ "type": "LATENT",
1013
+ "link": 209
1014
+ },
1015
+ {
1016
+ "name": "vae",
1017
+ "type": "VAE",
1018
+ "link": 210
1019
+ }
1020
+ ],
1021
+ "outputs": [
1022
+ {
1023
+ "name": "IMAGE",
1024
+ "type": "IMAGE",
1025
+ "slot_index": 0,
1026
+ "links": [
1027
+ 211
1028
+ ]
1029
+ }
1030
+ ],
1031
+ "properties": {
1032
+ "cnr_id": "comfy-core",
1033
+ "ver": "0.3.71",
1034
+ "Node name for S&R": "VAEDecode",
1035
+ "enableTabs": false,
1036
+ "tabWidth": 65,
1037
+ "tabXOffset": 10,
1038
+ "hasSecondTab": false,
1039
+ "secondTabText": "Send Back",
1040
+ "secondTabOffset": 80,
1041
+ "secondTabWidth": 65,
1042
+ "ue_properties": {
1043
+ "widget_ue_connectable": {},
1044
+ "version": "7.1",
1045
+ "input_ue_unconnectable": {}
1046
+ }
1047
+ },
1048
+ "widgets_values": []
1049
+ },
1050
+ {
1051
+ "id": 90,
1052
+ "type": "GetImageSize",
1053
+ "pos": [
1054
+ -914.6494032834313,
1055
+ 736.2708355567737
1056
+ ],
1057
+ "size": [
1058
+ 140,
1059
+ 124
1060
+ ],
1061
+ "flags": {},
1062
+ "order": 13,
1063
+ "mode": 0,
1064
+ "inputs": [
1065
+ {
1066
+ "name": "image",
1067
+ "type": "IMAGE",
1068
+ "link": 211
1069
+ }
1070
+ ],
1071
+ "outputs": [
1072
+ {
1073
+ "name": "width",
1074
+ "type": "INT",
1075
+ "links": [
1076
+ 187,
1077
+ 188,
1078
+ 197,
1079
+ 212
1080
+ ]
1081
+ },
1082
+ {
1083
+ "name": "height",
1084
+ "type": "INT",
1085
+ "links": [
1086
+ 189,
1087
+ 190,
1088
+ 198,
1089
+ 213
1090
+ ]
1091
+ },
1092
+ {
1093
+ "name": "batch_size",
1094
+ "type": "INT",
1095
+ "links": []
1096
+ }
1097
+ ],
1098
+ "properties": {
1099
+ "cnr_id": "comfy-core",
1100
+ "ver": "0.7.0",
1101
+ "Node name for S&R": "GetImageSize",
1102
+ "enableTabs": false,
1103
+ "tabWidth": 65,
1104
+ "tabXOffset": 10,
1105
+ "hasSecondTab": false,
1106
+ "secondTabText": "Send Back",
1107
+ "secondTabOffset": 80,
1108
+ "secondTabWidth": 65,
1109
+ "ue_properties": {
1110
+ "widget_ue_connectable": {},
1111
+ "version": "7.1",
1112
+ "input_ue_unconnectable": {}
1113
+ }
1114
+ },
1115
+ "widgets_values": [
1116
+ "width: 1024, height: 1024\n batch size: 1"
1117
+ ]
1118
+ },
1119
+ {
1120
+ "id": 91,
1121
+ "type": "VAEEncode",
1122
+ "pos": [
1123
+ -256.8351358960004,
1124
+ 471.2386874112704
1125
+ ],
1126
+ "size": [
1127
+ 140,
1128
+ 46
1129
+ ],
1130
+ "flags": {
1131
+ "collapsed": true
1132
+ },
1133
+ "order": 19,
1134
+ "mode": 0,
1135
+ "inputs": [
1136
+ {
1137
+ "name": "pixels",
1138
+ "type": "IMAGE",
1139
+ "link": 215
1140
+ },
1141
+ {
1142
+ "name": "vae",
1143
+ "type": "VAE",
1144
+ "link": 181
1145
+ }
1146
+ ],
1147
+ "outputs": [
1148
+ {
1149
+ "name": "LATENT",
1150
+ "type": "LATENT",
1151
+ "links": [
1152
+ 200
1153
+ ]
1154
+ }
1155
+ ],
1156
+ "properties": {
1157
+ "cnr_id": "comfy-core",
1158
+ "ver": "0.3.71",
1159
+ "Node name for S&R": "VAEEncode",
1160
+ "enableTabs": false,
1161
+ "tabWidth": 65,
1162
+ "tabXOffset": 10,
1163
+ "hasSecondTab": false,
1164
+ "secondTabText": "Send Back",
1165
+ "secondTabOffset": 80,
1166
+ "secondTabWidth": 65,
1167
+ "ue_properties": {
1168
+ "widget_ue_connectable": {},
1169
+ "version": "7.1",
1170
+ "input_ue_unconnectable": {}
1171
+ }
1172
+ },
1173
+ "widgets_values": []
1174
+ },
1175
+ {
1176
+ "id": 96,
1177
+ "type": "ImageScale",
1178
+ "pos": [
1179
+ -541.9051701853617,
1180
+ 509.13038411372514
1181
+ ],
1182
+ "size": [
1183
+ 269.921875,
1184
+ 152.8125
1185
+ ],
1186
+ "flags": {},
1187
+ "order": 17,
1188
+ "mode": 0,
1189
+ "inputs": [
1190
+ {
1191
+ "name": "image",
1192
+ "type": "IMAGE",
1193
+ "link": 214
1194
+ },
1195
+ {
1196
+ "name": "width",
1197
+ "type": "INT",
1198
+ "widget": {
1199
+ "name": "width"
1200
+ },
1201
+ "link": 212
1202
+ },
1203
+ {
1204
+ "name": "height",
1205
+ "type": "INT",
1206
+ "widget": {
1207
+ "name": "height"
1208
+ },
1209
+ "link": 213
1210
+ }
1211
+ ],
1212
+ "outputs": [
1213
+ {
1214
+ "name": "IMAGE",
1215
+ "type": "IMAGE",
1216
+ "links": [
1217
+ 215,
1218
+ 216
1219
+ ]
1220
+ }
1221
+ ],
1222
+ "properties": {
1223
+ "cnr_id": "comfy-core",
1224
+ "ver": "0.3.52",
1225
+ "Node name for S&R": "ImageScale",
1226
+ "ue_properties": {
1227
+ "widget_ue_connectable": {
1228
+ "width": true,
1229
+ "height": true
1230
+ },
1231
+ "version": "7.1",
1232
+ "input_ue_unconnectable": {}
1233
+ }
1234
+ },
1235
+ "widgets_values": [
1236
+ "area",
1237
+ 512,
1238
+ 512,
1239
+ "center"
1240
+ ]
1241
+ },
1242
+ {
1243
+ "id": 92,
1244
+ "type": "SetLatentNoiseMask",
1245
+ "pos": [
1246
+ -47.37803371329864,
1247
+ 552.1340734941332
1248
+ ],
1249
+ "size": [
1250
+ 188.1373046875,
1251
+ 46
1252
+ ],
1253
+ "flags": {},
1254
+ "order": 20,
1255
+ "mode": 0,
1256
+ "inputs": [
1257
+ {
1258
+ "name": "samples",
1259
+ "type": "LATENT",
1260
+ "link": 200
1261
+ },
1262
+ {
1263
+ "name": "mask",
1264
+ "type": "MASK",
1265
+ "link": 199
1266
+ }
1267
+ ],
1268
+ "outputs": [
1269
+ {
1270
+ "name": "LATENT",
1271
+ "type": "LATENT",
1272
+ "links": [
1273
+ 201,
1274
+ 205
1275
+ ]
1276
+ }
1277
+ ],
1278
+ "properties": {
1279
+ "cnr_id": "comfy-core",
1280
+ "ver": "0.3.51",
1281
+ "Node name for S&R": "SetLatentNoiseMask",
1282
+ "ue_properties": {
1283
+ "widget_ue_connectable": {},
1284
+ "version": "7.1",
1285
+ "input_ue_unconnectable": {}
1286
+ }
1287
+ },
1288
+ "widgets_values": []
1289
+ },
1290
+ {
1291
+ "id": 73,
1292
+ "type": "MaskToImage",
1293
+ "pos": [
1294
+ -514.7896658923698,
1295
+ 909.9351737467276
1296
+ ],
1297
+ "size": [
1298
+ 193.2779296875,
1299
+ 26
1300
+ ],
1301
+ "flags": {},
1302
+ "order": 9,
1303
+ "mode": 0,
1304
+ "inputs": [
1305
+ {
1306
+ "name": "mask",
1307
+ "type": "MASK",
1308
+ "link": 173
1309
+ }
1310
+ ],
1311
+ "outputs": [
1312
+ {
1313
+ "name": "IMAGE",
1314
+ "type": "IMAGE",
1315
+ "links": [
1316
+ 174
1317
+ ]
1318
+ }
1319
+ ],
1320
+ "properties": {
1321
+ "cnr_id": "comfy-core",
1322
+ "ver": "0.3.51",
1323
+ "Node name for S&R": "MaskToImage",
1324
+ "ue_properties": {
1325
+ "widget_ue_connectable": {},
1326
+ "version": "7.1",
1327
+ "input_ue_unconnectable": {}
1328
+ }
1329
+ },
1330
+ "widgets_values": []
1331
+ },
1332
+ {
1333
+ "id": 74,
1334
+ "type": "ImageScale",
1335
+ "pos": [
1336
+ -559.3815806117882,
1337
+ 1005.5195473781431
1338
+ ],
1339
+ "size": [
1340
+ 270,
1341
+ 130
1342
+ ],
1343
+ "flags": {},
1344
+ "order": 16,
1345
+ "mode": 0,
1346
+ "inputs": [
1347
+ {
1348
+ "name": "image",
1349
+ "type": "IMAGE",
1350
+ "link": 174
1351
+ },
1352
+ {
1353
+ "name": "width",
1354
+ "type": "INT",
1355
+ "widget": {
1356
+ "name": "width"
1357
+ },
1358
+ "link": 197
1359
+ },
1360
+ {
1361
+ "name": "height",
1362
+ "type": "INT",
1363
+ "widget": {
1364
+ "name": "height"
1365
+ },
1366
+ "link": 198
1367
+ }
1368
+ ],
1369
+ "outputs": [
1370
+ {
1371
+ "name": "IMAGE",
1372
+ "type": "IMAGE",
1373
+ "links": [
1374
+ 175
1375
+ ]
1376
+ }
1377
+ ],
1378
+ "properties": {
1379
+ "cnr_id": "comfy-core",
1380
+ "ver": "0.3.52",
1381
+ "Node name for S&R": "ImageScale",
1382
+ "ue_properties": {
1383
+ "widget_ue_connectable": {
1384
+ "width": true,
1385
+ "height": true
1386
+ },
1387
+ "version": "7.1",
1388
+ "input_ue_unconnectable": {}
1389
+ }
1390
+ },
1391
+ "widgets_values": [
1392
+ "nearest-exact",
1393
+ 512,
1394
+ 512,
1395
+ "center"
1396
+ ]
1397
+ },
1398
+ {
1399
+ "id": 75,
1400
+ "type": "ImageToMask",
1401
+ "pos": [
1402
+ -556.7866782788742,
1403
+ 1200.3106983669886
1404
+ ],
1405
+ "size": [
1406
+ 270,
1407
+ 58
1408
+ ],
1409
+ "flags": {},
1410
+ "order": 18,
1411
+ "mode": 0,
1412
+ "inputs": [
1413
+ {
1414
+ "name": "image",
1415
+ "type": "IMAGE",
1416
+ "link": 175
1417
+ }
1418
+ ],
1419
+ "outputs": [
1420
+ {
1421
+ "name": "MASK",
1422
+ "type": "MASK",
1423
+ "links": [
1424
+ 199,
1425
+ 202
1426
+ ]
1427
+ }
1428
+ ],
1429
+ "properties": {
1430
+ "cnr_id": "comfy-core",
1431
+ "ver": "0.3.51",
1432
+ "Node name for S&R": "ImageToMask",
1433
+ "ue_properties": {
1434
+ "widget_ue_connectable": {},
1435
+ "version": "7.1",
1436
+ "input_ue_unconnectable": {}
1437
+ }
1438
+ },
1439
+ "widgets_values": [
1440
+ "red"
1441
+ ]
1442
+ },
1443
+ {
1444
+ "id": 46,
1445
+ "type": "LoadImage",
1446
+ "pos": [
1447
+ -960,
1448
+ -90
1449
+ ],
1450
+ "size": [
1451
+ 274.080078125,
1452
+ 314
1453
+ ],
1454
+ "flags": {},
1455
+ "order": 6,
1456
+ "mode": 0,
1457
+ "inputs": [],
1458
+ "outputs": [
1459
+ {
1460
+ "name": "IMAGE",
1461
+ "type": "IMAGE",
1462
+ "links": [
1463
+ 128
1464
+ ]
1465
+ },
1466
+ {
1467
+ "name": "MASK",
1468
+ "type": "MASK",
1469
+ "links": [
1470
+ 173
1471
+ ]
1472
+ }
1473
+ ],
1474
+ "properties": {
1475
+ "cnr_id": "comfy-core",
1476
+ "ver": "0.3.71",
1477
+ "Node name for S&R": "LoadImage",
1478
+ "enableTabs": false,
1479
+ "tabWidth": 65,
1480
+ "tabXOffset": 10,
1481
+ "hasSecondTab": false,
1482
+ "secondTabText": "Send Back",
1483
+ "secondTabOffset": 80,
1484
+ "secondTabWidth": 65,
1485
+ "ue_properties": {
1486
+ "widget_ue_connectable": {},
1487
+ "version": "7.1",
1488
+ "input_ue_unconnectable": {}
1489
+ },
1490
+ "image": "clipspace/clipspace-painted-masked-1768018054791.png [input]"
1491
+ },
1492
+ "widgets_values": [
1493
+ "inpaint_1768016968051.png",
1494
+ "image"
1495
+ ]
1496
+ }
1497
+ ],
1498
+ "links": [
1499
+ [
1500
+ 128,
1501
+ 46,
1502
+ 0,
1503
+ 45,
1504
+ 0,
1505
+ "IMAGE"
1506
+ ],
1507
+ [
1508
+ 173,
1509
+ 46,
1510
+ 1,
1511
+ 73,
1512
+ 0,
1513
+ "MASK"
1514
+ ],
1515
+ [
1516
+ 174,
1517
+ 73,
1518
+ 0,
1519
+ 74,
1520
+ 0,
1521
+ "IMAGE"
1522
+ ],
1523
+ [
1524
+ 175,
1525
+ 74,
1526
+ 0,
1527
+ 75,
1528
+ 0,
1529
+ "IMAGE"
1530
+ ],
1531
+ [
1532
+ 176,
1533
+ 78,
1534
+ 0,
1535
+ 76,
1536
+ 0,
1537
+ "CONDITIONING"
1538
+ ],
1539
+ [
1540
+ 177,
1541
+ 76,
1542
+ 0,
1543
+ 89,
1544
+ 0,
1545
+ "CONDITIONING"
1546
+ ],
1547
+ [
1548
+ 179,
1549
+ 77,
1550
+ 0,
1551
+ 87,
1552
+ 1,
1553
+ "VAE"
1554
+ ],
1555
+ [
1556
+ 180,
1557
+ 81,
1558
+ 0,
1559
+ 78,
1560
+ 0,
1561
+ "CLIP"
1562
+ ],
1563
+ [
1564
+ 181,
1565
+ 77,
1566
+ 0,
1567
+ 91,
1568
+ 1,
1569
+ "VAE"
1570
+ ],
1571
+ [
1572
+ 184,
1573
+ 89,
1574
+ 0,
1575
+ 83,
1576
+ 1,
1577
+ "CONDITIONING"
1578
+ ],
1579
+ [
1580
+ 185,
1581
+ 79,
1582
+ 0,
1583
+ 83,
1584
+ 0,
1585
+ "MODEL"
1586
+ ],
1587
+ [
1588
+ 187,
1589
+ 90,
1590
+ 0,
1591
+ 85,
1592
+ 0,
1593
+ "INT"
1594
+ ],
1595
+ [
1596
+ 188,
1597
+ 90,
1598
+ 0,
1599
+ 86,
1600
+ 0,
1601
+ "INT"
1602
+ ],
1603
+ [
1604
+ 189,
1605
+ 90,
1606
+ 1,
1607
+ 85,
1608
+ 1,
1609
+ "INT"
1610
+ ],
1611
+ [
1612
+ 190,
1613
+ 90,
1614
+ 1,
1615
+ 86,
1616
+ 1,
1617
+ "INT"
1618
+ ],
1619
+ [
1620
+ 191,
1621
+ 82,
1622
+ 0,
1623
+ 88,
1624
+ 0,
1625
+ "NOISE"
1626
+ ],
1627
+ [
1628
+ 192,
1629
+ 83,
1630
+ 0,
1631
+ 88,
1632
+ 1,
1633
+ "GUIDER"
1634
+ ],
1635
+ [
1636
+ 193,
1637
+ 84,
1638
+ 0,
1639
+ 88,
1640
+ 2,
1641
+ "SAMPLER"
1642
+ ],
1643
+ [
1644
+ 194,
1645
+ 85,
1646
+ 0,
1647
+ 88,
1648
+ 3,
1649
+ "SIGMAS"
1650
+ ],
1651
+ [
1652
+ 196,
1653
+ 88,
1654
+ 0,
1655
+ 87,
1656
+ 0,
1657
+ "LATENT"
1658
+ ],
1659
+ [
1660
+ 197,
1661
+ 90,
1662
+ 0,
1663
+ 74,
1664
+ 1,
1665
+ "INT"
1666
+ ],
1667
+ [
1668
+ 198,
1669
+ 90,
1670
+ 1,
1671
+ 74,
1672
+ 2,
1673
+ "INT"
1674
+ ],
1675
+ [
1676
+ 199,
1677
+ 75,
1678
+ 0,
1679
+ 92,
1680
+ 1,
1681
+ "MASK"
1682
+ ],
1683
+ [
1684
+ 200,
1685
+ 91,
1686
+ 0,
1687
+ 92,
1688
+ 0,
1689
+ "LATENT"
1690
+ ],
1691
+ [
1692
+ 201,
1693
+ 92,
1694
+ 0,
1695
+ 89,
1696
+ 1,
1697
+ "LATENT"
1698
+ ],
1699
+ [
1700
+ 202,
1701
+ 75,
1702
+ 0,
1703
+ 93,
1704
+ 2,
1705
+ "MASK"
1706
+ ],
1707
+ [
1708
+ 203,
1709
+ 87,
1710
+ 0,
1711
+ 93,
1712
+ 1,
1713
+ "IMAGE"
1714
+ ],
1715
+ [
1716
+ 205,
1717
+ 92,
1718
+ 0,
1719
+ 88,
1720
+ 4,
1721
+ "LATENT"
1722
+ ],
1723
+ [
1724
+ 206,
1725
+ 93,
1726
+ 0,
1727
+ 9,
1728
+ 0,
1729
+ "IMAGE"
1730
+ ],
1731
+ [
1732
+ 207,
1733
+ 77,
1734
+ 0,
1735
+ 94,
1736
+ 1,
1737
+ "VAE"
1738
+ ],
1739
+ [
1740
+ 208,
1741
+ 45,
1742
+ 0,
1743
+ 94,
1744
+ 0,
1745
+ "IMAGE"
1746
+ ],
1747
+ [
1748
+ 209,
1749
+ 94,
1750
+ 0,
1751
+ 95,
1752
+ 0,
1753
+ "LATENT"
1754
+ ],
1755
+ [
1756
+ 210,
1757
+ 77,
1758
+ 0,
1759
+ 95,
1760
+ 1,
1761
+ "VAE"
1762
+ ],
1763
+ [
1764
+ 211,
1765
+ 95,
1766
+ 0,
1767
+ 90,
1768
+ 0,
1769
+ "IMAGE"
1770
+ ],
1771
+ [
1772
+ 212,
1773
+ 90,
1774
+ 0,
1775
+ 96,
1776
+ 1,
1777
+ "INT"
1778
+ ],
1779
+ [
1780
+ 213,
1781
+ 90,
1782
+ 1,
1783
+ 96,
1784
+ 2,
1785
+ "INT"
1786
+ ],
1787
+ [
1788
+ 214,
1789
+ 45,
1790
+ 0,
1791
+ 96,
1792
+ 0,
1793
+ "IMAGE"
1794
+ ],
1795
+ [
1796
+ 215,
1797
+ 96,
1798
+ 0,
1799
+ 91,
1800
+ 0,
1801
+ "IMAGE"
1802
+ ],
1803
+ [
1804
+ 216,
1805
+ 96,
1806
+ 0,
1807
+ 93,
1808
+ 0,
1809
+ "IMAGE"
1810
+ ]
1811
+ ],
1812
+ "groups": [
1813
+ {
1814
+ "id": 1,
1815
+ "title": "Models",
1816
+ "bounding": [
1817
+ -408.2335481707614,
1818
+ -234.8843633555234,
1819
+ 318.18181818181813,
1820
+ 416.0299011230469
1821
+ ],
1822
+ "color": "#3f789e",
1823
+ "font_size": 24,
1824
+ "flags": {}
1825
+ },
1826
+ {
1827
+ "id": 2,
1828
+ "title": "Custom sampler",
1829
+ "bounding": [
1830
+ 594.667192628257,
1831
+ -237.60127519776313,
1832
+ 558.5359191894531,
1833
+ 501.6
1834
+ ],
1835
+ "color": "#3f789e",
1836
+ "font_size": 24,
1837
+ "flags": {}
1838
+ },
1839
+ {
1840
+ "id": 3,
1841
+ "title": "Image size",
1842
+ "bounding": [
1843
+ 594.667192628257,
1844
+ 282.39872480223687,
1845
+ 560,
1846
+ 285.6
1847
+ ],
1848
+ "color": "#3f789e",
1849
+ "font_size": 24,
1850
+ "flags": {}
1851
+ },
1852
+ {
1853
+ "id": 4,
1854
+ "title": "Prompt",
1855
+ "bounding": [
1856
+ 124.667192628257,
1857
+ -237.60127519776313,
1858
+ 450,
1859
+ 420
1860
+ ],
1861
+ "color": "#3f789e",
1862
+ "font_size": 24,
1863
+ "flags": {}
1864
+ }
1865
+ ],
1866
+ "config": {},
1867
+ "extra": {
1868
+ "frontendVersion": "1.35.9",
1869
+ "workflowRendererVersion": "LG",
1870
+ "groupNodes": {},
1871
+ "VHS_latentpreview": false,
1872
+ "VHS_latentpreviewrate": 0,
1873
+ "VHS_MetadataImage": true,
1874
+ "VHS_KeepIntermediate": true,
1875
+ "ue_links": [],
1876
+ "links_added_by_ue": [],
1877
+ "ds": {
1878
+ "scale": 0.5530652774381023,
1879
+ "offset": [
1880
+ 394.2039301836752,
1881
+ 627.2932212537274
1882
+ ]
1883
+ }
1884
+ },
1885
+ "version": 0.4
1886
+ }
LanPaint/example_workflows/Flux2_Klein_inpainting.jpg ADDED

Git LFS Details

  • SHA256: 214b4ab8a7e830b2555173d7effcbe647dabfcd70c5cb2d76a87b758a8fcaeea
  • Pointer size: 132 Bytes
  • Size of remote file: 1.67 MB
LanPaint/example_workflows/Flux2_Klein_inpainting.json ADDED
@@ -0,0 +1,2665 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "92112d97-bb64-4b44-86f2-ea5691ef8f6e",
3
+ "revision": 0,
4
+ "last_node_id": 141,
5
+ "last_link_id": 252,
6
+ "nodes": [
7
+ {
8
+ "id": 99,
9
+ "type": "MarkdownNote",
10
+ "pos": [
11
+ 500,
12
+ 680
13
+ ],
14
+ "size": [
15
+ 210,
16
+ 88
17
+ ],
18
+ "flags": {},
19
+ "order": 0,
20
+ "mode": 0,
21
+ "inputs": [],
22
+ "outputs": [],
23
+ "title": "Note",
24
+ "properties": {
25
+ "ue_properties": {
26
+ "widget_ue_connectable": {},
27
+ "version": "7.1",
28
+ "input_ue_unconnectable": {}
29
+ }
30
+ },
31
+ "widgets_values": [
32
+ "Click on the top-right corner of the node to open the [subgraph](https://docs.comfy.org/interface/features/subgraph) \n👇"
33
+ ],
34
+ "color": "#222",
35
+ "bgcolor": "#000"
36
+ },
37
+ {
38
+ "id": 97,
39
+ "type": "MarkdownNote",
40
+ "pos": [
41
+ -1257.789968845821,
42
+ 803.5275371691753
43
+ ],
44
+ "size": [
45
+ 610,
46
+ 650
47
+ ],
48
+ "flags": {},
49
+ "order": 1,
50
+ "mode": 0,
51
+ "inputs": [],
52
+ "outputs": [],
53
+ "properties": {
54
+ "ue_properties": {
55
+ "widget_ue_connectable": {},
56
+ "version": "7.1",
57
+ "input_ue_unconnectable": {}
58
+ }
59
+ },
60
+ "widgets_values": [
61
+ "Guide: [Subgraph](https://docs.comfy.org/interface/features/subgraph)\n\n## Model links (for local users)\n\n**text_encoders**\n\n- [qwen_3_4b.safetensors](https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/text_encoders/qwen_3_4b.safetensors)\n\n**diffusion_models**\n\n- [lux-2-klein-base-4b-fp8.safetensors](https://huggingface.co/black-forest-labs/FLUX.2-klein-base-4b-fp8/resolve/main/flux-2-klein-base-4b-fp8.safetensors)\n\n**vae**\n\n- [flux2-vae.safetensors](https://huggingface.co/Comfy-Org/flux2-dev/resolve/main/split_files/vae/flux2-vae.safetensors)\n\n\nModel Storage Location\n\n```\n📂 ComfyUI/\n├── 📂 models/\n│ ├── 📂 text_encoders/\n│ │ └── qwen_3_4b.safetensors\n│ ├── 📂 diffusion_models/\n│ │ └── lux-2-klein-base-4b-fp8.safetensors\n│ └── 📂 vae/\n│ └── flux2-vae.safetensors\n```\n\n## Report issue\n\nNote: please update ComfyUI first ([guide](https://docs.comfy.org/zh-CN/installation/update_comfyui)) and prepare the required models. Desktop/Cloud ship stable builds; nightly-supported models may not be included yet, please wait for the next stable release.\n\n- Cannot run / runtime errors: [ComfyUI/issues](https://github.com/comfyanonymous/ComfyUI/issues)\n- UI / frontend issues: [ComfyUI_frontend/issues](https://github.com/Comfy-Org/ComfyUI_frontend/issues)\n- Workflow issues: [workflow_templates/issues](https://github.com/Comfy-Org/workflow_templates/issues)\n\n"
62
+ ],
63
+ "color": "#222",
64
+ "bgcolor": "#000"
65
+ },
66
+ {
67
+ "id": 112,
68
+ "type": "CLIPTextEncode",
69
+ "pos": [
70
+ 361.4681372990097,
71
+ 1043.0187170159304
72
+ ],
73
+ "size": [
74
+ 430,
75
+ 88
76
+ ],
77
+ "flags": {},
78
+ "order": 9,
79
+ "mode": 0,
80
+ "inputs": [
81
+ {
82
+ "name": "clip",
83
+ "type": "CLIP",
84
+ "link": 191
85
+ }
86
+ ],
87
+ "outputs": [
88
+ {
89
+ "name": "CONDITIONING",
90
+ "type": "CONDITIONING",
91
+ "slot_index": 0,
92
+ "links": [
93
+ 195
94
+ ]
95
+ }
96
+ ],
97
+ "title": "CLIP Text Encode (Negative Prompt)",
98
+ "properties": {
99
+ "Node name for S&R": "CLIPTextEncode",
100
+ "cnr_id": "comfy-core",
101
+ "ver": "0.8.2",
102
+ "enableTabs": false,
103
+ "tabWidth": 65,
104
+ "tabXOffset": 10,
105
+ "hasSecondTab": false,
106
+ "secondTabText": "Send Back",
107
+ "secondTabOffset": 80,
108
+ "secondTabWidth": 65,
109
+ "ue_properties": {
110
+ "widget_ue_connectable": {},
111
+ "version": "7.1",
112
+ "input_ue_unconnectable": {}
113
+ }
114
+ },
115
+ "widgets_values": [
116
+ ""
117
+ ],
118
+ "color": "#322",
119
+ "bgcolor": "#533"
120
+ },
121
+ {
122
+ "id": 113,
123
+ "type": "VAELoader",
124
+ "pos": [
125
+ -68.53186060598445,
126
+ 1032.8521075621834
127
+ ],
128
+ "size": [
129
+ 364.42708333333337,
130
+ 58
131
+ ],
132
+ "flags": {},
133
+ "order": 2,
134
+ "mode": 0,
135
+ "inputs": [],
136
+ "outputs": [
137
+ {
138
+ "name": "VAE",
139
+ "type": "VAE",
140
+ "links": [
141
+ 190,
142
+ 205,
143
+ 234
144
+ ]
145
+ }
146
+ ],
147
+ "properties": {
148
+ "Node name for S&R": "VAELoader",
149
+ "cnr_id": "comfy-core",
150
+ "ver": "0.8.2",
151
+ "models": [
152
+ {
153
+ "name": "flux2-vae.safetensors",
154
+ "url": "https://huggingface.co/Comfy-Org/flux2-dev/resolve/main/split_files/vae/flux2-vae.safetensors",
155
+ "directory": "vae"
156
+ }
157
+ ],
158
+ "enableTabs": false,
159
+ "tabWidth": 65,
160
+ "tabXOffset": 10,
161
+ "hasSecondTab": false,
162
+ "secondTabText": "Send Back",
163
+ "secondTabOffset": 80,
164
+ "secondTabWidth": 65,
165
+ "ue_properties": {
166
+ "widget_ue_connectable": {},
167
+ "version": "7.1",
168
+ "input_ue_unconnectable": {}
169
+ }
170
+ },
171
+ "widgets_values": [
172
+ "flux2-vae.safetensors"
173
+ ]
174
+ },
175
+ {
176
+ "id": 110,
177
+ "type": "CLIPLoader",
178
+ "pos": [
179
+ -68.53186060598445,
180
+ 862.8520792606068
181
+ ],
182
+ "size": [
183
+ 364.42708333333337,
184
+ 106
185
+ ],
186
+ "flags": {},
187
+ "order": 3,
188
+ "mode": 0,
189
+ "inputs": [],
190
+ "outputs": [
191
+ {
192
+ "name": "CLIP",
193
+ "type": "CLIP",
194
+ "links": [
195
+ 191,
196
+ 192
197
+ ]
198
+ }
199
+ ],
200
+ "properties": {
201
+ "Node name for S&R": "CLIPLoader",
202
+ "cnr_id": "comfy-core",
203
+ "ver": "0.8.2",
204
+ "models": [
205
+ {
206
+ "name": "qwen_3_4b.safetensors",
207
+ "url": "https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/text_encoders/qwen_3_4b.safetensors",
208
+ "directory": "text_encoders"
209
+ }
210
+ ],
211
+ "enableTabs": false,
212
+ "tabWidth": 65,
213
+ "tabXOffset": 10,
214
+ "hasSecondTab": false,
215
+ "secondTabText": "Send Back",
216
+ "secondTabOffset": 80,
217
+ "secondTabWidth": 65,
218
+ "ue_properties": {
219
+ "widget_ue_connectable": {},
220
+ "version": "7.1",
221
+ "input_ue_unconnectable": {}
222
+ }
223
+ },
224
+ "widgets_values": [
225
+ "qwen_3_8b_fp8mixed.safetensors",
226
+ "flux2",
227
+ "default"
228
+ ]
229
+ },
230
+ {
231
+ "id": 136,
232
+ "type": "LanPaint_MaskBlend",
233
+ "pos": [
234
+ 2130.366524646268,
235
+ 843.6546003113864
236
+ ],
237
+ "size": [
238
+ 270,
239
+ 98
240
+ ],
241
+ "flags": {},
242
+ "order": 20,
243
+ "mode": 0,
244
+ "inputs": [
245
+ {
246
+ "name": "image1",
247
+ "type": "IMAGE",
248
+ "link": 239
249
+ },
250
+ {
251
+ "name": "image2",
252
+ "type": "IMAGE",
253
+ "link": 238
254
+ },
255
+ {
256
+ "name": "mask",
257
+ "type": "MASK",
258
+ "link": 240
259
+ }
260
+ ],
261
+ "outputs": [
262
+ {
263
+ "name": "IMAGE",
264
+ "type": "IMAGE",
265
+ "links": [
266
+ 241
267
+ ]
268
+ }
269
+ ],
270
+ "properties": {
271
+ "Node name for S&R": "LanPaint_MaskBlend",
272
+ "cnr_id": "LanPaint",
273
+ "ver": "7b0d144db9aca6a4601e7c179b4c8103036e6e2b",
274
+ "ue_properties": {
275
+ "widget_ue_connectable": {
276
+ "blend_overlap": true
277
+ },
278
+ "version": "7.1",
279
+ "input_ue_unconnectable": {}
280
+ }
281
+ },
282
+ "widgets_values": [
283
+ 9
284
+ ]
285
+ },
286
+ {
287
+ "id": 114,
288
+ "type": "ImageScaleToTotalPixels",
289
+ "pos": [
290
+ -46.9677698074011,
291
+ 1248.0941846161222
292
+ ],
293
+ "size": [
294
+ 270,
295
+ 106
296
+ ],
297
+ "flags": {},
298
+ "order": 11,
299
+ "mode": 0,
300
+ "inputs": [
301
+ {
302
+ "name": "image",
303
+ "type": "IMAGE",
304
+ "link": 204
305
+ }
306
+ ],
307
+ "outputs": [
308
+ {
309
+ "name": "IMAGE",
310
+ "type": "IMAGE",
311
+ "links": [
312
+ 198,
313
+ 199
314
+ ]
315
+ }
316
+ ],
317
+ "properties": {
318
+ "Node name for S&R": "ImageScaleToTotalPixels",
319
+ "cnr_id": "comfy-core",
320
+ "ver": "0.8.2",
321
+ "enableTabs": false,
322
+ "tabWidth": 65,
323
+ "tabXOffset": 10,
324
+ "hasSecondTab": false,
325
+ "secondTabText": "Send Back",
326
+ "secondTabOffset": 80,
327
+ "secondTabWidth": 65,
328
+ "ue_properties": {
329
+ "widget_ue_connectable": {},
330
+ "version": "7.1",
331
+ "input_ue_unconnectable": {}
332
+ }
333
+ },
334
+ "widgets_values": [
335
+ "nearest-exact",
336
+ 1,
337
+ 1
338
+ ]
339
+ },
340
+ {
341
+ "id": 116,
342
+ "type": "CFGGuider",
343
+ "pos": [
344
+ 1015.3697546367637,
345
+ 818.5786518942696
346
+ ],
347
+ "size": [
348
+ 270,
349
+ 98
350
+ ],
351
+ "flags": {},
352
+ "order": 15,
353
+ "mode": 0,
354
+ "inputs": [
355
+ {
356
+ "name": "model",
357
+ "type": "MODEL",
358
+ "link": 189
359
+ },
360
+ {
361
+ "name": "positive",
362
+ "type": "CONDITIONING",
363
+ "link": 196
364
+ },
365
+ {
366
+ "name": "negative",
367
+ "type": "CONDITIONING",
368
+ "link": 197
369
+ }
370
+ ],
371
+ "outputs": [
372
+ {
373
+ "name": "GUIDER",
374
+ "type": "GUIDER",
375
+ "links": [
376
+ 207
377
+ ]
378
+ }
379
+ ],
380
+ "properties": {
381
+ "Node name for S&R": "CFGGuider",
382
+ "cnr_id": "comfy-core",
383
+ "ver": "0.8.2",
384
+ "enableTabs": false,
385
+ "tabWidth": 65,
386
+ "tabXOffset": 10,
387
+ "hasSecondTab": false,
388
+ "secondTabText": "Send Back",
389
+ "secondTabOffset": 80,
390
+ "secondTabWidth": 65,
391
+ "ue_properties": {
392
+ "widget_ue_connectable": {},
393
+ "version": "7.1",
394
+ "input_ue_unconnectable": {}
395
+ }
396
+ },
397
+ "widgets_values": [
398
+ 5
399
+ ]
400
+ },
401
+ {
402
+ "id": 117,
403
+ "type": "KSamplerSelect",
404
+ "pos": [
405
+ 1015.3697546367637,
406
+ 958.5786930275832
407
+ ],
408
+ "size": [
409
+ 270,
410
+ 58
411
+ ],
412
+ "flags": {},
413
+ "order": 4,
414
+ "mode": 0,
415
+ "inputs": [],
416
+ "outputs": [
417
+ {
418
+ "name": "SAMPLER",
419
+ "type": "SAMPLER",
420
+ "links": [
421
+ 208
422
+ ]
423
+ }
424
+ ],
425
+ "properties": {
426
+ "Node name for S&R": "KSamplerSelect",
427
+ "cnr_id": "comfy-core",
428
+ "ver": "0.8.2",
429
+ "enableTabs": false,
430
+ "tabWidth": 65,
431
+ "tabXOffset": 10,
432
+ "hasSecondTab": false,
433
+ "secondTabText": "Send Back",
434
+ "secondTabOffset": 80,
435
+ "secondTabWidth": 65,
436
+ "ue_properties": {
437
+ "widget_ue_connectable": {},
438
+ "version": "7.1",
439
+ "input_ue_unconnectable": {}
440
+ }
441
+ },
442
+ "widgets_values": [
443
+ "euler"
444
+ ]
445
+ },
446
+ {
447
+ "id": 118,
448
+ "type": "Flux2Scheduler",
449
+ "pos": [
450
+ 1015.3697546367637,
451
+ 1058.5786098492258
452
+ ],
453
+ "size": [
454
+ 270,
455
+ 106
456
+ ],
457
+ "flags": {},
458
+ "order": 16,
459
+ "mode": 0,
460
+ "inputs": [
461
+ {
462
+ "name": "width",
463
+ "type": "INT",
464
+ "widget": {
465
+ "name": "width"
466
+ },
467
+ "link": 200
468
+ },
469
+ {
470
+ "name": "height",
471
+ "type": "INT",
472
+ "widget": {
473
+ "name": "height"
474
+ },
475
+ "link": 202
476
+ }
477
+ ],
478
+ "outputs": [
479
+ {
480
+ "name": "SIGMAS",
481
+ "type": "SIGMAS",
482
+ "links": [
483
+ 209
484
+ ]
485
+ }
486
+ ],
487
+ "properties": {
488
+ "Node name for S&R": "Flux2Scheduler",
489
+ "cnr_id": "comfy-core",
490
+ "ver": "0.8.2",
491
+ "enableTabs": false,
492
+ "tabWidth": 65,
493
+ "tabXOffset": 10,
494
+ "hasSecondTab": false,
495
+ "secondTabText": "Send Back",
496
+ "secondTabOffset": 80,
497
+ "secondTabWidth": 65,
498
+ "ue_properties": {
499
+ "widget_ue_connectable": {},
500
+ "version": "7.1",
501
+ "input_ue_unconnectable": {}
502
+ }
503
+ },
504
+ "widgets_values": [
505
+ 20,
506
+ 1024,
507
+ 1024
508
+ ]
509
+ },
510
+ {
511
+ "id": 120,
512
+ "type": "VAEDecode",
513
+ "pos": [
514
+ 1881.3770683600626,
515
+ 748.1665033623689
516
+ ],
517
+ "size": [
518
+ 220,
519
+ 46
520
+ ],
521
+ "flags": {},
522
+ "order": 19,
523
+ "mode": 0,
524
+ "inputs": [
525
+ {
526
+ "name": "samples",
527
+ "type": "LATENT",
528
+ "link": 251
529
+ },
530
+ {
531
+ "name": "vae",
532
+ "type": "VAE",
533
+ "link": 190
534
+ }
535
+ ],
536
+ "outputs": [
537
+ {
538
+ "name": "IMAGE",
539
+ "type": "IMAGE",
540
+ "slot_index": 0,
541
+ "links": [
542
+ 238
543
+ ]
544
+ }
545
+ ],
546
+ "properties": {
547
+ "Node name for S&R": "VAEDecode",
548
+ "cnr_id": "comfy-core",
549
+ "ver": "0.8.2",
550
+ "enableTabs": false,
551
+ "tabWidth": 65,
552
+ "tabXOffset": 10,
553
+ "hasSecondTab": false,
554
+ "secondTabText": "Send Back",
555
+ "secondTabOffset": 80,
556
+ "secondTabWidth": 65,
557
+ "ue_properties": {
558
+ "widget_ue_connectable": {},
559
+ "version": "7.1",
560
+ "input_ue_unconnectable": {}
561
+ }
562
+ },
563
+ "widgets_values": []
564
+ },
565
+ {
566
+ "id": 123,
567
+ "type": "GetImageSize",
568
+ "pos": [
569
+ 499.83059550468477,
570
+ 1243.3287212023115
571
+ ],
572
+ "size": [
573
+ 187.5,
574
+ 124
575
+ ],
576
+ "flags": {},
577
+ "order": 14,
578
+ "mode": 0,
579
+ "inputs": [
580
+ {
581
+ "name": "image",
582
+ "type": "IMAGE",
583
+ "link": 199
584
+ }
585
+ ],
586
+ "outputs": [
587
+ {
588
+ "name": "width",
589
+ "type": "INT",
590
+ "links": [
591
+ 200,
592
+ 201
593
+ ]
594
+ },
595
+ {
596
+ "name": "height",
597
+ "type": "INT",
598
+ "links": [
599
+ 202,
600
+ 203
601
+ ]
602
+ },
603
+ {
604
+ "name": "batch_size",
605
+ "type": "INT",
606
+ "links": []
607
+ }
608
+ ],
609
+ "properties": {
610
+ "Node name for S&R": "GetImageSize",
611
+ "cnr_id": "comfy-core",
612
+ "ver": "0.8.2",
613
+ "enableTabs": false,
614
+ "tabWidth": 65,
615
+ "tabXOffset": 10,
616
+ "hasSecondTab": false,
617
+ "secondTabText": "Send Back",
618
+ "secondTabOffset": 80,
619
+ "secondTabWidth": 65,
620
+ "ue_properties": {
621
+ "widget_ue_connectable": {},
622
+ "version": "7.1",
623
+ "input_ue_unconnectable": {}
624
+ }
625
+ },
626
+ "widgets_values": [
627
+ "width: 1024, height: 1024\n batch size: 1"
628
+ ]
629
+ },
630
+ {
631
+ "id": 115,
632
+ "type": "RandomNoise",
633
+ "pos": [
634
+ 1015.3697546367637,
635
+ 698.5786325108902
636
+ ],
637
+ "size": [
638
+ 270,
639
+ 82
640
+ ],
641
+ "flags": {},
642
+ "order": 5,
643
+ "mode": 0,
644
+ "inputs": [],
645
+ "outputs": [
646
+ {
647
+ "name": "NOISE",
648
+ "type": "NOISE",
649
+ "links": [
650
+ 206
651
+ ]
652
+ }
653
+ ],
654
+ "properties": {
655
+ "Node name for S&R": "RandomNoise",
656
+ "cnr_id": "comfy-core",
657
+ "ver": "0.8.2",
658
+ "enableTabs": false,
659
+ "tabWidth": 65,
660
+ "tabXOffset": 10,
661
+ "hasSecondTab": false,
662
+ "secondTabText": "Send Back",
663
+ "secondTabOffset": 80,
664
+ "secondTabWidth": 65,
665
+ "ue_properties": {
666
+ "widget_ue_connectable": {},
667
+ "version": "7.1",
668
+ "input_ue_unconnectable": {}
669
+ }
670
+ },
671
+ "widgets_values": [
672
+ 0,
673
+ "fixed"
674
+ ]
675
+ },
676
+ {
677
+ "id": 119,
678
+ "type": "EmptyFlux2LatentImage",
679
+ "pos": [
680
+ 769.262525556713,
681
+ 1228.1103251340592
682
+ ],
683
+ "size": [
684
+ 270,
685
+ 106
686
+ ],
687
+ "flags": {},
688
+ "order": 17,
689
+ "mode": 0,
690
+ "inputs": [
691
+ {
692
+ "name": "width",
693
+ "type": "INT",
694
+ "widget": {
695
+ "name": "width"
696
+ },
697
+ "link": 201
698
+ },
699
+ {
700
+ "name": "height",
701
+ "type": "INT",
702
+ "widget": {
703
+ "name": "height"
704
+ },
705
+ "link": 203
706
+ }
707
+ ],
708
+ "outputs": [
709
+ {
710
+ "name": "LATENT",
711
+ "type": "LATENT",
712
+ "links": []
713
+ }
714
+ ],
715
+ "properties": {
716
+ "Node name for S&R": "EmptyFlux2LatentImage",
717
+ "cnr_id": "comfy-core",
718
+ "ver": "0.8.2",
719
+ "enableTabs": false,
720
+ "tabWidth": 65,
721
+ "tabXOffset": 10,
722
+ "hasSecondTab": false,
723
+ "secondTabText": "Send Back",
724
+ "secondTabOffset": 80,
725
+ "secondTabWidth": 65,
726
+ "ue_properties": {
727
+ "widget_ue_connectable": {},
728
+ "version": "7.1",
729
+ "input_ue_unconnectable": {}
730
+ }
731
+ },
732
+ "widgets_values": [
733
+ 1024,
734
+ 1024,
735
+ 1
736
+ ]
737
+ },
738
+ {
739
+ "id": 135,
740
+ "type": "f07d2d08-2bc5-4dd8-a9f0-f2347c6b5cca",
741
+ "pos": [
742
+ 4.154091859301728,
743
+ 1721.4287401481058
744
+ ],
745
+ "size": [
746
+ 196.265234375,
747
+ 66
748
+ ],
749
+ "flags": {},
750
+ "order": 12,
751
+ "mode": 0,
752
+ "inputs": [
753
+ {
754
+ "name": "vae",
755
+ "type": "VAE",
756
+ "link": 234
757
+ },
758
+ {
759
+ "name": "image",
760
+ "type": "IMAGE",
761
+ "link": 235
762
+ },
763
+ {
764
+ "name": "mask",
765
+ "type": "MASK",
766
+ "link": 236
767
+ }
768
+ ],
769
+ "outputs": [
770
+ {
771
+ "name": "LATENT",
772
+ "type": "LATENT",
773
+ "links": [
774
+ 237
775
+ ]
776
+ },
777
+ {
778
+ "name": "MASK",
779
+ "type": "MASK",
780
+ "links": [
781
+ 240
782
+ ]
783
+ },
784
+ {
785
+ "name": "IMAGE",
786
+ "type": "IMAGE",
787
+ "links": [
788
+ 239
789
+ ]
790
+ }
791
+ ],
792
+ "properties": {
793
+ "proxyWidgets": [],
794
+ "cnr_id": "comfy-core",
795
+ "ver": "0.9.2",
796
+ "ue_properties": {
797
+ "widget_ue_connectable": {},
798
+ "version": "7.1",
799
+ "input_ue_unconnectable": {}
800
+ }
801
+ },
802
+ "widgets_values": []
803
+ },
804
+ {
805
+ "id": 9,
806
+ "type": "SaveImage",
807
+ "pos": [
808
+ 2549.2906717451565,
809
+ 1036.4687385556058
810
+ ],
811
+ "size": [
812
+ 416.6666666666667,
813
+ 470
814
+ ],
815
+ "flags": {},
816
+ "order": 21,
817
+ "mode": 0,
818
+ "inputs": [
819
+ {
820
+ "name": "images",
821
+ "type": "IMAGE",
822
+ "link": 241
823
+ }
824
+ ],
825
+ "outputs": [],
826
+ "properties": {
827
+ "cnr_id": "comfy-core",
828
+ "ver": "0.8.2",
829
+ "Node name for S&R": "SaveImage",
830
+ "enableTabs": false,
831
+ "tabWidth": 65,
832
+ "tabXOffset": 10,
833
+ "hasSecondTab": false,
834
+ "secondTabText": "Send Back",
835
+ "secondTabOffset": 80,
836
+ "secondTabWidth": 65,
837
+ "ue_properties": {
838
+ "widget_ue_connectable": {},
839
+ "version": "7.1",
840
+ "input_ue_unconnectable": {}
841
+ }
842
+ },
843
+ "widgets_values": [
844
+ "Flux2-Klein-4b-base"
845
+ ]
846
+ },
847
+ {
848
+ "id": 109,
849
+ "type": "UNETLoader",
850
+ "pos": [
851
+ -68.53186060598445,
852
+ 712.8520626074891
853
+ ],
854
+ "size": [
855
+ 364.42708333333337,
856
+ 82
857
+ ],
858
+ "flags": {},
859
+ "order": 6,
860
+ "mode": 0,
861
+ "inputs": [],
862
+ "outputs": [
863
+ {
864
+ "name": "MODEL",
865
+ "type": "MODEL",
866
+ "links": [
867
+ 189
868
+ ]
869
+ }
870
+ ],
871
+ "properties": {
872
+ "Node name for S&R": "UNETLoader",
873
+ "cnr_id": "comfy-core",
874
+ "ver": "0.8.2",
875
+ "models": [
876
+ {
877
+ "name": "lux-2-klein-base-4b-fp8.safetensors",
878
+ "url": "https://huggingface.co/black-forest-labs/FLUX.2-klein-base-4b-fp8/resolve/main/flux-2-klein-base-4b-fp8.safetensors",
879
+ "directory": "diffusion_models"
880
+ }
881
+ ],
882
+ "enableTabs": false,
883
+ "tabWidth": 65,
884
+ "tabXOffset": 10,
885
+ "hasSecondTab": false,
886
+ "secondTabText": "Send Back",
887
+ "secondTabOffset": 80,
888
+ "secondTabWidth": 65,
889
+ "ue_properties": {
890
+ "widget_ue_connectable": {},
891
+ "version": "7.1",
892
+ "input_ue_unconnectable": {}
893
+ }
894
+ },
895
+ "widgets_values": [
896
+ "flux-2-klein-base-9b-fp8.safetensors",
897
+ "default"
898
+ ]
899
+ },
900
+ {
901
+ "id": 122,
902
+ "type": "6007e698-2ebd-4917-84d8-299b35d7b7ab",
903
+ "pos": [
904
+ 1160.6499310102483,
905
+ 1732.0890781447288
906
+ ],
907
+ "size": [
908
+ 240,
909
+ 86
910
+ ],
911
+ "flags": {},
912
+ "order": 13,
913
+ "mode": 0,
914
+ "inputs": [
915
+ {
916
+ "label": "positive",
917
+ "name": "conditioning",
918
+ "type": "CONDITIONING",
919
+ "link": 194
920
+ },
921
+ {
922
+ "label": "negative",
923
+ "name": "conditioning_1",
924
+ "type": "CONDITIONING",
925
+ "link": 195
926
+ },
927
+ {
928
+ "name": "pixels",
929
+ "type": "IMAGE",
930
+ "link": 198
931
+ },
932
+ {
933
+ "name": "vae",
934
+ "type": "VAE",
935
+ "link": 205
936
+ }
937
+ ],
938
+ "outputs": [
939
+ {
940
+ "label": "positive",
941
+ "name": "CONDITIONING",
942
+ "type": "CONDITIONING",
943
+ "links": [
944
+ 196
945
+ ]
946
+ },
947
+ {
948
+ "label": "negative",
949
+ "name": "CONDITIONING_1",
950
+ "type": "CONDITIONING",
951
+ "links": [
952
+ 197
953
+ ]
954
+ }
955
+ ],
956
+ "properties": {
957
+ "proxyWidgets": [],
958
+ "cnr_id": "comfy-core",
959
+ "ver": "0.8.2",
960
+ "enableTabs": false,
961
+ "tabWidth": 65,
962
+ "tabXOffset": 10,
963
+ "hasSecondTab": false,
964
+ "secondTabText": "Send Back",
965
+ "secondTabOffset": 80,
966
+ "secondTabWidth": 65,
967
+ "ue_properties": {
968
+ "widget_ue_connectable": {},
969
+ "version": "7.1",
970
+ "input_ue_unconnectable": {}
971
+ }
972
+ },
973
+ "widgets_values": []
974
+ },
975
+ {
976
+ "id": 111,
977
+ "type": "CLIPTextEncode",
978
+ "pos": [
979
+ 361.4681372990097,
980
+ 713.0187167443823
981
+ ],
982
+ "size": [
983
+ 430,
984
+ 230
985
+ ],
986
+ "flags": {},
987
+ "order": 10,
988
+ "mode": 0,
989
+ "inputs": [
990
+ {
991
+ "name": "clip",
992
+ "type": "CLIP",
993
+ "link": 192
994
+ }
995
+ ],
996
+ "outputs": [
997
+ {
998
+ "name": "CONDITIONING",
999
+ "type": "CONDITIONING",
1000
+ "slot_index": 0,
1001
+ "links": [
1002
+ 194
1003
+ ]
1004
+ }
1005
+ ],
1006
+ "title": "CLIP Text Encode (Positive Prompt)",
1007
+ "properties": {
1008
+ "Node name for S&R": "CLIPTextEncode",
1009
+ "cnr_id": "comfy-core",
1010
+ "ver": "0.8.2",
1011
+ "enableTabs": false,
1012
+ "tabWidth": 65,
1013
+ "tabXOffset": 10,
1014
+ "hasSecondTab": false,
1015
+ "secondTabText": "Send Back",
1016
+ "secondTabOffset": 80,
1017
+ "secondTabWidth": 65,
1018
+ "ue_properties": {
1019
+ "widget_ue_connectable": {},
1020
+ "version": "7.1",
1021
+ "input_ue_unconnectable": {}
1022
+ }
1023
+ },
1024
+ "widgets_values": [
1025
+ "change building's window light color to blue"
1026
+ ],
1027
+ "color": "#232",
1028
+ "bgcolor": "#353"
1029
+ },
1030
+ {
1031
+ "id": 76,
1032
+ "type": "LoadImage",
1033
+ "pos": [
1034
+ -540.3505464098968,
1035
+ 866.1188777911093
1036
+ ],
1037
+ "size": [
1038
+ 320,
1039
+ 470
1040
+ ],
1041
+ "flags": {},
1042
+ "order": 7,
1043
+ "mode": 0,
1044
+ "inputs": [],
1045
+ "outputs": [
1046
+ {
1047
+ "name": "IMAGE",
1048
+ "type": "IMAGE",
1049
+ "links": [
1050
+ 204,
1051
+ 235
1052
+ ]
1053
+ },
1054
+ {
1055
+ "name": "MASK",
1056
+ "type": "MASK",
1057
+ "links": [
1058
+ 236
1059
+ ]
1060
+ }
1061
+ ],
1062
+ "properties": {
1063
+ "Node name for S&R": "LoadImage",
1064
+ "cnr_id": "comfy-core",
1065
+ "ver": "0.8.2",
1066
+ "enableTabs": false,
1067
+ "tabWidth": 65,
1068
+ "tabXOffset": 10,
1069
+ "hasSecondTab": false,
1070
+ "secondTabText": "Send Back",
1071
+ "secondTabOffset": 80,
1072
+ "secondTabWidth": 65,
1073
+ "ue_properties": {
1074
+ "widget_ue_connectable": {},
1075
+ "version": "7.1",
1076
+ "input_ue_unconnectable": {}
1077
+ },
1078
+ "image": "clipspace/clipspace-painted-masked-1768666568593.png [input]"
1079
+ },
1080
+ "widgets_values": [
1081
+ "clipspace-painted-masked-1768666568593.png",
1082
+ "image"
1083
+ ]
1084
+ },
1085
+ {
1086
+ "id": 141,
1087
+ "type": "Note",
1088
+ "pos": [
1089
+ 1537.948078058678,
1090
+ 1731.9861154632674
1091
+ ],
1092
+ "size": [
1093
+ 352.7542257974378,
1094
+ 139.78283467403935
1095
+ ],
1096
+ "flags": {},
1097
+ "order": 8,
1098
+ "mode": 0,
1099
+ "inputs": [],
1100
+ "outputs": [],
1101
+ "properties": {
1102
+ "ue_properties": {
1103
+ "widget_ue_connectable": {},
1104
+ "version": "7.1",
1105
+ "input_ue_unconnectable": {}
1106
+ }
1107
+ },
1108
+ "widgets_values": [
1109
+ "Bypass reference conditioning if you don't need reference"
1110
+ ],
1111
+ "color": "#432",
1112
+ "bgcolor": "#653"
1113
+ },
1114
+ {
1115
+ "id": 121,
1116
+ "type": "LanPaint_SamplerCustomAdvanced",
1117
+ "pos": [
1118
+ 1381.2404031217425,
1119
+ 648.379755917492
1120
+ ],
1121
+ "size": [
1122
+ 291.4830078125,
1123
+ 568
1124
+ ],
1125
+ "flags": {},
1126
+ "order": 18,
1127
+ "mode": 0,
1128
+ "inputs": [
1129
+ {
1130
+ "name": "noise",
1131
+ "type": "NOISE",
1132
+ "link": 206
1133
+ },
1134
+ {
1135
+ "name": "guider",
1136
+ "type": "GUIDER",
1137
+ "link": 207
1138
+ },
1139
+ {
1140
+ "name": "sampler",
1141
+ "type": "SAMPLER",
1142
+ "link": 208
1143
+ },
1144
+ {
1145
+ "name": "sigmas",
1146
+ "type": "SIGMAS",
1147
+ "link": 209
1148
+ },
1149
+ {
1150
+ "name": "latent_image",
1151
+ "type": "LATENT",
1152
+ "link": 237
1153
+ }
1154
+ ],
1155
+ "outputs": [
1156
+ {
1157
+ "name": "output",
1158
+ "type": "LATENT",
1159
+ "links": [
1160
+ 251
1161
+ ]
1162
+ },
1163
+ {
1164
+ "name": "denoised_output",
1165
+ "type": "LATENT",
1166
+ "links": []
1167
+ }
1168
+ ],
1169
+ "properties": {
1170
+ "Node name for S&R": "LanPaint_SamplerCustomAdvanced",
1171
+ "cnr_id": "LanPaint",
1172
+ "ver": "7b0d144db9aca6a4601e7c179b4c8103036e6e2b",
1173
+ "ue_properties": {
1174
+ "widget_ue_connectable": {},
1175
+ "version": "7.1",
1176
+ "input_ue_unconnectable": {}
1177
+ }
1178
+ },
1179
+ "widgets_values": [
1180
+ 2,
1181
+ 8,
1182
+ 0.2,
1183
+ 1,
1184
+ 15,
1185
+ "Image First",
1186
+ 1,
1187
+ "LanPaint Custom Sampler Adv. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!"
1188
+ ]
1189
+ }
1190
+ ],
1191
+ "links": [
1192
+ [
1193
+ 189,
1194
+ 109,
1195
+ 0,
1196
+ 116,
1197
+ 0,
1198
+ "MODEL"
1199
+ ],
1200
+ [
1201
+ 190,
1202
+ 113,
1203
+ 0,
1204
+ 120,
1205
+ 1,
1206
+ "VAE"
1207
+ ],
1208
+ [
1209
+ 191,
1210
+ 110,
1211
+ 0,
1212
+ 112,
1213
+ 0,
1214
+ "CLIP"
1215
+ ],
1216
+ [
1217
+ 192,
1218
+ 110,
1219
+ 0,
1220
+ 111,
1221
+ 0,
1222
+ "CLIP"
1223
+ ],
1224
+ [
1225
+ 194,
1226
+ 111,
1227
+ 0,
1228
+ 122,
1229
+ 0,
1230
+ "CONDITIONING"
1231
+ ],
1232
+ [
1233
+ 195,
1234
+ 112,
1235
+ 0,
1236
+ 122,
1237
+ 1,
1238
+ "CONDITIONING"
1239
+ ],
1240
+ [
1241
+ 196,
1242
+ 122,
1243
+ 0,
1244
+ 116,
1245
+ 1,
1246
+ "CONDITIONING"
1247
+ ],
1248
+ [
1249
+ 197,
1250
+ 122,
1251
+ 1,
1252
+ 116,
1253
+ 2,
1254
+ "CONDITIONING"
1255
+ ],
1256
+ [
1257
+ 198,
1258
+ 114,
1259
+ 0,
1260
+ 122,
1261
+ 2,
1262
+ "IMAGE"
1263
+ ],
1264
+ [
1265
+ 199,
1266
+ 114,
1267
+ 0,
1268
+ 123,
1269
+ 0,
1270
+ "IMAGE"
1271
+ ],
1272
+ [
1273
+ 200,
1274
+ 123,
1275
+ 0,
1276
+ 118,
1277
+ 0,
1278
+ "INT"
1279
+ ],
1280
+ [
1281
+ 201,
1282
+ 123,
1283
+ 0,
1284
+ 119,
1285
+ 0,
1286
+ "INT"
1287
+ ],
1288
+ [
1289
+ 202,
1290
+ 123,
1291
+ 1,
1292
+ 118,
1293
+ 1,
1294
+ "INT"
1295
+ ],
1296
+ [
1297
+ 203,
1298
+ 123,
1299
+ 1,
1300
+ 119,
1301
+ 1,
1302
+ "INT"
1303
+ ],
1304
+ [
1305
+ 204,
1306
+ 76,
1307
+ 0,
1308
+ 114,
1309
+ 0,
1310
+ "IMAGE"
1311
+ ],
1312
+ [
1313
+ 205,
1314
+ 113,
1315
+ 0,
1316
+ 122,
1317
+ 3,
1318
+ "VAE"
1319
+ ],
1320
+ [
1321
+ 206,
1322
+ 115,
1323
+ 0,
1324
+ 121,
1325
+ 0,
1326
+ "NOISE"
1327
+ ],
1328
+ [
1329
+ 207,
1330
+ 116,
1331
+ 0,
1332
+ 121,
1333
+ 1,
1334
+ "GUIDER"
1335
+ ],
1336
+ [
1337
+ 208,
1338
+ 117,
1339
+ 0,
1340
+ 121,
1341
+ 2,
1342
+ "SAMPLER"
1343
+ ],
1344
+ [
1345
+ 209,
1346
+ 118,
1347
+ 0,
1348
+ 121,
1349
+ 3,
1350
+ "SIGMAS"
1351
+ ],
1352
+ [
1353
+ 234,
1354
+ 113,
1355
+ 0,
1356
+ 135,
1357
+ 0,
1358
+ "VAE"
1359
+ ],
1360
+ [
1361
+ 235,
1362
+ 76,
1363
+ 0,
1364
+ 135,
1365
+ 1,
1366
+ "IMAGE"
1367
+ ],
1368
+ [
1369
+ 236,
1370
+ 76,
1371
+ 1,
1372
+ 135,
1373
+ 2,
1374
+ "MASK"
1375
+ ],
1376
+ [
1377
+ 237,
1378
+ 135,
1379
+ 0,
1380
+ 121,
1381
+ 4,
1382
+ "LATENT"
1383
+ ],
1384
+ [
1385
+ 238,
1386
+ 120,
1387
+ 0,
1388
+ 136,
1389
+ 1,
1390
+ "IMAGE"
1391
+ ],
1392
+ [
1393
+ 239,
1394
+ 135,
1395
+ 2,
1396
+ 136,
1397
+ 0,
1398
+ "IMAGE"
1399
+ ],
1400
+ [
1401
+ 240,
1402
+ 135,
1403
+ 1,
1404
+ 136,
1405
+ 2,
1406
+ "MASK"
1407
+ ],
1408
+ [
1409
+ 241,
1410
+ 136,
1411
+ 0,
1412
+ 9,
1413
+ 0,
1414
+ "IMAGE"
1415
+ ],
1416
+ [
1417
+ 251,
1418
+ 121,
1419
+ 0,
1420
+ 120,
1421
+ 0,
1422
+ "LATENT"
1423
+ ]
1424
+ ],
1425
+ "groups": [
1426
+ {
1427
+ "id": 1,
1428
+ "title": "Models",
1429
+ "bounding": [
1430
+ -72.19852871584465,
1431
+ 628.9909451488317,
1432
+ 380,
1433
+ 550
1434
+ ],
1435
+ "color": "#3f789e",
1436
+ "font_size": 24,
1437
+ "flags": {}
1438
+ },
1439
+ {
1440
+ "id": 2,
1441
+ "title": "Prompt",
1442
+ "bounding": [
1443
+ 347.8014712841558,
1444
+ 628.9909451488317,
1445
+ 470,
1446
+ 550
1447
+ ],
1448
+ "color": "#3f789e",
1449
+ "font_size": 24,
1450
+ "flags": {}
1451
+ },
1452
+ {
1453
+ "id": 3,
1454
+ "title": "Sampler",
1455
+ "bounding": [
1456
+ 1015.7031229873269,
1457
+ 634.5508624623236,
1458
+ 532.3638671875,
1459
+ 550
1460
+ ],
1461
+ "color": "#3f789e",
1462
+ "font_size": 24,
1463
+ "flags": {}
1464
+ }
1465
+ ],
1466
+ "definitions": {
1467
+ "subgraphs": [
1468
+ {
1469
+ "id": "6007e698-2ebd-4917-84d8-299b35d7b7ab",
1470
+ "version": 1,
1471
+ "state": {
1472
+ "lastGroupId": 4,
1473
+ "lastNodeId": 78,
1474
+ "lastLinkId": 170,
1475
+ "lastRerouteId": 0
1476
+ },
1477
+ "revision": 0,
1478
+ "config": {},
1479
+ "name": "Reference Conditioning",
1480
+ "inputNode": {
1481
+ "id": -10,
1482
+ "bounding": [
1483
+ -270,
1484
+ 990,
1485
+ 120,
1486
+ 120
1487
+ ]
1488
+ },
1489
+ "outputNode": {
1490
+ "id": -20,
1491
+ "bounding": [
1492
+ 580,
1493
+ 970,
1494
+ 120,
1495
+ 80
1496
+ ]
1497
+ },
1498
+ "inputs": [
1499
+ {
1500
+ "id": "5c9a0f5e-8cee-4947-90bc-330de782043a",
1501
+ "name": "conditioning",
1502
+ "type": "CONDITIONING",
1503
+ "linkIds": [
1504
+ 165
1505
+ ],
1506
+ "label": "positive",
1507
+ "pos": [
1508
+ -170,
1509
+ 1010
1510
+ ]
1511
+ },
1512
+ {
1513
+ "id": "61826d46-4c21-4ad6-801c-3e3fa94115e2",
1514
+ "name": "conditioning_1",
1515
+ "type": "CONDITIONING",
1516
+ "linkIds": [
1517
+ 166
1518
+ ],
1519
+ "label": "negative",
1520
+ "pos": [
1521
+ -170,
1522
+ 1030
1523
+ ]
1524
+ },
1525
+ {
1526
+ "id": "345bf085-5939-47ff-9767-8f8f239a719c",
1527
+ "name": "pixels",
1528
+ "type": "IMAGE",
1529
+ "linkIds": [
1530
+ 167
1531
+ ],
1532
+ "pos": [
1533
+ -170,
1534
+ 1050
1535
+ ]
1536
+ },
1537
+ {
1538
+ "id": "f4594e34-e2f5-4f1e-b1fa-a1dc2aeb0a90",
1539
+ "name": "vae",
1540
+ "type": "VAE",
1541
+ "linkIds": [
1542
+ 168
1543
+ ],
1544
+ "pos": [
1545
+ -170,
1546
+ 1070
1547
+ ]
1548
+ }
1549
+ ],
1550
+ "outputs": [
1551
+ {
1552
+ "id": "b3357c0e-6428-4055-9cd3-3595f0896fa8",
1553
+ "name": "CONDITIONING",
1554
+ "type": "CONDITIONING",
1555
+ "linkIds": [
1556
+ 169
1557
+ ],
1558
+ "label": "positive",
1559
+ "pos": [
1560
+ 600,
1561
+ 990
1562
+ ]
1563
+ },
1564
+ {
1565
+ "id": "01519713-2ed1-4694-a387-79f44e088e89",
1566
+ "name": "CONDITIONING_1",
1567
+ "type": "CONDITIONING",
1568
+ "linkIds": [
1569
+ 170
1570
+ ],
1571
+ "label": "negative",
1572
+ "pos": [
1573
+ 600,
1574
+ 1010
1575
+ ]
1576
+ }
1577
+ ],
1578
+ "widgets": [],
1579
+ "nodes": [
1580
+ {
1581
+ "id": 76,
1582
+ "type": "ReferenceLatent",
1583
+ "pos": [
1584
+ 170,
1585
+ 1050
1586
+ ],
1587
+ "size": [
1588
+ 204.134765625,
1589
+ 46
1590
+ ],
1591
+ "flags": {
1592
+ "collapsed": false
1593
+ },
1594
+ "order": 0,
1595
+ "mode": 0,
1596
+ "inputs": [
1597
+ {
1598
+ "localized_name": "conditioning",
1599
+ "name": "conditioning",
1600
+ "type": "CONDITIONING",
1601
+ "link": 166
1602
+ },
1603
+ {
1604
+ "localized_name": "latent",
1605
+ "name": "latent",
1606
+ "shape": 7,
1607
+ "type": "LATENT",
1608
+ "link": 163
1609
+ }
1610
+ ],
1611
+ "outputs": [
1612
+ {
1613
+ "localized_name": "CONDITIONING",
1614
+ "name": "CONDITIONING",
1615
+ "type": "CONDITIONING",
1616
+ "links": [
1617
+ 170
1618
+ ]
1619
+ }
1620
+ ],
1621
+ "properties": {
1622
+ "Node name for S&R": "ReferenceLatent",
1623
+ "cnr_id": "comfy-core",
1624
+ "ver": "0.8.2",
1625
+ "enableTabs": false,
1626
+ "tabWidth": 65,
1627
+ "tabXOffset": 10,
1628
+ "hasSecondTab": false,
1629
+ "secondTabText": "Send Back",
1630
+ "secondTabOffset": 80,
1631
+ "secondTabWidth": 65,
1632
+ "ue_properties": {
1633
+ "widget_ue_connectable": {},
1634
+ "version": "7.1",
1635
+ "input_ue_unconnectable": {}
1636
+ }
1637
+ },
1638
+ "widgets_values": []
1639
+ },
1640
+ {
1641
+ "id": 78,
1642
+ "type": "VAEEncode",
1643
+ "pos": [
1644
+ -90,
1645
+ 1150
1646
+ ],
1647
+ "size": [
1648
+ 190,
1649
+ 46
1650
+ ],
1651
+ "flags": {
1652
+ "collapsed": false
1653
+ },
1654
+ "order": 2,
1655
+ "mode": 0,
1656
+ "inputs": [
1657
+ {
1658
+ "localized_name": "pixels",
1659
+ "name": "pixels",
1660
+ "type": "IMAGE",
1661
+ "link": 167
1662
+ },
1663
+ {
1664
+ "localized_name": "vae",
1665
+ "name": "vae",
1666
+ "type": "VAE",
1667
+ "link": 168
1668
+ }
1669
+ ],
1670
+ "outputs": [
1671
+ {
1672
+ "localized_name": "LATENT",
1673
+ "name": "LATENT",
1674
+ "type": "LATENT",
1675
+ "links": [
1676
+ 163,
1677
+ 164
1678
+ ]
1679
+ }
1680
+ ],
1681
+ "properties": {
1682
+ "Node name for S&R": "VAEEncode",
1683
+ "cnr_id": "comfy-core",
1684
+ "ver": "0.8.2",
1685
+ "enableTabs": false,
1686
+ "tabWidth": 65,
1687
+ "tabXOffset": 10,
1688
+ "hasSecondTab": false,
1689
+ "secondTabText": "Send Back",
1690
+ "secondTabOffset": 80,
1691
+ "secondTabWidth": 65,
1692
+ "ue_properties": {
1693
+ "widget_ue_connectable": {},
1694
+ "version": "7.1",
1695
+ "input_ue_unconnectable": {}
1696
+ }
1697
+ },
1698
+ "widgets_values": []
1699
+ },
1700
+ {
1701
+ "id": 77,
1702
+ "type": "ReferenceLatent",
1703
+ "pos": [
1704
+ 170,
1705
+ 940
1706
+ ],
1707
+ "size": [
1708
+ 210,
1709
+ 46
1710
+ ],
1711
+ "flags": {
1712
+ "collapsed": false
1713
+ },
1714
+ "order": 1,
1715
+ "mode": 0,
1716
+ "inputs": [
1717
+ {
1718
+ "localized_name": "conditioning",
1719
+ "name": "conditioning",
1720
+ "type": "CONDITIONING",
1721
+ "link": 165
1722
+ },
1723
+ {
1724
+ "localized_name": "latent",
1725
+ "name": "latent",
1726
+ "shape": 7,
1727
+ "type": "LATENT",
1728
+ "link": 164
1729
+ }
1730
+ ],
1731
+ "outputs": [
1732
+ {
1733
+ "localized_name": "CONDITIONING",
1734
+ "name": "CONDITIONING",
1735
+ "type": "CONDITIONING",
1736
+ "links": [
1737
+ 169
1738
+ ]
1739
+ }
1740
+ ],
1741
+ "properties": {
1742
+ "Node name for S&R": "ReferenceLatent",
1743
+ "cnr_id": "comfy-core",
1744
+ "ver": "0.8.2",
1745
+ "enableTabs": false,
1746
+ "tabWidth": 65,
1747
+ "tabXOffset": 10,
1748
+ "hasSecondTab": false,
1749
+ "secondTabText": "Send Back",
1750
+ "secondTabOffset": 80,
1751
+ "secondTabWidth": 65,
1752
+ "ue_properties": {
1753
+ "widget_ue_connectable": {},
1754
+ "version": "7.1",
1755
+ "input_ue_unconnectable": {}
1756
+ }
1757
+ },
1758
+ "widgets_values": []
1759
+ }
1760
+ ],
1761
+ "groups": [],
1762
+ "links": [
1763
+ {
1764
+ "id": 163,
1765
+ "origin_id": 78,
1766
+ "origin_slot": 0,
1767
+ "target_id": 76,
1768
+ "target_slot": 1,
1769
+ "type": "LATENT"
1770
+ },
1771
+ {
1772
+ "id": 164,
1773
+ "origin_id": 78,
1774
+ "origin_slot": 0,
1775
+ "target_id": 77,
1776
+ "target_slot": 1,
1777
+ "type": "LATENT"
1778
+ },
1779
+ {
1780
+ "id": 165,
1781
+ "origin_id": -10,
1782
+ "origin_slot": 0,
1783
+ "target_id": 77,
1784
+ "target_slot": 0,
1785
+ "type": "CONDITIONING"
1786
+ },
1787
+ {
1788
+ "id": 166,
1789
+ "origin_id": -10,
1790
+ "origin_slot": 1,
1791
+ "target_id": 76,
1792
+ "target_slot": 0,
1793
+ "type": "CONDITIONING"
1794
+ },
1795
+ {
1796
+ "id": 167,
1797
+ "origin_id": -10,
1798
+ "origin_slot": 2,
1799
+ "target_id": 78,
1800
+ "target_slot": 0,
1801
+ "type": "IMAGE"
1802
+ },
1803
+ {
1804
+ "id": 168,
1805
+ "origin_id": -10,
1806
+ "origin_slot": 3,
1807
+ "target_id": 78,
1808
+ "target_slot": 1,
1809
+ "type": "VAE"
1810
+ },
1811
+ {
1812
+ "id": 169,
1813
+ "origin_id": 77,
1814
+ "origin_slot": 0,
1815
+ "target_id": -20,
1816
+ "target_slot": 0,
1817
+ "type": "CONDITIONING"
1818
+ },
1819
+ {
1820
+ "id": 170,
1821
+ "origin_id": 76,
1822
+ "origin_slot": 0,
1823
+ "target_id": -20,
1824
+ "target_slot": 1,
1825
+ "type": "CONDITIONING"
1826
+ }
1827
+ ],
1828
+ "extra": {
1829
+ "workflowRendererVersion": "LG",
1830
+ "ue_links": [],
1831
+ "links_added_by_ue": []
1832
+ }
1833
+ },
1834
+ {
1835
+ "id": "f07d2d08-2bc5-4dd8-a9f0-f2347c6b5cca",
1836
+ "version": 1,
1837
+ "state": {
1838
+ "lastGroupId": 3,
1839
+ "lastNodeId": 134,
1840
+ "lastLinkId": 235,
1841
+ "lastRerouteId": 0
1842
+ },
1843
+ "revision": 0,
1844
+ "config": {},
1845
+ "name": "LanPaint Preprocessing",
1846
+ "inputNode": {
1847
+ "id": -10,
1848
+ "bounding": [
1849
+ 147.7819921827197,
1850
+ 1983.6123610996979,
1851
+ 120,
1852
+ 100
1853
+ ]
1854
+ },
1855
+ "outputNode": {
1856
+ "id": -20,
1857
+ "bounding": [
1858
+ 1453.72549451583,
1859
+ 2003.6123610996979,
1860
+ 120,
1861
+ 100
1862
+ ]
1863
+ },
1864
+ "inputs": [
1865
+ {
1866
+ "id": "386e09d2-6c09-4494-8037-c52f3fc4d4fc",
1867
+ "name": "vae",
1868
+ "type": "VAE",
1869
+ "linkIds": [
1870
+ 228,
1871
+ 223,
1872
+ 233
1873
+ ],
1874
+ "localized_name": "vae",
1875
+ "pos": [
1876
+ 247.7819921827197,
1877
+ 2003.6123610996979
1878
+ ]
1879
+ },
1880
+ {
1881
+ "id": "686ea659-706d-48b5-aa90-ba8decf332ae",
1882
+ "name": "image",
1883
+ "type": "IMAGE",
1884
+ "linkIds": [
1885
+ 227,
1886
+ 224
1887
+ ],
1888
+ "localized_name": "image",
1889
+ "pos": [
1890
+ 247.7819921827197,
1891
+ 2023.6123610996979
1892
+ ]
1893
+ },
1894
+ {
1895
+ "id": "2f1a67f1-2cd1-46d9-8729-45755d6ca367",
1896
+ "name": "mask",
1897
+ "type": "MASK",
1898
+ "linkIds": [
1899
+ 225
1900
+ ],
1901
+ "localized_name": "mask",
1902
+ "pos": [
1903
+ 247.7819921827197,
1904
+ 2043.6123610996979
1905
+ ]
1906
+ }
1907
+ ],
1908
+ "outputs": [
1909
+ {
1910
+ "id": "c0e68b11-07aa-4ef5-bd82-9e26113be414",
1911
+ "name": "LATENT",
1912
+ "type": "LATENT",
1913
+ "linkIds": [
1914
+ 226
1915
+ ],
1916
+ "localized_name": "LATENT",
1917
+ "pos": [
1918
+ 1473.72549451583,
1919
+ 2023.6123610996979
1920
+ ]
1921
+ },
1922
+ {
1923
+ "id": "59d15e04-ac41-4f42-b0a0-1d4151cfe98b",
1924
+ "name": "MASK",
1925
+ "type": "MASK",
1926
+ "linkIds": [
1927
+ 234
1928
+ ],
1929
+ "pos": [
1930
+ 1473.72549451583,
1931
+ 2043.6123610996979
1932
+ ]
1933
+ },
1934
+ {
1935
+ "id": "d597296a-7306-40e4-af12-04a7c2acc51f",
1936
+ "name": "IMAGE",
1937
+ "type": "IMAGE",
1938
+ "linkIds": [
1939
+ 235
1940
+ ],
1941
+ "pos": [
1942
+ 1473.72549451583,
1943
+ 2063.612361099698
1944
+ ]
1945
+ }
1946
+ ],
1947
+ "widgets": [],
1948
+ "nodes": [
1949
+ {
1950
+ "id": 125,
1951
+ "type": "VAEDecode",
1952
+ "pos": [
1953
+ 341.948202749188,
1954
+ 1853.879018702556
1955
+ ],
1956
+ "size": [
1957
+ 210,
1958
+ 46
1959
+ ],
1960
+ "flags": {},
1961
+ "order": 1,
1962
+ "mode": 0,
1963
+ "inputs": [
1964
+ {
1965
+ "localized_name": "samples",
1966
+ "name": "samples",
1967
+ "type": "LATENT",
1968
+ "link": 212
1969
+ },
1970
+ {
1971
+ "localized_name": "vae",
1972
+ "name": "vae",
1973
+ "type": "VAE",
1974
+ "link": 228
1975
+ }
1976
+ ],
1977
+ "outputs": [
1978
+ {
1979
+ "localized_name": "IMAGE",
1980
+ "name": "IMAGE",
1981
+ "type": "IMAGE",
1982
+ "slot_index": 0,
1983
+ "links": [
1984
+ 213
1985
+ ]
1986
+ }
1987
+ ],
1988
+ "properties": {
1989
+ "Node name for S&R": "VAEDecode",
1990
+ "cnr_id": "comfy-core",
1991
+ "ver": "0.3.71",
1992
+ "enableTabs": false,
1993
+ "tabWidth": 65,
1994
+ "tabXOffset": 10,
1995
+ "hasSecondTab": false,
1996
+ "secondTabText": "Send Back",
1997
+ "secondTabOffset": 80,
1998
+ "secondTabWidth": 65,
1999
+ "ue_properties": {
2000
+ "widget_ue_connectable": {},
2001
+ "version": "7.1",
2002
+ "input_ue_unconnectable": {}
2003
+ }
2004
+ },
2005
+ "widgets_values": []
2006
+ },
2007
+ {
2008
+ "id": 126,
2009
+ "type": "GetImageSize",
2010
+ "pos": [
2011
+ 349.8229419100825,
2012
+ 1980.2723036675939
2013
+ ],
2014
+ "size": [
2015
+ 140,
2016
+ 124
2017
+ ],
2018
+ "flags": {},
2019
+ "order": 2,
2020
+ "mode": 0,
2021
+ "inputs": [
2022
+ {
2023
+ "localized_name": "image",
2024
+ "name": "image",
2025
+ "type": "IMAGE",
2026
+ "link": 213
2027
+ }
2028
+ ],
2029
+ "outputs": [
2030
+ {
2031
+ "localized_name": "width",
2032
+ "name": "width",
2033
+ "type": "INT",
2034
+ "links": [
2035
+ 215,
2036
+ 218
2037
+ ]
2038
+ },
2039
+ {
2040
+ "localized_name": "height",
2041
+ "name": "height",
2042
+ "type": "INT",
2043
+ "links": [
2044
+ 216,
2045
+ 219
2046
+ ]
2047
+ },
2048
+ {
2049
+ "localized_name": "batch_size",
2050
+ "name": "batch_size",
2051
+ "type": "INT",
2052
+ "links": []
2053
+ }
2054
+ ],
2055
+ "properties": {
2056
+ "Node name for S&R": "GetImageSize",
2057
+ "cnr_id": "comfy-core",
2058
+ "ver": "0.7.0",
2059
+ "enableTabs": false,
2060
+ "tabWidth": 65,
2061
+ "tabXOffset": 10,
2062
+ "hasSecondTab": false,
2063
+ "secondTabText": "Send Back",
2064
+ "secondTabOffset": 80,
2065
+ "secondTabWidth": 65,
2066
+ "ue_properties": {
2067
+ "widget_ue_connectable": {},
2068
+ "version": "7.1",
2069
+ "input_ue_unconnectable": {}
2070
+ }
2071
+ },
2072
+ "widgets_values": []
2073
+ },
2074
+ {
2075
+ "id": 127,
2076
+ "type": "ImageScale",
2077
+ "pos": [
2078
+ 705.0907645817256,
2079
+ 2249.5210154889633
2080
+ ],
2081
+ "size": [
2082
+ 270,
2083
+ 130
2084
+ ],
2085
+ "flags": {},
2086
+ "order": 3,
2087
+ "mode": 0,
2088
+ "inputs": [
2089
+ {
2090
+ "localized_name": "image",
2091
+ "name": "image",
2092
+ "type": "IMAGE",
2093
+ "link": 214
2094
+ },
2095
+ {
2096
+ "localized_name": "width",
2097
+ "name": "width",
2098
+ "type": "INT",
2099
+ "widget": {
2100
+ "name": "width"
2101
+ },
2102
+ "link": 215
2103
+ },
2104
+ {
2105
+ "localized_name": "height",
2106
+ "name": "height",
2107
+ "type": "INT",
2108
+ "widget": {
2109
+ "name": "height"
2110
+ },
2111
+ "link": 216
2112
+ }
2113
+ ],
2114
+ "outputs": [
2115
+ {
2116
+ "localized_name": "IMAGE",
2117
+ "name": "IMAGE",
2118
+ "type": "IMAGE",
2119
+ "links": [
2120
+ 217
2121
+ ]
2122
+ }
2123
+ ],
2124
+ "properties": {
2125
+ "Node name for S&R": "ImageScale",
2126
+ "cnr_id": "comfy-core",
2127
+ "ver": "0.3.52",
2128
+ "ue_properties": {
2129
+ "widget_ue_connectable": {
2130
+ "width": true,
2131
+ "height": true
2132
+ },
2133
+ "version": "7.1",
2134
+ "input_ue_unconnectable": {}
2135
+ }
2136
+ },
2137
+ "widgets_values": [
2138
+ "nearest-exact",
2139
+ 512,
2140
+ 512,
2141
+ "center"
2142
+ ]
2143
+ },
2144
+ {
2145
+ "id": 124,
2146
+ "type": "VAEEncode",
2147
+ "pos": [
2148
+ 334.5563505623274,
2149
+ 1685.8414078894357
2150
+ ],
2151
+ "size": [
2152
+ 140,
2153
+ 46
2154
+ ],
2155
+ "flags": {
2156
+ "collapsed": false
2157
+ },
2158
+ "order": 0,
2159
+ "mode": 0,
2160
+ "inputs": [
2161
+ {
2162
+ "localized_name": "pixels",
2163
+ "name": "pixels",
2164
+ "type": "IMAGE",
2165
+ "link": 224
2166
+ },
2167
+ {
2168
+ "localized_name": "vae",
2169
+ "name": "vae",
2170
+ "type": "VAE",
2171
+ "link": 223
2172
+ }
2173
+ ],
2174
+ "outputs": [
2175
+ {
2176
+ "localized_name": "LATENT",
2177
+ "name": "LATENT",
2178
+ "type": "LATENT",
2179
+ "links": [
2180
+ 212
2181
+ ]
2182
+ }
2183
+ ],
2184
+ "properties": {
2185
+ "Node name for S&R": "VAEEncode",
2186
+ "cnr_id": "comfy-core",
2187
+ "ver": "0.3.71",
2188
+ "enableTabs": false,
2189
+ "tabWidth": 65,
2190
+ "tabXOffset": 10,
2191
+ "hasSecondTab": false,
2192
+ "secondTabText": "Send Back",
2193
+ "secondTabOffset": 80,
2194
+ "secondTabWidth": 65,
2195
+ "ue_properties": {
2196
+ "widget_ue_connectable": {},
2197
+ "version": "7.1",
2198
+ "input_ue_unconnectable": {}
2199
+ }
2200
+ },
2201
+ "widgets_values": []
2202
+ },
2203
+ {
2204
+ "id": 129,
2205
+ "type": "MaskToImage",
2206
+ "pos": [
2207
+ 327.7819921827197,
2208
+ 1780.2436686425217
2209
+ ],
2210
+ "size": [
2211
+ 193.2779296875,
2212
+ 26
2213
+ ],
2214
+ "flags": {},
2215
+ "order": 5,
2216
+ "mode": 0,
2217
+ "inputs": [
2218
+ {
2219
+ "localized_name": "mask",
2220
+ "name": "mask",
2221
+ "type": "MASK",
2222
+ "link": 225
2223
+ }
2224
+ ],
2225
+ "outputs": [
2226
+ {
2227
+ "localized_name": "IMAGE",
2228
+ "name": "IMAGE",
2229
+ "type": "IMAGE",
2230
+ "links": [
2231
+ 214
2232
+ ]
2233
+ }
2234
+ ],
2235
+ "properties": {
2236
+ "Node name for S&R": "MaskToImage",
2237
+ "cnr_id": "comfy-core",
2238
+ "ver": "0.3.51",
2239
+ "ue_properties": {
2240
+ "widget_ue_connectable": {},
2241
+ "version": "7.1",
2242
+ "input_ue_unconnectable": {}
2243
+ }
2244
+ },
2245
+ "widgets_values": []
2246
+ },
2247
+ {
2248
+ "id": 132,
2249
+ "type": "SetLatentNoiseMask",
2250
+ "pos": [
2251
+ 1205.5881898283299,
2252
+ 1723.8113483645336
2253
+ ],
2254
+ "size": [
2255
+ 188.1373046875,
2256
+ 46
2257
+ ],
2258
+ "flags": {},
2259
+ "order": 7,
2260
+ "mode": 0,
2261
+ "inputs": [
2262
+ {
2263
+ "localized_name": "samples",
2264
+ "name": "samples",
2265
+ "type": "LATENT",
2266
+ "link": 232
2267
+ },
2268
+ {
2269
+ "localized_name": "mask",
2270
+ "name": "mask",
2271
+ "type": "MASK",
2272
+ "link": 222
2273
+ }
2274
+ ],
2275
+ "outputs": [
2276
+ {
2277
+ "localized_name": "LATENT",
2278
+ "name": "LATENT",
2279
+ "type": "LATENT",
2280
+ "links": [
2281
+ 226
2282
+ ]
2283
+ }
2284
+ ],
2285
+ "properties": {
2286
+ "Node name for S&R": "SetLatentNoiseMask",
2287
+ "cnr_id": "comfy-core",
2288
+ "ver": "0.3.51",
2289
+ "ue_properties": {
2290
+ "widget_ue_connectable": {},
2291
+ "version": "7.1",
2292
+ "input_ue_unconnectable": {}
2293
+ }
2294
+ },
2295
+ "widgets_values": []
2296
+ },
2297
+ {
2298
+ "id": 134,
2299
+ "type": "VAEEncode",
2300
+ "pos": [
2301
+ 1002.2749668743055,
2302
+ 1594.9125557215868
2303
+ ],
2304
+ "size": [
2305
+ 140,
2306
+ 46
2307
+ ],
2308
+ "flags": {
2309
+ "collapsed": false
2310
+ },
2311
+ "order": 8,
2312
+ "mode": 0,
2313
+ "inputs": [
2314
+ {
2315
+ "localized_name": "pixels",
2316
+ "name": "pixels",
2317
+ "type": "IMAGE",
2318
+ "link": 231
2319
+ },
2320
+ {
2321
+ "localized_name": "vae",
2322
+ "name": "vae",
2323
+ "type": "VAE",
2324
+ "link": 233
2325
+ }
2326
+ ],
2327
+ "outputs": [
2328
+ {
2329
+ "localized_name": "LATENT",
2330
+ "name": "LATENT",
2331
+ "type": "LATENT",
2332
+ "links": [
2333
+ 232
2334
+ ]
2335
+ }
2336
+ ],
2337
+ "properties": {
2338
+ "Node name for S&R": "VAEEncode",
2339
+ "cnr_id": "comfy-core",
2340
+ "ver": "0.3.71",
2341
+ "enableTabs": false,
2342
+ "tabWidth": 65,
2343
+ "tabXOffset": 10,
2344
+ "hasSecondTab": false,
2345
+ "secondTabText": "Send Back",
2346
+ "secondTabOffset": 80,
2347
+ "secondTabWidth": 65,
2348
+ "ue_properties": {
2349
+ "widget_ue_connectable": {},
2350
+ "version": "7.1",
2351
+ "input_ue_unconnectable": {}
2352
+ }
2353
+ },
2354
+ "widgets_values": []
2355
+ },
2356
+ {
2357
+ "id": 128,
2358
+ "type": "ImageToMask",
2359
+ "pos": [
2360
+ 707.6856669146396,
2361
+ 2444.3121664778087
2362
+ ],
2363
+ "size": [
2364
+ 270,
2365
+ 58
2366
+ ],
2367
+ "flags": {},
2368
+ "order": 4,
2369
+ "mode": 0,
2370
+ "inputs": [
2371
+ {
2372
+ "localized_name": "image",
2373
+ "name": "image",
2374
+ "type": "IMAGE",
2375
+ "link": 217
2376
+ }
2377
+ ],
2378
+ "outputs": [
2379
+ {
2380
+ "localized_name": "MASK",
2381
+ "name": "MASK",
2382
+ "type": "MASK",
2383
+ "links": [
2384
+ 222,
2385
+ 234
2386
+ ]
2387
+ }
2388
+ ],
2389
+ "properties": {
2390
+ "Node name for S&R": "ImageToMask",
2391
+ "cnr_id": "comfy-core",
2392
+ "ver": "0.3.51",
2393
+ "ue_properties": {
2394
+ "widget_ue_connectable": {},
2395
+ "version": "7.1",
2396
+ "input_ue_unconnectable": {}
2397
+ }
2398
+ },
2399
+ "widgets_values": [
2400
+ "red"
2401
+ ]
2402
+ },
2403
+ {
2404
+ "id": 130,
2405
+ "type": "ImageScale",
2406
+ "pos": [
2407
+ 722.567175008152,
2408
+ 1753.1318522245451
2409
+ ],
2410
+ "size": [
2411
+ 269.921875,
2412
+ 152.8125
2413
+ ],
2414
+ "flags": {},
2415
+ "order": 6,
2416
+ "mode": 0,
2417
+ "inputs": [
2418
+ {
2419
+ "localized_name": "image",
2420
+ "name": "image",
2421
+ "type": "IMAGE",
2422
+ "link": 227
2423
+ },
2424
+ {
2425
+ "localized_name": "width",
2426
+ "name": "width",
2427
+ "type": "INT",
2428
+ "widget": {
2429
+ "name": "width"
2430
+ },
2431
+ "link": 218
2432
+ },
2433
+ {
2434
+ "localized_name": "height",
2435
+ "name": "height",
2436
+ "type": "INT",
2437
+ "widget": {
2438
+ "name": "height"
2439
+ },
2440
+ "link": 219
2441
+ }
2442
+ ],
2443
+ "outputs": [
2444
+ {
2445
+ "localized_name": "IMAGE",
2446
+ "name": "IMAGE",
2447
+ "type": "IMAGE",
2448
+ "links": [
2449
+ 231,
2450
+ 235
2451
+ ]
2452
+ }
2453
+ ],
2454
+ "properties": {
2455
+ "Node name for S&R": "ImageScale",
2456
+ "cnr_id": "comfy-core",
2457
+ "ver": "0.3.52",
2458
+ "ue_properties": {
2459
+ "widget_ue_connectable": {
2460
+ "width": true,
2461
+ "height": true
2462
+ },
2463
+ "version": "7.1",
2464
+ "input_ue_unconnectable": {}
2465
+ }
2466
+ },
2467
+ "widgets_values": [
2468
+ "area",
2469
+ 512,
2470
+ 512,
2471
+ "center"
2472
+ ]
2473
+ }
2474
+ ],
2475
+ "groups": [],
2476
+ "links": [
2477
+ {
2478
+ "id": 212,
2479
+ "origin_id": 124,
2480
+ "origin_slot": 0,
2481
+ "target_id": 125,
2482
+ "target_slot": 0,
2483
+ "type": "LATENT"
2484
+ },
2485
+ {
2486
+ "id": 213,
2487
+ "origin_id": 125,
2488
+ "origin_slot": 0,
2489
+ "target_id": 126,
2490
+ "target_slot": 0,
2491
+ "type": "IMAGE"
2492
+ },
2493
+ {
2494
+ "id": 214,
2495
+ "origin_id": 129,
2496
+ "origin_slot": 0,
2497
+ "target_id": 127,
2498
+ "target_slot": 0,
2499
+ "type": "IMAGE"
2500
+ },
2501
+ {
2502
+ "id": 215,
2503
+ "origin_id": 126,
2504
+ "origin_slot": 0,
2505
+ "target_id": 127,
2506
+ "target_slot": 1,
2507
+ "type": "INT"
2508
+ },
2509
+ {
2510
+ "id": 216,
2511
+ "origin_id": 126,
2512
+ "origin_slot": 1,
2513
+ "target_id": 127,
2514
+ "target_slot": 2,
2515
+ "type": "INT"
2516
+ },
2517
+ {
2518
+ "id": 217,
2519
+ "origin_id": 127,
2520
+ "origin_slot": 0,
2521
+ "target_id": 128,
2522
+ "target_slot": 0,
2523
+ "type": "IMAGE"
2524
+ },
2525
+ {
2526
+ "id": 218,
2527
+ "origin_id": 126,
2528
+ "origin_slot": 0,
2529
+ "target_id": 130,
2530
+ "target_slot": 1,
2531
+ "type": "INT"
2532
+ },
2533
+ {
2534
+ "id": 219,
2535
+ "origin_id": 126,
2536
+ "origin_slot": 1,
2537
+ "target_id": 130,
2538
+ "target_slot": 2,
2539
+ "type": "INT"
2540
+ },
2541
+ {
2542
+ "id": 232,
2543
+ "origin_id": 134,
2544
+ "origin_slot": 0,
2545
+ "target_id": 132,
2546
+ "target_slot": 0,
2547
+ "type": "LATENT"
2548
+ },
2549
+ {
2550
+ "id": 222,
2551
+ "origin_id": 128,
2552
+ "origin_slot": 0,
2553
+ "target_id": 132,
2554
+ "target_slot": 1,
2555
+ "type": "MASK"
2556
+ },
2557
+ {
2558
+ "id": 231,
2559
+ "origin_id": 130,
2560
+ "origin_slot": 0,
2561
+ "target_id": 134,
2562
+ "target_slot": 0,
2563
+ "type": "IMAGE"
2564
+ },
2565
+ {
2566
+ "id": 228,
2567
+ "origin_id": -10,
2568
+ "origin_slot": 0,
2569
+ "target_id": 125,
2570
+ "target_slot": 1,
2571
+ "type": "VAE"
2572
+ },
2573
+ {
2574
+ "id": 223,
2575
+ "origin_id": -10,
2576
+ "origin_slot": 0,
2577
+ "target_id": 124,
2578
+ "target_slot": 1,
2579
+ "type": "VAE"
2580
+ },
2581
+ {
2582
+ "id": 233,
2583
+ "origin_id": -10,
2584
+ "origin_slot": 0,
2585
+ "target_id": 134,
2586
+ "target_slot": 1,
2587
+ "type": "VAE"
2588
+ },
2589
+ {
2590
+ "id": 227,
2591
+ "origin_id": -10,
2592
+ "origin_slot": 1,
2593
+ "target_id": 130,
2594
+ "target_slot": 0,
2595
+ "type": "IMAGE"
2596
+ },
2597
+ {
2598
+ "id": 224,
2599
+ "origin_id": -10,
2600
+ "origin_slot": 1,
2601
+ "target_id": 124,
2602
+ "target_slot": 0,
2603
+ "type": "IMAGE"
2604
+ },
2605
+ {
2606
+ "id": 225,
2607
+ "origin_id": -10,
2608
+ "origin_slot": 2,
2609
+ "target_id": 129,
2610
+ "target_slot": 0,
2611
+ "type": "MASK"
2612
+ },
2613
+ {
2614
+ "id": 226,
2615
+ "origin_id": 132,
2616
+ "origin_slot": 0,
2617
+ "target_id": -20,
2618
+ "target_slot": 0,
2619
+ "type": "LATENT"
2620
+ },
2621
+ {
2622
+ "id": 234,
2623
+ "origin_id": 128,
2624
+ "origin_slot": 0,
2625
+ "target_id": -20,
2626
+ "target_slot": 1,
2627
+ "type": "MASK"
2628
+ },
2629
+ {
2630
+ "id": 235,
2631
+ "origin_id": 130,
2632
+ "origin_slot": 0,
2633
+ "target_id": -20,
2634
+ "target_slot": 2,
2635
+ "type": "IMAGE"
2636
+ }
2637
+ ],
2638
+ "extra": {
2639
+ "ue_links": [],
2640
+ "links_added_by_ue": [],
2641
+ "workflowRendererVersion": "LG"
2642
+ }
2643
+ }
2644
+ ]
2645
+ },
2646
+ "config": {},
2647
+ "extra": {
2648
+ "frontendVersion": "1.37.11",
2649
+ "workflowRendererVersion": "LG",
2650
+ "VHS_latentpreview": false,
2651
+ "VHS_latentpreviewrate": 0,
2652
+ "VHS_MetadataImage": true,
2653
+ "VHS_KeepIntermediate": true,
2654
+ "ue_links": [],
2655
+ "links_added_by_ue": [],
2656
+ "ds": {
2657
+ "scale": 0.6934334949441376,
2658
+ "offset": [
2659
+ -453.34680325511,
2660
+ -421.81393627582696
2661
+ ]
2662
+ }
2663
+ },
2664
+ "version": 0.4
2665
+ }
LanPaint/example_workflows/Flux_Inpaint.jpg ADDED

Git LFS Details

  • SHA256: 9e826efb4e7dad79b01605a9a77700ec4209d14825526405e67703aa79a7719c
  • Pointer size: 132 Bytes
  • Size of remote file: 1.34 MB
LanPaint/example_workflows/Flux_Inpaint.json ADDED
@@ -0,0 +1,786 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "978d3a45-3d13-43c6-8ef9-89dc3e74d6ba",
3
+ "revision": 0,
4
+ "last_node_id": 82,
5
+ "last_link_id": 220,
6
+ "nodes": [
7
+ {
8
+ "id": 66,
9
+ "type": "SetLatentNoiseMask",
10
+ "pos": [
11
+ 514.1915893554688,
12
+ 781.9396362304688
13
+ ],
14
+ "size": [
15
+ 264.5999755859375,
16
+ 46
17
+ ],
18
+ "flags": {},
19
+ "order": 6,
20
+ "mode": 0,
21
+ "inputs": [
22
+ {
23
+ "name": "samples",
24
+ "type": "LATENT",
25
+ "link": 216
26
+ },
27
+ {
28
+ "name": "mask",
29
+ "type": "MASK",
30
+ "link": 189
31
+ }
32
+ ],
33
+ "outputs": [
34
+ {
35
+ "name": "LATENT",
36
+ "type": "LATENT",
37
+ "slot_index": 0,
38
+ "links": [
39
+ 186
40
+ ]
41
+ }
42
+ ],
43
+ "properties": {
44
+ "cnr_id": "comfy-core",
45
+ "ver": "0.3.23",
46
+ "Node name for S&R": "SetLatentNoiseMask"
47
+ },
48
+ "widgets_values": []
49
+ },
50
+ {
51
+ "id": 78,
52
+ "type": "CLIPTextEncode",
53
+ "pos": [
54
+ 314.8565368652344,
55
+ 255.63235473632812
56
+ ],
57
+ "size": [
58
+ 422.84503173828125,
59
+ 164.31304931640625
60
+ ],
61
+ "flags": {},
62
+ "order": 2,
63
+ "mode": 0,
64
+ "inputs": [
65
+ {
66
+ "label": "clip",
67
+ "name": "clip",
68
+ "type": "CLIP",
69
+ "link": 194
70
+ }
71
+ ],
72
+ "outputs": [
73
+ {
74
+ "label": "CONDITIONING",
75
+ "name": "CONDITIONING",
76
+ "type": "CONDITIONING",
77
+ "slot_index": 0,
78
+ "links": [
79
+ 195
80
+ ]
81
+ }
82
+ ],
83
+ "title": "CLIP Text Encode (Positive Prompt)",
84
+ "properties": {
85
+ "cnr_id": "comfy-core",
86
+ "ver": "0.3.26",
87
+ "Node name for S&R": "CLIPTextEncode"
88
+ },
89
+ "widgets_values": [
90
+ "cute anime girl with massive fluffy fennec ears and a big fluffy tail blonde messy long hair blue eyes wearing a maid outfit with a long black gold leaf pattern dress and a white apron mouth open placing a fancy black forest cake with candles on top of a dinner table of an old dark Victorian mansion lit by candlelight with a bright window to the foggy forest and very expensive stuff everywhere there are paintings on the walls"
91
+ ],
92
+ "color": "#232",
93
+ "bgcolor": "#353"
94
+ },
95
+ {
96
+ "id": 80,
97
+ "type": "CLIPTextEncode",
98
+ "pos": [
99
+ 362.7684020996094,
100
+ 481.0662536621094
101
+ ],
102
+ "size": [
103
+ 422.84503173828125,
104
+ 164.31304931640625
105
+ ],
106
+ "flags": {
107
+ "collapsed": true
108
+ },
109
+ "order": 3,
110
+ "mode": 0,
111
+ "inputs": [
112
+ {
113
+ "label": "clip",
114
+ "name": "clip",
115
+ "type": "CLIP",
116
+ "link": 196
117
+ }
118
+ ],
119
+ "outputs": [
120
+ {
121
+ "label": "CONDITIONING",
122
+ "name": "CONDITIONING",
123
+ "type": "CONDITIONING",
124
+ "slot_index": 0,
125
+ "links": [
126
+ 210
127
+ ]
128
+ }
129
+ ],
130
+ "title": "CLIP Text Encode (Negative Prompt)",
131
+ "properties": {
132
+ "cnr_id": "comfy-core",
133
+ "ver": "0.3.26",
134
+ "Node name for S&R": "CLIPTextEncode"
135
+ },
136
+ "widgets_values": [
137
+ ""
138
+ ],
139
+ "color": "#322",
140
+ "bgcolor": "#533"
141
+ },
142
+ {
143
+ "id": 79,
144
+ "type": "FluxGuidance",
145
+ "pos": [
146
+ 529.1380615234375,
147
+ 156.20236206054688
148
+ ],
149
+ "size": [
150
+ 211.60000610351562,
151
+ 58
152
+ ],
153
+ "flags": {},
154
+ "order": 5,
155
+ "mode": 0,
156
+ "inputs": [
157
+ {
158
+ "label": "conditioning",
159
+ "name": "conditioning",
160
+ "type": "CONDITIONING",
161
+ "link": 195
162
+ }
163
+ ],
164
+ "outputs": [
165
+ {
166
+ "label": "CONDITIONING",
167
+ "name": "CONDITIONING",
168
+ "type": "CONDITIONING",
169
+ "slot_index": 0,
170
+ "links": [
171
+ 207
172
+ ]
173
+ }
174
+ ],
175
+ "properties": {
176
+ "cnr_id": "comfy-core",
177
+ "ver": "0.3.26",
178
+ "Node name for S&R": "FluxGuidance"
179
+ },
180
+ "widgets_values": [
181
+ 3.5
182
+ ]
183
+ },
184
+ {
185
+ "id": 77,
186
+ "type": "CheckpointLoaderSimple",
187
+ "pos": [
188
+ -66.25785064697266,
189
+ 484.081787109375
190
+ ],
191
+ "size": [
192
+ 315,
193
+ 98
194
+ ],
195
+ "flags": {},
196
+ "order": 0,
197
+ "mode": 0,
198
+ "inputs": [],
199
+ "outputs": [
200
+ {
201
+ "label": "MODEL",
202
+ "name": "MODEL",
203
+ "type": "MODEL",
204
+ "slot_index": 0,
205
+ "links": [
206
+ 197
207
+ ]
208
+ },
209
+ {
210
+ "label": "CLIP",
211
+ "name": "CLIP",
212
+ "type": "CLIP",
213
+ "slot_index": 1,
214
+ "links": [
215
+ 194,
216
+ 196
217
+ ]
218
+ },
219
+ {
220
+ "label": "VAE",
221
+ "name": "VAE",
222
+ "type": "VAE",
223
+ "slot_index": 2,
224
+ "links": [
225
+ 200,
226
+ 203
227
+ ]
228
+ }
229
+ ],
230
+ "properties": {
231
+ "cnr_id": "comfy-core",
232
+ "ver": "0.3.26",
233
+ "Node name for S&R": "CheckpointLoaderSimple"
234
+ },
235
+ "widgets_values": [
236
+ "flux1-dev-fp8.safetensors"
237
+ ]
238
+ },
239
+ {
240
+ "id": 73,
241
+ "type": "LanPaint_KSampler",
242
+ "pos": [
243
+ 1005.0399780273438,
244
+ 296.9553527832031
245
+ ],
246
+ "size": [
247
+ 413.6495666503906,
248
+ 596
249
+ ],
250
+ "flags": {},
251
+ "order": 7,
252
+ "mode": 0,
253
+ "inputs": [
254
+ {
255
+ "name": "model",
256
+ "type": "MODEL",
257
+ "link": 197
258
+ },
259
+ {
260
+ "name": "positive",
261
+ "type": "CONDITIONING",
262
+ "link": 207
263
+ },
264
+ {
265
+ "name": "negative",
266
+ "type": "CONDITIONING",
267
+ "link": 210
268
+ },
269
+ {
270
+ "name": "latent_image",
271
+ "type": "LATENT",
272
+ "link": 186
273
+ }
274
+ ],
275
+ "outputs": [
276
+ {
277
+ "name": "LATENT",
278
+ "type": "LATENT",
279
+ "slot_index": 0,
280
+ "links": [
281
+ 187
282
+ ]
283
+ }
284
+ ],
285
+ "properties": {
286
+ "cnr_id": "LanPaint",
287
+ "ver": "56bd6c04e89124cd06682b304245d6ddf8b20522",
288
+ "Node name for S&R": "LanPaint_KSampler"
289
+ },
290
+ "widgets_values": [
291
+ 0,
292
+ "fixed",
293
+ 30,
294
+ 1,
295
+ "euler",
296
+ "simple",
297
+ 1,
298
+ 5,
299
+ "Image First",
300
+ "LanPaint KSampler. Recommend steps 50, LanPaint NumSteps 1-20 depending on the difficulty of task. LanPaint_EndSigma = 3.0 for anime style, 0.6 for realistic style. For more information, visit https://github.com/scraed/LanPaint",
301
+ "🖼️ Image Inpainting"
302
+ ]
303
+ },
304
+ {
305
+ "id": 65,
306
+ "type": "VAEEncode",
307
+ "pos": [
308
+ 200.1034698486328,
309
+ 776.3561401367188
310
+ ],
311
+ "size": [
312
+ 210,
313
+ 46
314
+ ],
315
+ "flags": {},
316
+ "order": 4,
317
+ "mode": 0,
318
+ "inputs": [
319
+ {
320
+ "name": "pixels",
321
+ "type": "IMAGE",
322
+ "link": 188
323
+ },
324
+ {
325
+ "name": "vae",
326
+ "type": "VAE",
327
+ "link": 203
328
+ }
329
+ ],
330
+ "outputs": [
331
+ {
332
+ "name": "LATENT",
333
+ "type": "LATENT",
334
+ "slot_index": 0,
335
+ "links": [
336
+ 216
337
+ ]
338
+ }
339
+ ],
340
+ "properties": {
341
+ "cnr_id": "comfy-core",
342
+ "ver": "0.3.23",
343
+ "Node name for S&R": "VAEEncode"
344
+ },
345
+ "widgets_values": []
346
+ },
347
+ {
348
+ "id": 48,
349
+ "type": "SaveImage",
350
+ "pos": [
351
+ 1075.49169921875,
352
+ 1167.2703857421875
353
+ ],
354
+ "size": [
355
+ 311.2532653808594,
356
+ 484.7096252441406
357
+ ],
358
+ "flags": {},
359
+ "order": 9,
360
+ "mode": 0,
361
+ "inputs": [
362
+ {
363
+ "name": "images",
364
+ "type": "IMAGE",
365
+ "link": 103
366
+ }
367
+ ],
368
+ "outputs": [],
369
+ "properties": {
370
+ "cnr_id": "comfy-core",
371
+ "ver": "0.3.23"
372
+ },
373
+ "widgets_values": [
374
+ "ComfyUI"
375
+ ]
376
+ },
377
+ {
378
+ "id": 81,
379
+ "type": "LanPaint_MaskBlend",
380
+ "pos": [
381
+ 1773.0189208984375,
382
+ 1222.9478759765625
383
+ ],
384
+ "size": [
385
+ 210,
386
+ 98
387
+ ],
388
+ "flags": {},
389
+ "order": 10,
390
+ "mode": 0,
391
+ "inputs": [
392
+ {
393
+ "name": "image1",
394
+ "type": "IMAGE",
395
+ "link": 219
396
+ },
397
+ {
398
+ "name": "image2",
399
+ "type": "IMAGE",
400
+ "link": 218
401
+ },
402
+ {
403
+ "name": "mask",
404
+ "type": "MASK",
405
+ "link": 220
406
+ }
407
+ ],
408
+ "outputs": [
409
+ {
410
+ "name": "IMAGE",
411
+ "type": "IMAGE",
412
+ "links": [
413
+ 217
414
+ ]
415
+ }
416
+ ],
417
+ "properties": {
418
+ "cnr_id": "LanPaint",
419
+ "ver": "4d3d5d17f0105b673df92da5b084cce567c9c712",
420
+ "Node name for S&R": "LanPaint_MaskBlend"
421
+ },
422
+ "widgets_values": [
423
+ 9
424
+ ]
425
+ },
426
+ {
427
+ "id": 82,
428
+ "type": "SaveImage",
429
+ "pos": [
430
+ 2106.45166015625,
431
+ 1090.682861328125
432
+ ],
433
+ "size": [
434
+ 311.2532653808594,
435
+ 484.7096252441406
436
+ ],
437
+ "flags": {},
438
+ "order": 11,
439
+ "mode": 0,
440
+ "inputs": [
441
+ {
442
+ "name": "images",
443
+ "type": "IMAGE",
444
+ "link": 217
445
+ }
446
+ ],
447
+ "outputs": [],
448
+ "properties": {
449
+ "cnr_id": "comfy-core",
450
+ "ver": "0.3.23"
451
+ },
452
+ "widgets_values": [
453
+ "ComfyUI"
454
+ ]
455
+ },
456
+ {
457
+ "id": 8,
458
+ "type": "VAEDecode",
459
+ "pos": [
460
+ 1211.46484375,
461
+ 1065.318359375
462
+ ],
463
+ "size": [
464
+ 210,
465
+ 46
466
+ ],
467
+ "flags": {},
468
+ "order": 8,
469
+ "mode": 0,
470
+ "inputs": [
471
+ {
472
+ "name": "samples",
473
+ "type": "LATENT",
474
+ "link": 187
475
+ },
476
+ {
477
+ "name": "vae",
478
+ "type": "VAE",
479
+ "link": 200
480
+ }
481
+ ],
482
+ "outputs": [
483
+ {
484
+ "name": "IMAGE",
485
+ "type": "IMAGE",
486
+ "slot_index": 0,
487
+ "links": [
488
+ 103,
489
+ 218
490
+ ]
491
+ }
492
+ ],
493
+ "properties": {
494
+ "cnr_id": "comfy-core",
495
+ "ver": "0.3.23",
496
+ "Node name for S&R": "VAEDecode"
497
+ },
498
+ "widgets_values": []
499
+ },
500
+ {
501
+ "id": 75,
502
+ "type": "LoadImage",
503
+ "pos": [
504
+ 45.954593658447266,
505
+ 1150.45556640625
506
+ ],
507
+ "size": [
508
+ 266.13720703125,
509
+ 487.1314697265625
510
+ ],
511
+ "flags": {},
512
+ "order": 1,
513
+ "mode": 0,
514
+ "inputs": [],
515
+ "outputs": [
516
+ {
517
+ "name": "IMAGE",
518
+ "type": "IMAGE",
519
+ "links": [
520
+ 188,
521
+ 219
522
+ ]
523
+ },
524
+ {
525
+ "name": "MASK",
526
+ "type": "MASK",
527
+ "links": [
528
+ 189,
529
+ 220
530
+ ]
531
+ }
532
+ ],
533
+ "properties": {
534
+ "cnr_id": "comfy-core",
535
+ "ver": "0.3.27",
536
+ "Node name for S&R": "LoadImage"
537
+ },
538
+ "widgets_values": [
539
+ "clipspace/clipspace-mask-8865503.5.png [input]",
540
+ "image"
541
+ ]
542
+ }
543
+ ],
544
+ "links": [
545
+ [
546
+ 103,
547
+ 8,
548
+ 0,
549
+ 48,
550
+ 0,
551
+ "IMAGE"
552
+ ],
553
+ [
554
+ 186,
555
+ 66,
556
+ 0,
557
+ 73,
558
+ 3,
559
+ "LATENT"
560
+ ],
561
+ [
562
+ 187,
563
+ 73,
564
+ 0,
565
+ 8,
566
+ 0,
567
+ "LATENT"
568
+ ],
569
+ [
570
+ 188,
571
+ 75,
572
+ 0,
573
+ 65,
574
+ 0,
575
+ "IMAGE"
576
+ ],
577
+ [
578
+ 189,
579
+ 75,
580
+ 1,
581
+ 66,
582
+ 1,
583
+ "MASK"
584
+ ],
585
+ [
586
+ 194,
587
+ 77,
588
+ 1,
589
+ 78,
590
+ 0,
591
+ "CLIP"
592
+ ],
593
+ [
594
+ 195,
595
+ 78,
596
+ 0,
597
+ 79,
598
+ 0,
599
+ "CONDITIONING"
600
+ ],
601
+ [
602
+ 196,
603
+ 77,
604
+ 1,
605
+ 80,
606
+ 0,
607
+ "CLIP"
608
+ ],
609
+ [
610
+ 197,
611
+ 77,
612
+ 0,
613
+ 73,
614
+ 0,
615
+ "MODEL"
616
+ ],
617
+ [
618
+ 200,
619
+ 77,
620
+ 2,
621
+ 8,
622
+ 1,
623
+ "VAE"
624
+ ],
625
+ [
626
+ 203,
627
+ 77,
628
+ 2,
629
+ 65,
630
+ 1,
631
+ "VAE"
632
+ ],
633
+ [
634
+ 207,
635
+ 79,
636
+ 0,
637
+ 73,
638
+ 1,
639
+ "CONDITIONING"
640
+ ],
641
+ [
642
+ 210,
643
+ 80,
644
+ 0,
645
+ 73,
646
+ 2,
647
+ "CONDITIONING"
648
+ ],
649
+ [
650
+ 216,
651
+ 65,
652
+ 0,
653
+ 66,
654
+ 0,
655
+ "LATENT"
656
+ ],
657
+ [
658
+ 217,
659
+ 81,
660
+ 0,
661
+ 82,
662
+ 0,
663
+ "IMAGE"
664
+ ],
665
+ [
666
+ 218,
667
+ 8,
668
+ 0,
669
+ 81,
670
+ 1,
671
+ "IMAGE"
672
+ ],
673
+ [
674
+ 219,
675
+ 75,
676
+ 0,
677
+ 81,
678
+ 0,
679
+ "IMAGE"
680
+ ],
681
+ [
682
+ 220,
683
+ 75,
684
+ 1,
685
+ 81,
686
+ 2,
687
+ "MASK"
688
+ ]
689
+ ],
690
+ "groups": [
691
+ {
692
+ "id": 1,
693
+ "title": "Mask image for inpainting.",
694
+ "bounding": [
695
+ 36.04227828979492,
696
+ 989.7313232421875,
697
+ 278.89093017578125,
698
+ 669.3414916992188
699
+ ],
700
+ "color": "#3f789e",
701
+ "font_size": 24,
702
+ "flags": {}
703
+ },
704
+ {
705
+ "id": 2,
706
+ "title": "Convert Latents for LanPaint",
707
+ "bounding": [
708
+ 286.0640563964844,
709
+ 714.343505859375,
710
+ 489.16796875,
711
+ 197.81044006347656
712
+ ],
713
+ "color": "#3f789e",
714
+ "font_size": 24,
715
+ "flags": {}
716
+ },
717
+ {
718
+ "id": 3,
719
+ "title": "Load Model and Set Prompts",
720
+ "bounding": [
721
+ -78.9311294555664,
722
+ 176.08712768554688,
723
+ 1006.1721801757812,
724
+ 514.258544921875
725
+ ],
726
+ "color": "#3f789e",
727
+ "font_size": 24,
728
+ "flags": {}
729
+ },
730
+ {
731
+ "id": 4,
732
+ "title": "Inpaint with the LanPaint KSampler",
733
+ "bounding": [
734
+ 960.8922729492188,
735
+ 179.17588806152344,
736
+ 474.8909606933594,
737
+ 630.4742431640625
738
+ ],
739
+ "color": "#3f789e",
740
+ "font_size": 24,
741
+ "flags": {}
742
+ },
743
+ {
744
+ "id": 5,
745
+ "title": "LanPaint OutPut",
746
+ "bounding": [
747
+ 1085.6029052734375,
748
+ 994.0775756835938,
749
+ 345.4561767578125,
750
+ 669.4969482421875
751
+ ],
752
+ "color": "#3f789e",
753
+ "font_size": 24,
754
+ "flags": {}
755
+ },
756
+ {
757
+ "id": 11,
758
+ "title": "LanPaint",
759
+ "bounding": [
760
+ -262.59381103515625,
761
+ 140.46656799316406,
762
+ 1737.328857421875,
763
+ 797.4443359375
764
+ ],
765
+ "color": "#3f789e",
766
+ "font_size": 24,
767
+ "flags": {}
768
+ }
769
+ ],
770
+ "config": {},
771
+ "extra": {
772
+ "ds": {
773
+ "scale": 0.35049389948139237,
774
+ "offset": [
775
+ 348.866804381099,
776
+ 308.65057628971834
777
+ ]
778
+ },
779
+ "frontendVersion": "1.27.10",
780
+ "node_versions": {
781
+ "comfy-core": "0.3.18",
782
+ "LanPaint": "0f509469ed2cd60c6032f739e282aad5dfc06166"
783
+ }
784
+ },
785
+ "version": 0.4
786
+ }
LanPaint/example_workflows/Hunyuan_Inpaint.jpg ADDED

Git LFS Details

  • SHA256: cd0114520644c017e18913b10c70c24b16c3366e4449035293e2b9f0fe1a56b2
  • Pointer size: 131 Bytes
  • Size of remote file: 686 kB
LanPaint/example_workflows/Hunyuan_Inpaint.json ADDED
@@ -0,0 +1,1033 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "054799b4-76bf-4b4e-b7b7-615d2914285b",
3
+ "revision": 0,
4
+ "last_node_id": 117,
5
+ "last_link_id": 265,
6
+ "nodes": [
7
+ {
8
+ "id": 88,
9
+ "type": "Note",
10
+ "pos": [
11
+ 180,
12
+ 440
13
+ ],
14
+ "size": [
15
+ 350,
16
+ 110
17
+ ],
18
+ "flags": {},
19
+ "order": 0,
20
+ "mode": 0,
21
+ "inputs": [],
22
+ "outputs": [],
23
+ "properties": {
24
+ "ue_properties": {
25
+ "widget_ue_connectable": {},
26
+ "version": "7.1",
27
+ "input_ue_unconnectable": {}
28
+ }
29
+ },
30
+ "widgets_values": [
31
+ "Select a fp8 weight_dtype if you are running out of memory."
32
+ ],
33
+ "color": "#432",
34
+ "bgcolor": "#653"
35
+ },
36
+ {
37
+ "id": 103,
38
+ "type": "UNETLoader",
39
+ "pos": [
40
+ 180,
41
+ 310
42
+ ],
43
+ "size": [
44
+ 350,
45
+ 82
46
+ ],
47
+ "flags": {},
48
+ "order": 1,
49
+ "mode": 0,
50
+ "inputs": [],
51
+ "outputs": [
52
+ {
53
+ "name": "MODEL",
54
+ "type": "MODEL",
55
+ "slot_index": 0,
56
+ "links": [
57
+ 241,
58
+ 242,
59
+ 250
60
+ ]
61
+ }
62
+ ],
63
+ "properties": {
64
+ "cnr_id": "comfy-core",
65
+ "ver": "0.3.23",
66
+ "Node name for S&R": "UNETLoader",
67
+ "ue_properties": {
68
+ "widget_ue_connectable": {},
69
+ "version": "7.1",
70
+ "input_ue_unconnectable": {}
71
+ }
72
+ },
73
+ "widgets_values": [
74
+ "hunyuan_video_t2v_720p_bf16.safetensors",
75
+ "default"
76
+ ],
77
+ "color": "#223",
78
+ "bgcolor": "#335"
79
+ },
80
+ {
81
+ "id": 94,
82
+ "type": "DualCLIPLoader",
83
+ "pos": [
84
+ -160,
85
+ -60
86
+ ],
87
+ "size": [
88
+ 350,
89
+ 130
90
+ ],
91
+ "flags": {},
92
+ "order": 2,
93
+ "mode": 0,
94
+ "inputs": [],
95
+ "outputs": [
96
+ {
97
+ "name": "CLIP",
98
+ "type": "CLIP",
99
+ "slot_index": 0,
100
+ "links": [
101
+ 244,
102
+ 252,
103
+ 255
104
+ ]
105
+ }
106
+ ],
107
+ "properties": {
108
+ "cnr_id": "comfy-core",
109
+ "ver": "0.3.23",
110
+ "Node name for S&R": "DualCLIPLoader",
111
+ "ue_properties": {
112
+ "widget_ue_connectable": {},
113
+ "version": "7.1",
114
+ "input_ue_unconnectable": {}
115
+ }
116
+ },
117
+ "widgets_values": [
118
+ "clip_l.safetensors",
119
+ "llava_llama3_fp8_scaled.safetensors",
120
+ "hunyuan_video",
121
+ "default"
122
+ ],
123
+ "color": "#223",
124
+ "bgcolor": "#335"
125
+ },
126
+ {
127
+ "id": 114,
128
+ "type": "FluxGuidance",
129
+ "pos": [
130
+ 653.5101318359375,
131
+ -73.20354461669922
132
+ ],
133
+ "size": [
134
+ 270,
135
+ 58
136
+ ],
137
+ "flags": {},
138
+ "order": 11,
139
+ "mode": 0,
140
+ "inputs": [
141
+ {
142
+ "name": "conditioning",
143
+ "type": "CONDITIONING",
144
+ "link": 258
145
+ }
146
+ ],
147
+ "outputs": [
148
+ {
149
+ "name": "CONDITIONING",
150
+ "type": "CONDITIONING",
151
+ "links": [
152
+ 259
153
+ ]
154
+ }
155
+ ],
156
+ "properties": {
157
+ "cnr_id": "comfy-core",
158
+ "ver": "0.3.65",
159
+ "Node name for S&R": "FluxGuidance"
160
+ },
161
+ "widgets_values": [
162
+ 6
163
+ ]
164
+ },
165
+ {
166
+ "id": 106,
167
+ "type": "VAEEncode",
168
+ "pos": [
169
+ 558.60888671875,
170
+ 922.0687255859375
171
+ ],
172
+ "size": [
173
+ 140,
174
+ 46
175
+ ],
176
+ "flags": {},
177
+ "order": 10,
178
+ "mode": 0,
179
+ "inputs": [
180
+ {
181
+ "name": "pixels",
182
+ "type": "IMAGE",
183
+ "link": 216
184
+ },
185
+ {
186
+ "name": "vae",
187
+ "type": "VAE",
188
+ "link": 220
189
+ }
190
+ ],
191
+ "outputs": [
192
+ {
193
+ "name": "LATENT",
194
+ "type": "LATENT",
195
+ "links": [
196
+ 217
197
+ ]
198
+ }
199
+ ],
200
+ "properties": {
201
+ "cnr_id": "comfy-core",
202
+ "ver": "0.3.59",
203
+ "Node name for S&R": "VAEEncode",
204
+ "ue_properties": {
205
+ "widget_ue_connectable": {},
206
+ "version": "7.1",
207
+ "input_ue_unconnectable": {}
208
+ }
209
+ },
210
+ "widgets_values": []
211
+ },
212
+ {
213
+ "id": 107,
214
+ "type": "SetLatentNoiseMask",
215
+ "pos": [
216
+ 732.1127319335938,
217
+ 906.8209228515625
218
+ ],
219
+ "size": [
220
+ 180.74765014648438,
221
+ 46
222
+ ],
223
+ "flags": {},
224
+ "order": 12,
225
+ "mode": 0,
226
+ "inputs": [
227
+ {
228
+ "name": "samples",
229
+ "type": "LATENT",
230
+ "link": 217
231
+ },
232
+ {
233
+ "name": "mask",
234
+ "type": "MASK",
235
+ "link": 218
236
+ }
237
+ ],
238
+ "outputs": [
239
+ {
240
+ "name": "LATENT",
241
+ "type": "LATENT",
242
+ "links": [
243
+ 261
244
+ ]
245
+ }
246
+ ],
247
+ "properties": {
248
+ "cnr_id": "comfy-core",
249
+ "ver": "0.3.59",
250
+ "Node name for S&R": "SetLatentNoiseMask",
251
+ "ue_properties": {
252
+ "widget_ue_connectable": {},
253
+ "version": "7.1",
254
+ "input_ue_unconnectable": {}
255
+ }
256
+ },
257
+ "widgets_values": []
258
+ },
259
+ {
260
+ "id": 105,
261
+ "type": "LoadImage",
262
+ "pos": [
263
+ 171.56072998046875,
264
+ 795.9495239257812
265
+ ],
266
+ "size": [
267
+ 274.080078125,
268
+ 314
269
+ ],
270
+ "flags": {},
271
+ "order": 3,
272
+ "mode": 0,
273
+ "inputs": [],
274
+ "outputs": [
275
+ {
276
+ "name": "IMAGE",
277
+ "type": "IMAGE",
278
+ "links": [
279
+ 216
280
+ ]
281
+ },
282
+ {
283
+ "name": "MASK",
284
+ "type": "MASK",
285
+ "links": [
286
+ 218
287
+ ]
288
+ }
289
+ ],
290
+ "properties": {
291
+ "cnr_id": "comfy-core",
292
+ "ver": "0.3.59",
293
+ "Node name for S&R": "LoadImage",
294
+ "ue_properties": {
295
+ "widget_ue_connectable": {},
296
+ "version": "7.1",
297
+ "input_ue_unconnectable": {}
298
+ }
299
+ },
300
+ "widgets_values": [
301
+ "Masked_Load_Me_in_Loader (8).png",
302
+ "image"
303
+ ]
304
+ },
305
+ {
306
+ "id": 104,
307
+ "type": "CLIPTextEncode",
308
+ "pos": [
309
+ 226.1235809326172,
310
+ -161.8229522705078
311
+ ],
312
+ "size": [
313
+ 310,
314
+ 240
315
+ ],
316
+ "flags": {},
317
+ "order": 8,
318
+ "mode": 0,
319
+ "inputs": [
320
+ {
321
+ "name": "clip",
322
+ "type": "CLIP",
323
+ "link": 252
324
+ }
325
+ ],
326
+ "outputs": [
327
+ {
328
+ "name": "CONDITIONING",
329
+ "type": "CONDITIONING",
330
+ "slot_index": 0,
331
+ "links": [
332
+ 245,
333
+ 258
334
+ ]
335
+ }
336
+ ],
337
+ "title": "CLIP Text Encode (Positive Prompt)",
338
+ "properties": {
339
+ "cnr_id": "comfy-core",
340
+ "ver": "0.3.23",
341
+ "Node name for S&R": "CLIPTextEncode",
342
+ "ue_properties": {
343
+ "widget_ue_connectable": {},
344
+ "version": "7.1",
345
+ "input_ue_unconnectable": {}
346
+ }
347
+ },
348
+ "widgets_values": [
349
+ "Close up Portrait of a futuristic cowgirl wearing jeans rides a mechanical horse across a vast cyberpunk desert. The dunes shimmer with holographic projections, glowing in blues and purples. cacti and two massive moons hang low on the horizon, illuminating the dusty air. Cyberpunk western fusion, cinematic, 8K, highly detailed, atmospheric perspective, Blade Runner style."
350
+ ],
351
+ "color": "#232",
352
+ "bgcolor": "#353"
353
+ },
354
+ {
355
+ "id": 113,
356
+ "type": "CLIPTextEncode",
357
+ "pos": [
358
+ 233.61778259277344,
359
+ 122.75636291503906
360
+ ],
361
+ "size": [
362
+ 319.00726318359375,
363
+ 88
364
+ ],
365
+ "flags": {},
366
+ "order": 9,
367
+ "mode": 0,
368
+ "inputs": [
369
+ {
370
+ "name": "clip",
371
+ "type": "CLIP",
372
+ "link": 255
373
+ }
374
+ ],
375
+ "outputs": [
376
+ {
377
+ "name": "CONDITIONING",
378
+ "type": "CONDITIONING",
379
+ "slot_index": 0,
380
+ "links": [
381
+ 254
382
+ ]
383
+ }
384
+ ],
385
+ "title": "CLIP Text Encode (Positive Prompt)",
386
+ "properties": {
387
+ "cnr_id": "comfy-core",
388
+ "ver": "0.3.23",
389
+ "Node name for S&R": "CLIPTextEncode",
390
+ "ue_properties": {
391
+ "widget_ue_connectable": {},
392
+ "version": "7.1",
393
+ "input_ue_unconnectable": {}
394
+ }
395
+ },
396
+ "widgets_values": [
397
+ ""
398
+ ],
399
+ "color": "#232",
400
+ "bgcolor": "#353"
401
+ },
402
+ {
403
+ "id": 92,
404
+ "type": "Note",
405
+ "pos": [
406
+ 1340,
407
+ 250
408
+ ],
409
+ "size": [
410
+ 210,
411
+ 170
412
+ ],
413
+ "flags": {},
414
+ "order": 4,
415
+ "mode": 0,
416
+ "inputs": [],
417
+ "outputs": [],
418
+ "properties": {
419
+ "ue_properties": {
420
+ "widget_ue_connectable": {},
421
+ "version": "7.1",
422
+ "input_ue_unconnectable": {}
423
+ }
424
+ },
425
+ "widgets_values": [
426
+ "Use the tiled decode node by default because most people will need it.\n\nLower the tile_size and overlap if you run out of memory."
427
+ ],
428
+ "color": "#432",
429
+ "bgcolor": "#653"
430
+ },
431
+ {
432
+ "id": 116,
433
+ "type": "Note",
434
+ "pos": [
435
+ 1324.0262451171875,
436
+ 583.7811889648438
437
+ ],
438
+ "size": [
439
+ 210,
440
+ 170
441
+ ],
442
+ "flags": {},
443
+ "order": 5,
444
+ "mode": 0,
445
+ "inputs": [],
446
+ "outputs": [],
447
+ "properties": {
448
+ "ue_properties": {
449
+ "widget_ue_connectable": {},
450
+ "version": "7.1",
451
+ "input_ue_unconnectable": {}
452
+ }
453
+ },
454
+ "widgets_values": [
455
+ "Decrease LanPaint_NumSteps to accelerate"
456
+ ],
457
+ "color": "#432",
458
+ "bgcolor": "#653"
459
+ },
460
+ {
461
+ "id": 85,
462
+ "type": "VAEDecodeTiled",
463
+ "pos": [
464
+ 1341.9100341796875,
465
+ 49.04500961303711
466
+ ],
467
+ "size": [
468
+ 210,
469
+ 150
470
+ ],
471
+ "flags": {},
472
+ "order": 14,
473
+ "mode": 4,
474
+ "inputs": [
475
+ {
476
+ "name": "samples",
477
+ "type": "LATENT",
478
+ "link": 248
479
+ },
480
+ {
481
+ "name": "vae",
482
+ "type": "VAE",
483
+ "link": 237
484
+ }
485
+ ],
486
+ "outputs": [
487
+ {
488
+ "name": "IMAGE",
489
+ "type": "IMAGE",
490
+ "slot_index": 0,
491
+ "links": [
492
+ 246,
493
+ 247,
494
+ 251
495
+ ]
496
+ }
497
+ ],
498
+ "properties": {
499
+ "cnr_id": "comfy-core",
500
+ "ver": "0.3.18",
501
+ "Node name for S&R": "VAEDecodeTiled",
502
+ "ue_properties": {
503
+ "widget_ue_connectable": {},
504
+ "version": "7.1",
505
+ "input_ue_unconnectable": {}
506
+ }
507
+ },
508
+ "widgets_values": [
509
+ 256,
510
+ 64,
511
+ 64,
512
+ 8
513
+ ]
514
+ },
515
+ {
516
+ "id": 86,
517
+ "type": "SaveAnimatedWEBP",
518
+ "pos": [
519
+ 1661.5201416015625,
520
+ 68.0674819946289
521
+ ],
522
+ "size": [
523
+ 380,
524
+ 366
525
+ ],
526
+ "flags": {},
527
+ "order": 16,
528
+ "mode": 4,
529
+ "inputs": [
530
+ {
531
+ "name": "images",
532
+ "type": "IMAGE",
533
+ "link": 251
534
+ }
535
+ ],
536
+ "outputs": [],
537
+ "properties": {
538
+ "cnr_id": "comfy-core",
539
+ "ver": "0.3.18",
540
+ "Node name for S&R": "SaveAnimatedWEBP",
541
+ "ue_properties": {
542
+ "widget_ue_connectable": {},
543
+ "version": "7.1",
544
+ "input_ue_unconnectable": {}
545
+ }
546
+ },
547
+ "widgets_values": [
548
+ "ComfyUI",
549
+ 24,
550
+ false,
551
+ 80,
552
+ "default"
553
+ ]
554
+ },
555
+ {
556
+ "id": 110,
557
+ "type": "LanPaint_KSampler",
558
+ "pos": [
559
+ 829.425537109375,
560
+ 218.98995971679688
561
+ ],
562
+ "size": [
563
+ 400,
564
+ 596
565
+ ],
566
+ "flags": {},
567
+ "order": 13,
568
+ "mode": 0,
569
+ "inputs": [
570
+ {
571
+ "name": "model",
572
+ "type": "MODEL",
573
+ "link": 239
574
+ },
575
+ {
576
+ "name": "positive",
577
+ "type": "CONDITIONING",
578
+ "link": 259
579
+ },
580
+ {
581
+ "name": "negative",
582
+ "type": "CONDITIONING",
583
+ "link": 254
584
+ },
585
+ {
586
+ "name": "latent_image",
587
+ "type": "LATENT",
588
+ "link": 261
589
+ }
590
+ ],
591
+ "outputs": [
592
+ {
593
+ "name": "LATENT",
594
+ "type": "LATENT",
595
+ "links": [
596
+ 248,
597
+ 262
598
+ ]
599
+ }
600
+ ],
601
+ "properties": {
602
+ "cnr_id": "LanPaint",
603
+ "ver": "6109df6591a4cf2bc9d3b113d03f7297fa9248e9",
604
+ "Node name for S&R": "LanPaint_KSampler"
605
+ },
606
+ "widgets_values": [
607
+ 534861079790570,
608
+ "randomize",
609
+ 20,
610
+ 1,
611
+ "euler",
612
+ "simple",
613
+ 1,
614
+ 5,
615
+ "Image First",
616
+ "LanPaint KSampler. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!",
617
+ "🖼️ Image Inpainting"
618
+ ]
619
+ },
620
+ {
621
+ "id": 89,
622
+ "type": "VAEDecode",
623
+ "pos": [
624
+ 1340,
625
+ -60
626
+ ],
627
+ "size": [
628
+ 210,
629
+ 46
630
+ ],
631
+ "flags": {},
632
+ "order": 15,
633
+ "mode": 0,
634
+ "inputs": [
635
+ {
636
+ "name": "samples",
637
+ "type": "LATENT",
638
+ "link": 262
639
+ },
640
+ {
641
+ "name": "vae",
642
+ "type": "VAE",
643
+ "link": 265
644
+ }
645
+ ],
646
+ "outputs": [
647
+ {
648
+ "name": "IMAGE",
649
+ "type": "IMAGE",
650
+ "slot_index": 0,
651
+ "links": [
652
+ 264
653
+ ]
654
+ }
655
+ ],
656
+ "properties": {
657
+ "cnr_id": "comfy-core",
658
+ "ver": "0.3.18",
659
+ "Node name for S&R": "VAEDecode",
660
+ "ue_properties": {
661
+ "widget_ue_connectable": {},
662
+ "version": "7.1",
663
+ "input_ue_unconnectable": {}
664
+ }
665
+ },
666
+ "widgets_values": []
667
+ },
668
+ {
669
+ "id": 78,
670
+ "type": "VAELoader",
671
+ "pos": [
672
+ 910,
673
+ -230
674
+ ],
675
+ "size": [
676
+ 350.65509033203125,
677
+ 58
678
+ ],
679
+ "flags": {},
680
+ "order": 6,
681
+ "mode": 0,
682
+ "inputs": [],
683
+ "outputs": [
684
+ {
685
+ "name": "VAE",
686
+ "type": "VAE",
687
+ "slot_index": 0,
688
+ "links": [
689
+ 229,
690
+ 232,
691
+ 220,
692
+ 237,
693
+ 265
694
+ ]
695
+ }
696
+ ],
697
+ "properties": {
698
+ "cnr_id": "comfy-core",
699
+ "ver": "0.3.18",
700
+ "Node name for S&R": "VAELoader",
701
+ "ue_properties": {
702
+ "widget_ue_connectable": {},
703
+ "version": "7.1",
704
+ "input_ue_unconnectable": {}
705
+ }
706
+ },
707
+ "widgets_values": [
708
+ "hunyuan_video_vae_bf16.safetensors"
709
+ ]
710
+ },
711
+ {
712
+ "id": 81,
713
+ "type": "ModelSamplingSD3",
714
+ "pos": [
715
+ 613.9942626953125,
716
+ 59.9338493347168
717
+ ],
718
+ "size": [
719
+ 210,
720
+ 58
721
+ ],
722
+ "flags": {},
723
+ "order": 7,
724
+ "mode": 0,
725
+ "inputs": [
726
+ {
727
+ "name": "model",
728
+ "type": "MODEL",
729
+ "link": 250
730
+ }
731
+ ],
732
+ "outputs": [
733
+ {
734
+ "name": "MODEL",
735
+ "type": "MODEL",
736
+ "slot_index": 0,
737
+ "links": [
738
+ 226,
739
+ 239
740
+ ]
741
+ }
742
+ ],
743
+ "properties": {
744
+ "cnr_id": "comfy-core",
745
+ "ver": "0.3.18",
746
+ "Node name for S&R": "ModelSamplingSD3",
747
+ "ue_properties": {
748
+ "widget_ue_connectable": {},
749
+ "version": "7.1",
750
+ "input_ue_unconnectable": {}
751
+ }
752
+ },
753
+ "widgets_values": [
754
+ 7
755
+ ]
756
+ },
757
+ {
758
+ "id": 117,
759
+ "type": "SaveImage",
760
+ "pos": [
761
+ 1670.939697265625,
762
+ -104.6227798461914
763
+ ],
764
+ "size": [
765
+ 531.0060424804688,
766
+ 550.45361328125
767
+ ],
768
+ "flags": {},
769
+ "order": 17,
770
+ "mode": 0,
771
+ "inputs": [
772
+ {
773
+ "name": "images",
774
+ "type": "IMAGE",
775
+ "link": 264
776
+ }
777
+ ],
778
+ "outputs": [],
779
+ "properties": {
780
+ "cnr_id": "comfy-core",
781
+ "ver": "0.3.65"
782
+ },
783
+ "widgets_values": [
784
+ "ComfyUI"
785
+ ]
786
+ }
787
+ ],
788
+ "links": [
789
+ [
790
+ 216,
791
+ 105,
792
+ 0,
793
+ 106,
794
+ 0,
795
+ "IMAGE"
796
+ ],
797
+ [
798
+ 217,
799
+ 106,
800
+ 0,
801
+ 107,
802
+ 0,
803
+ "LATENT"
804
+ ],
805
+ [
806
+ 218,
807
+ 105,
808
+ 1,
809
+ 107,
810
+ 1,
811
+ "MASK"
812
+ ],
813
+ [
814
+ 220,
815
+ 78,
816
+ 0,
817
+ 106,
818
+ 1,
819
+ "VAE"
820
+ ],
821
+ [
822
+ 237,
823
+ 78,
824
+ 0,
825
+ 85,
826
+ 1,
827
+ "VAE"
828
+ ],
829
+ [
830
+ 239,
831
+ 81,
832
+ 0,
833
+ 110,
834
+ 0,
835
+ "MODEL"
836
+ ],
837
+ [
838
+ 248,
839
+ 110,
840
+ 0,
841
+ 85,
842
+ 0,
843
+ "LATENT"
844
+ ],
845
+ [
846
+ 250,
847
+ 103,
848
+ 0,
849
+ 81,
850
+ 0,
851
+ "MODEL"
852
+ ],
853
+ [
854
+ 251,
855
+ 85,
856
+ 0,
857
+ 86,
858
+ 0,
859
+ "IMAGE"
860
+ ],
861
+ [
862
+ 252,
863
+ 94,
864
+ 0,
865
+ 104,
866
+ 0,
867
+ "CLIP"
868
+ ],
869
+ [
870
+ 254,
871
+ 113,
872
+ 0,
873
+ 110,
874
+ 2,
875
+ "CONDITIONING"
876
+ ],
877
+ [
878
+ 255,
879
+ 94,
880
+ 0,
881
+ 113,
882
+ 0,
883
+ "CLIP"
884
+ ],
885
+ [
886
+ 258,
887
+ 104,
888
+ 0,
889
+ 114,
890
+ 0,
891
+ "CONDITIONING"
892
+ ],
893
+ [
894
+ 259,
895
+ 114,
896
+ 0,
897
+ 110,
898
+ 1,
899
+ "CONDITIONING"
900
+ ],
901
+ [
902
+ 261,
903
+ 107,
904
+ 0,
905
+ 110,
906
+ 3,
907
+ "LATENT"
908
+ ],
909
+ [
910
+ 262,
911
+ 110,
912
+ 0,
913
+ 89,
914
+ 0,
915
+ "LATENT"
916
+ ],
917
+ [
918
+ 264,
919
+ 89,
920
+ 0,
921
+ 117,
922
+ 0,
923
+ "IMAGE"
924
+ ],
925
+ [
926
+ 265,
927
+ 78,
928
+ 0,
929
+ 89,
930
+ 1,
931
+ "VAE"
932
+ ]
933
+ ],
934
+ "groups": [
935
+ {
936
+ "id": 1,
937
+ "title": "Text Encoding",
938
+ "bounding": [
939
+ -190,
940
+ -140,
941
+ 730,
942
+ 340
943
+ ],
944
+ "color": "#8A8",
945
+ "font_size": 24,
946
+ "flags": {}
947
+ },
948
+ {
949
+ "id": 2,
950
+ "title": "VAE Decoding & Output",
951
+ "bounding": [
952
+ 1320,
953
+ -140,
954
+ 1110,
955
+ 600
956
+ ],
957
+ "color": "#3f789e",
958
+ "font_size": 24,
959
+ "flags": {}
960
+ },
961
+ {
962
+ "id": 4,
963
+ "title": "Sampling Process",
964
+ "bounding": [
965
+ 570,
966
+ -140,
967
+ 730,
968
+ 980
969
+ ],
970
+ "color": "#3f789e",
971
+ "font_size": 24,
972
+ "flags": {}
973
+ },
974
+ {
975
+ "id": 5,
976
+ "title": "HunyuanVideo Model",
977
+ "bounding": [
978
+ 170,
979
+ 230,
980
+ 370.5005798339844,
981
+ 330.7360534667969
982
+ ],
983
+ "color": "#88A",
984
+ "font_size": 24,
985
+ "flags": {}
986
+ },
987
+ {
988
+ "id": 6,
989
+ "title": "Guidance",
990
+ "bounding": [
991
+ 590,
992
+ -90,
993
+ 680,
994
+ 260
995
+ ],
996
+ "color": "#8AA",
997
+ "font_size": 24,
998
+ "flags": {}
999
+ },
1000
+ {
1001
+ "id": 7,
1002
+ "title": "sampling",
1003
+ "bounding": [
1004
+ 590,
1005
+ 200,
1006
+ 680,
1007
+ 440
1008
+ ],
1009
+ "color": "#b06634",
1010
+ "font_size": 24,
1011
+ "flags": {}
1012
+ }
1013
+ ],
1014
+ "config": {},
1015
+ "extra": {
1016
+ "ds": {
1017
+ "scale": 0.4870776476432723,
1018
+ "offset": [
1019
+ 85.03251058761712,
1020
+ 779.6524460150363
1021
+ ]
1022
+ },
1023
+ "frontendVersion": "1.27.10",
1024
+ "groupNodes": {},
1025
+ "ue_links": [],
1026
+ "links_added_by_ue": [],
1027
+ "VHS_latentpreview": false,
1028
+ "VHS_latentpreviewrate": 0,
1029
+ "VHS_MetadataImage": true,
1030
+ "VHS_KeepIntermediate": true
1031
+ },
1032
+ "version": 0.4
1033
+ }
LanPaint/example_workflows/Masked_Qwen_Image_Edit.jpg ADDED

Git LFS Details

  • SHA256: 9994fe2e38218474e755959c00ab081c7e90565746132cba359da98b57240a76
  • Pointer size: 131 Bytes
  • Size of remote file: 690 kB
LanPaint/example_workflows/Masked_Qwen_Image_Edit.json ADDED
@@ -0,0 +1,1636 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "91f6bbe2-ed41-4fd6-bac7-71d5b5864ecb",
3
+ "revision": 0,
4
+ "last_node_id": 147,
5
+ "last_link_id": 315,
6
+ "nodes": [
7
+ {
8
+ "id": 99,
9
+ "type": "MarkdownNote",
10
+ "pos": [
11
+ -830,
12
+ -10
13
+ ],
14
+ "size": [
15
+ 540,
16
+ 550
17
+ ],
18
+ "flags": {},
19
+ "order": 0,
20
+ "mode": 0,
21
+ "inputs": [],
22
+ "outputs": [],
23
+ "title": "Model links",
24
+ "properties": {
25
+ "widget_ue_connectable": {}
26
+ },
27
+ "widgets_values": [
28
+ "[Tutorial](https://docs.comfy.org/tutorials/image/qwen/qwen-image-edit) | [教程](https://docs.comfy.org/zh-CN/tutorials/image/qwen/qwen-image-edit)\n\n\n## Model links\n\nYou can find all the models on [Comfy-Org/Qwen-Image_ComfyUI](https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/tree/main) and [Comfy-Org/Qwen-Image-Edit_ComfyUI](https://huggingface.co/Comfy-Org/Qwen-Image-Edit_ComfyUI) \n\n**Diffusion model**\n\n- [qwen_image_edit_fp8_e4m3fn.safetensors](https://huggingface.co/Comfy-Org/Qwen-Image-Edit_ComfyUI/resolve/main/split_files/diffusion_models/qwen_image_edit_fp8_e4m3fn.safetensors)\n\n**LoRA**\n\n- [Qwen-Image-Lightning-4steps-V1.0.safetensors](https://huggingface.co/lightx2v/Qwen-Image-Lightning/resolve/main/Qwen-Image-Lightning-4steps-V1.0.safetensors)\n\n**Text encoder**\n\n- [qwen_2.5_vl_7b_fp8_scaled.safetensors](https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/text_encoders/qwen_2.5_vl_7b_fp8_scaled.safetensors)\n\n**VAE**\n\n- [qwen_image_vae.safetensors](https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/vae/qwen_image_vae.safetensors)\n\nModel Storage Location\n\n```\n📂 ComfyUI/\n├── 📂 models/\n│ ├── 📂 diffusion_models/\n│ │ └── qwen_image_edit_fp8_e4m3fn.safetensors\n│ ├── 📂 loras/\n│ │ └── Qwen-Image-Lightning-4steps-V1.0.safetensors\n│ ├── 📂 vae/\n│ │ └── qwen_image_vae.safetensors\n│ └── 📂 text_encoders/\n│ └── qwen_2.5_vl_7b_fp8_scaled.safetensors\n```\n"
29
+ ],
30
+ "color": "#432",
31
+ "bgcolor": "#653"
32
+ },
33
+ {
34
+ "id": 129,
35
+ "type": "ModelSamplingAuraFlow",
36
+ "pos": [
37
+ 550.1956176757812,
38
+ 27.127967834472656
39
+ ],
40
+ "size": [
41
+ 290,
42
+ 60
43
+ ],
44
+ "flags": {},
45
+ "order": 11,
46
+ "mode": 0,
47
+ "inputs": [
48
+ {
49
+ "name": "model",
50
+ "type": "MODEL",
51
+ "link": 293
52
+ }
53
+ ],
54
+ "outputs": [
55
+ {
56
+ "name": "MODEL",
57
+ "type": "MODEL",
58
+ "links": [
59
+ 260
60
+ ]
61
+ }
62
+ ],
63
+ "properties": {
64
+ "cnr_id": "comfy-core",
65
+ "ver": "0.3.48",
66
+ "Node name for S&R": "ModelSamplingAuraFlow",
67
+ "enableTabs": false,
68
+ "tabWidth": 65,
69
+ "tabXOffset": 10,
70
+ "hasSecondTab": false,
71
+ "secondTabText": "Send Back",
72
+ "secondTabOffset": 80,
73
+ "secondTabWidth": 65,
74
+ "widget_ue_connectable": {}
75
+ },
76
+ "widgets_values": [
77
+ 3
78
+ ]
79
+ },
80
+ {
81
+ "id": 130,
82
+ "type": "CFGNorm",
83
+ "pos": [
84
+ 550.1956176757812,
85
+ 137.1279754638672
86
+ ],
87
+ "size": [
88
+ 290,
89
+ 60
90
+ ],
91
+ "flags": {},
92
+ "order": 13,
93
+ "mode": 0,
94
+ "inputs": [
95
+ {
96
+ "name": "model",
97
+ "type": "MODEL",
98
+ "link": 260
99
+ }
100
+ ],
101
+ "outputs": [
102
+ {
103
+ "name": "patched_model",
104
+ "type": "MODEL",
105
+ "links": [
106
+ 269
107
+ ]
108
+ }
109
+ ],
110
+ "properties": {
111
+ "cnr_id": "comfy-core",
112
+ "ver": "0.3.50",
113
+ "Node name for S&R": "CFGNorm",
114
+ "enableTabs": false,
115
+ "tabWidth": 65,
116
+ "tabXOffset": 10,
117
+ "hasSecondTab": false,
118
+ "secondTabText": "Send Back",
119
+ "secondTabOffset": 80,
120
+ "secondTabWidth": 65,
121
+ "ue_properties": {
122
+ "widget_ue_connectable": {
123
+ "strength": true
124
+ }
125
+ }
126
+ },
127
+ "widgets_values": [
128
+ 1
129
+ ]
130
+ },
131
+ {
132
+ "id": 138,
133
+ "type": "LanPaint_MaskBlend",
134
+ "pos": [
135
+ 1746.5638427734375,
136
+ 60.70713806152344
137
+ ],
138
+ "size": [
139
+ 210,
140
+ 98
141
+ ],
142
+ "flags": {},
143
+ "order": 25,
144
+ "mode": 0,
145
+ "inputs": [
146
+ {
147
+ "name": "image1",
148
+ "type": "IMAGE",
149
+ "link": 309
150
+ },
151
+ {
152
+ "name": "image2",
153
+ "type": "IMAGE",
154
+ "link": 286
155
+ },
156
+ {
157
+ "name": "mask",
158
+ "type": "MASK",
159
+ "link": 290
160
+ }
161
+ ],
162
+ "outputs": [
163
+ {
164
+ "name": "IMAGE",
165
+ "type": "IMAGE",
166
+ "links": [
167
+ 291
168
+ ]
169
+ }
170
+ ],
171
+ "properties": {
172
+ "cnr_id": "LanPaint",
173
+ "ver": "4d3d5d17f0105b673df92da5b084cce567c9c712",
174
+ "Node name for S&R": "LanPaint_MaskBlend"
175
+ },
176
+ "widgets_values": [
177
+ 9
178
+ ]
179
+ },
180
+ {
181
+ "id": 97,
182
+ "type": "MarkdownNote",
183
+ "pos": [
184
+ 960.13525390625,
185
+ 776.3380737304688
186
+ ],
187
+ "size": [
188
+ 300,
189
+ 190
190
+ ],
191
+ "flags": {},
192
+ "order": 1,
193
+ "mode": 0,
194
+ "inputs": [],
195
+ "outputs": [],
196
+ "title": "KSampler settings",
197
+ "properties": {},
198
+ "widgets_values": [
199
+ "You can test and find the best setting by yourself. The following table is for reference.\n\n| Model | Steps | CFG |\n|---------------------|---------------|---------------|\n| Offical | 50 | 4.0 \n| fp8_e4m3fn | 20 | 2.5 |\n| fp8_e4m3fn + 4steps LoRA | 4 | 1.0 |\n"
200
+ ],
201
+ "color": "#432",
202
+ "bgcolor": "#653"
203
+ },
204
+ {
205
+ "id": 124,
206
+ "type": "UNETLoader",
207
+ "pos": [
208
+ -249.80447387695312,
209
+ 37.12797164916992
210
+ ],
211
+ "size": [
212
+ 330,
213
+ 90
214
+ ],
215
+ "flags": {},
216
+ "order": 2,
217
+ "mode": 0,
218
+ "inputs": [],
219
+ "outputs": [
220
+ {
221
+ "name": "MODEL",
222
+ "type": "MODEL",
223
+ "slot_index": 0,
224
+ "links": [
225
+ 292
226
+ ]
227
+ }
228
+ ],
229
+ "properties": {
230
+ "cnr_id": "comfy-core",
231
+ "ver": "0.3.48",
232
+ "Node name for S&R": "UNETLoader",
233
+ "models": [
234
+ {
235
+ "name": "qwen_image_edit_fp8_e4m3fn.safetensors",
236
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image-Edit_ComfyUI/resolve/main/split_files/diffusion_models/qwen_image_edit_fp8_e4m3fn.safetensors",
237
+ "directory": "diffusion_models"
238
+ }
239
+ ],
240
+ "enableTabs": false,
241
+ "tabWidth": 65,
242
+ "tabXOffset": 10,
243
+ "hasSecondTab": false,
244
+ "secondTabText": "Send Back",
245
+ "secondTabOffset": 80,
246
+ "secondTabWidth": 65,
247
+ "widget_ue_connectable": {}
248
+ },
249
+ "widgets_values": [
250
+ "qwen_image_edit_fp8_e4m3fn.safetensors",
251
+ "default"
252
+ ]
253
+ },
254
+ {
255
+ "id": 141,
256
+ "type": "LoraLoaderModelOnly",
257
+ "pos": [
258
+ 199.41346740722656,
259
+ 19.401098251342773
260
+ ],
261
+ "size": [
262
+ 270,
263
+ 82
264
+ ],
265
+ "flags": {},
266
+ "order": 8,
267
+ "mode": 4,
268
+ "inputs": [
269
+ {
270
+ "name": "model",
271
+ "type": "MODEL",
272
+ "link": 292
273
+ }
274
+ ],
275
+ "outputs": [
276
+ {
277
+ "name": "MODEL",
278
+ "type": "MODEL",
279
+ "links": [
280
+ 293
281
+ ]
282
+ }
283
+ ],
284
+ "properties": {
285
+ "cnr_id": "comfy-core",
286
+ "ver": "0.3.50",
287
+ "Node name for S&R": "LoraLoaderModelOnly",
288
+ "models": [
289
+ {
290
+ "name": "Qwen-Image-Lightning-4steps-V1.0.safetensors",
291
+ "url": "https://huggingface.co/lightx2v/Qwen-Image-Lightning/resolve/main/Qwen-Image-Lightning-4steps-V1.0.safetensors",
292
+ "directory": "loras"
293
+ }
294
+ ],
295
+ "enableTabs": false,
296
+ "tabWidth": 65,
297
+ "tabXOffset": 10,
298
+ "hasSecondTab": false,
299
+ "secondTabText": "Send Back",
300
+ "secondTabOffset": 80,
301
+ "secondTabWidth": 65,
302
+ "ue_properties": {
303
+ "widget_ue_connectable": {
304
+ "lora_name": true,
305
+ "strength_model": true
306
+ }
307
+ }
308
+ },
309
+ "widgets_values": [
310
+ "Qwen-Image-Lightning-4steps-V1.0.safetensors",
311
+ 1
312
+ ]
313
+ },
314
+ {
315
+ "id": 125,
316
+ "type": "CLIPLoader",
317
+ "pos": [
318
+ -249.80447387695312,
319
+ 177.12796020507812
320
+ ],
321
+ "size": [
322
+ 330,
323
+ 110
324
+ ],
325
+ "flags": {},
326
+ "order": 3,
327
+ "mode": 0,
328
+ "inputs": [],
329
+ "outputs": [
330
+ {
331
+ "name": "CLIP",
332
+ "type": "CLIP",
333
+ "slot_index": 0,
334
+ "links": [
335
+ 255,
336
+ 257
337
+ ]
338
+ }
339
+ ],
340
+ "properties": {
341
+ "cnr_id": "comfy-core",
342
+ "ver": "0.3.48",
343
+ "Node name for S&R": "CLIPLoader",
344
+ "models": [
345
+ {
346
+ "name": "qwen_2.5_vl_7b_fp8_scaled.safetensors",
347
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/text_encoders/qwen_2.5_vl_7b_fp8_scaled.safetensors",
348
+ "directory": "text_encoders"
349
+ }
350
+ ],
351
+ "enableTabs": false,
352
+ "tabWidth": 65,
353
+ "tabXOffset": 10,
354
+ "hasSecondTab": false,
355
+ "secondTabText": "Send Back",
356
+ "secondTabOffset": 80,
357
+ "secondTabWidth": 65,
358
+ "widget_ue_connectable": {}
359
+ },
360
+ "widgets_values": [
361
+ "qwen_2.5_vl_7b_fp8_scaled.safetensors",
362
+ "qwen_image",
363
+ "default"
364
+ ]
365
+ },
366
+ {
367
+ "id": 104,
368
+ "type": "SaveImage",
369
+ "pos": [
370
+ 2063.178955078125,
371
+ 10.873106002807617
372
+ ],
373
+ "size": [
374
+ 311.2532653808594,
375
+ 484.7096252441406
376
+ ],
377
+ "flags": {},
378
+ "order": 26,
379
+ "mode": 0,
380
+ "inputs": [
381
+ {
382
+ "name": "images",
383
+ "type": "IMAGE",
384
+ "link": 291
385
+ }
386
+ ],
387
+ "outputs": [],
388
+ "properties": {
389
+ "cnr_id": "comfy-core",
390
+ "ver": "0.3.23"
391
+ },
392
+ "widgets_values": [
393
+ "ComfyUI"
394
+ ]
395
+ },
396
+ {
397
+ "id": 127,
398
+ "type": "TextEncodeQwenImageEdit",
399
+ "pos": [
400
+ 182.30767822265625,
401
+ 198.8886260986328
402
+ ],
403
+ "size": [
404
+ 360,
405
+ 150
406
+ ],
407
+ "flags": {},
408
+ "order": 18,
409
+ "mode": 0,
410
+ "inputs": [
411
+ {
412
+ "name": "clip",
413
+ "type": "CLIP",
414
+ "link": 255
415
+ },
416
+ {
417
+ "name": "vae",
418
+ "shape": 7,
419
+ "type": "VAE",
420
+ "link": 256
421
+ },
422
+ {
423
+ "name": "image",
424
+ "shape": 7,
425
+ "type": "IMAGE",
426
+ "link": 306
427
+ }
428
+ ],
429
+ "outputs": [
430
+ {
431
+ "name": "CONDITIONING",
432
+ "type": "CONDITIONING",
433
+ "links": [
434
+ 267
435
+ ]
436
+ }
437
+ ],
438
+ "properties": {
439
+ "cnr_id": "comfy-core",
440
+ "ver": "0.3.50",
441
+ "Node name for S&R": "TextEncodeQwenImageEdit",
442
+ "enableTabs": false,
443
+ "tabWidth": 65,
444
+ "tabXOffset": 10,
445
+ "hasSecondTab": false,
446
+ "secondTabText": "Send Back",
447
+ "secondTabOffset": 80,
448
+ "secondTabWidth": 65,
449
+ "ue_properties": {
450
+ "widget_ue_connectable": {
451
+ "prompt": true
452
+ }
453
+ }
454
+ },
455
+ "widgets_values": [
456
+ "change the girl's cloth to red evening gown "
457
+ ],
458
+ "color": "#232",
459
+ "bgcolor": "#353"
460
+ },
461
+ {
462
+ "id": 128,
463
+ "type": "TextEncodeQwenImageEdit",
464
+ "pos": [
465
+ 190.8400421142578,
466
+ 395.84197998046875
467
+ ],
468
+ "size": [
469
+ 360,
470
+ 150
471
+ ],
472
+ "flags": {},
473
+ "order": 19,
474
+ "mode": 0,
475
+ "inputs": [
476
+ {
477
+ "name": "clip",
478
+ "type": "CLIP",
479
+ "link": 257
480
+ },
481
+ {
482
+ "name": "vae",
483
+ "shape": 7,
484
+ "type": "VAE",
485
+ "link": 258
486
+ },
487
+ {
488
+ "name": "image",
489
+ "shape": 7,
490
+ "type": "IMAGE",
491
+ "link": 307
492
+ }
493
+ ],
494
+ "outputs": [
495
+ {
496
+ "name": "CONDITIONING",
497
+ "type": "CONDITIONING",
498
+ "links": [
499
+ 268
500
+ ]
501
+ }
502
+ ],
503
+ "properties": {
504
+ "cnr_id": "comfy-core",
505
+ "ver": "0.3.50",
506
+ "Node name for S&R": "TextEncodeQwenImageEdit",
507
+ "enableTabs": false,
508
+ "tabWidth": 65,
509
+ "tabXOffset": 10,
510
+ "hasSecondTab": false,
511
+ "secondTabText": "Send Back",
512
+ "secondTabOffset": 80,
513
+ "secondTabWidth": 65,
514
+ "ue_properties": {
515
+ "widget_ue_connectable": {
516
+ "prompt": true
517
+ }
518
+ }
519
+ },
520
+ "widgets_values": [
521
+ ""
522
+ ],
523
+ "color": "#223",
524
+ "bgcolor": "#335"
525
+ },
526
+ {
527
+ "id": 134,
528
+ "type": "SetLatentNoiseMask",
529
+ "pos": [
530
+ 560.0880126953125,
531
+ 642.5905151367188
532
+ ],
533
+ "size": [
534
+ 180.74765014648438,
535
+ 46
536
+ ],
537
+ "flags": {},
538
+ "order": 22,
539
+ "mode": 0,
540
+ "inputs": [
541
+ {
542
+ "name": "samples",
543
+ "type": "LATENT",
544
+ "link": 312
545
+ },
546
+ {
547
+ "name": "mask",
548
+ "type": "MASK",
549
+ "link": 273
550
+ }
551
+ ],
552
+ "outputs": [
553
+ {
554
+ "name": "LATENT",
555
+ "type": "LATENT",
556
+ "links": [
557
+ 284
558
+ ]
559
+ }
560
+ ],
561
+ "properties": {
562
+ "cnr_id": "comfy-core",
563
+ "ver": "0.3.51",
564
+ "Node name for S&R": "SetLatentNoiseMask"
565
+ },
566
+ "widgets_values": []
567
+ },
568
+ {
569
+ "id": 147,
570
+ "type": "VAEEncode",
571
+ "pos": [
572
+ 381.33148193359375,
573
+ 639.6804809570312
574
+ ],
575
+ "size": [
576
+ 140,
577
+ 46
578
+ ],
579
+ "flags": {},
580
+ "order": 20,
581
+ "mode": 0,
582
+ "inputs": [
583
+ {
584
+ "name": "pixels",
585
+ "type": "IMAGE",
586
+ "link": 311
587
+ },
588
+ {
589
+ "name": "vae",
590
+ "type": "VAE",
591
+ "link": 313
592
+ }
593
+ ],
594
+ "outputs": [
595
+ {
596
+ "name": "LATENT",
597
+ "type": "LATENT",
598
+ "links": [
599
+ 312
600
+ ]
601
+ }
602
+ ],
603
+ "properties": {
604
+ "cnr_id": "comfy-core",
605
+ "ver": "0.3.50",
606
+ "Node name for S&R": "VAEEncode",
607
+ "enableTabs": false,
608
+ "tabWidth": 65,
609
+ "tabXOffset": 10,
610
+ "hasSecondTab": false,
611
+ "secondTabText": "Send Back",
612
+ "secondTabOffset": 80,
613
+ "secondTabWidth": 65,
614
+ "ue_properties": {
615
+ "widget_ue_connectable": {}
616
+ }
617
+ }
618
+ },
619
+ {
620
+ "id": 126,
621
+ "type": "VAELoader",
622
+ "pos": [
623
+ -249.80447387695312,
624
+ 337.1279296875
625
+ ],
626
+ "size": [
627
+ 330,
628
+ 60
629
+ ],
630
+ "flags": {},
631
+ "order": 4,
632
+ "mode": 0,
633
+ "inputs": [],
634
+ "outputs": [
635
+ {
636
+ "name": "VAE",
637
+ "type": "VAE",
638
+ "slot_index": 0,
639
+ "links": [
640
+ 256,
641
+ 258,
642
+ 276,
643
+ 288,
644
+ 296,
645
+ 313
646
+ ]
647
+ }
648
+ ],
649
+ "properties": {
650
+ "cnr_id": "comfy-core",
651
+ "ver": "0.3.48",
652
+ "Node name for S&R": "VAELoader",
653
+ "models": [
654
+ {
655
+ "name": "qwen_image_vae.safetensors",
656
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/vae/qwen_image_vae.safetensors",
657
+ "directory": "vae"
658
+ }
659
+ ],
660
+ "enableTabs": false,
661
+ "tabWidth": 65,
662
+ "tabXOffset": 10,
663
+ "hasSecondTab": false,
664
+ "secondTabText": "Send Back",
665
+ "secondTabOffset": 80,
666
+ "secondTabWidth": 65,
667
+ "widget_ue_connectable": {}
668
+ },
669
+ "widgets_values": [
670
+ "qwen_image_vae.safetensors"
671
+ ]
672
+ },
673
+ {
674
+ "id": 142,
675
+ "type": "VAEDecode",
676
+ "pos": [
677
+ -468.50421142578125,
678
+ 1343.047119140625
679
+ ],
680
+ "size": [
681
+ 210,
682
+ 46
683
+ ],
684
+ "flags": {},
685
+ "order": 14,
686
+ "mode": 0,
687
+ "inputs": [
688
+ {
689
+ "name": "samples",
690
+ "type": "LATENT",
691
+ "link": 294
692
+ },
693
+ {
694
+ "name": "vae",
695
+ "type": "VAE",
696
+ "link": 296
697
+ }
698
+ ],
699
+ "outputs": [
700
+ {
701
+ "name": "IMAGE",
702
+ "type": "IMAGE",
703
+ "slot_index": 0,
704
+ "links": [
705
+ 297
706
+ ]
707
+ }
708
+ ],
709
+ "properties": {
710
+ "cnr_id": "comfy-core",
711
+ "ver": "0.3.23",
712
+ "Node name for S&R": "VAEDecode"
713
+ }
714
+ },
715
+ {
716
+ "id": 144,
717
+ "type": "ImageScale",
718
+ "pos": [
719
+ -163.11903381347656,
720
+ 1055.310546875
721
+ ],
722
+ "size": [
723
+ 270,
724
+ 130
725
+ ],
726
+ "flags": {},
727
+ "order": 16,
728
+ "mode": 0,
729
+ "inputs": [
730
+ {
731
+ "name": "image",
732
+ "type": "IMAGE",
733
+ "link": 314
734
+ },
735
+ {
736
+ "name": "width",
737
+ "type": "INT",
738
+ "widget": {
739
+ "name": "width"
740
+ },
741
+ "link": 298
742
+ },
743
+ {
744
+ "name": "height",
745
+ "type": "INT",
746
+ "widget": {
747
+ "name": "height"
748
+ },
749
+ "link": 299
750
+ }
751
+ ],
752
+ "outputs": [
753
+ {
754
+ "name": "IMAGE",
755
+ "type": "IMAGE",
756
+ "links": [
757
+ 306,
758
+ 307,
759
+ 309,
760
+ 311
761
+ ]
762
+ }
763
+ ],
764
+ "properties": {
765
+ "cnr_id": "comfy-core",
766
+ "ver": "0.3.52",
767
+ "Node name for S&R": "ImageScale"
768
+ },
769
+ "widgets_values": [
770
+ "nearest-exact",
771
+ 512,
772
+ 512,
773
+ "center"
774
+ ]
775
+ },
776
+ {
777
+ "id": 110,
778
+ "type": "LoadImage",
779
+ "pos": [
780
+ -224.69882202148438,
781
+ 491.67425537109375
782
+ ],
783
+ "size": [
784
+ 274.080078125,
785
+ 314.0000305175781
786
+ ],
787
+ "flags": {},
788
+ "order": 5,
789
+ "mode": 0,
790
+ "inputs": [],
791
+ "outputs": [
792
+ {
793
+ "name": "IMAGE",
794
+ "type": "IMAGE",
795
+ "links": [
796
+ 275,
797
+ 314
798
+ ]
799
+ },
800
+ {
801
+ "name": "MASK",
802
+ "type": "MASK",
803
+ "links": [
804
+ 277
805
+ ]
806
+ }
807
+ ],
808
+ "properties": {
809
+ "cnr_id": "comfy-core",
810
+ "ver": "0.3.50",
811
+ "Node name for S&R": "LoadImage",
812
+ "enableTabs": false,
813
+ "tabWidth": 65,
814
+ "tabXOffset": 10,
815
+ "hasSecondTab": false,
816
+ "secondTabText": "Send Back",
817
+ "secondTabOffset": 80,
818
+ "secondTabWidth": 65,
819
+ "ue_properties": {
820
+ "widget_ue_connectable": {
821
+ "image": true,
822
+ "upload": true
823
+ }
824
+ }
825
+ },
826
+ "widgets_values": [
827
+ "clipspace/clipspace-painted-masked-23308506.png [input]",
828
+ "image"
829
+ ]
830
+ },
831
+ {
832
+ "id": 136,
833
+ "type": "MaskToImage",
834
+ "pos": [
835
+ -121.25953674316406,
836
+ 1228.22509765625
837
+ ],
838
+ "size": [
839
+ 184.62362670898438,
840
+ 26
841
+ ],
842
+ "flags": {},
843
+ "order": 10,
844
+ "mode": 0,
845
+ "inputs": [
846
+ {
847
+ "name": "mask",
848
+ "type": "MASK",
849
+ "link": 277
850
+ }
851
+ ],
852
+ "outputs": [
853
+ {
854
+ "name": "IMAGE",
855
+ "type": "IMAGE",
856
+ "links": [
857
+ 315
858
+ ]
859
+ }
860
+ ],
861
+ "properties": {
862
+ "cnr_id": "comfy-core",
863
+ "ver": "0.3.51",
864
+ "Node name for S&R": "MaskToImage"
865
+ },
866
+ "widgets_values": []
867
+ },
868
+ {
869
+ "id": 133,
870
+ "type": "ImageToMask",
871
+ "pos": [
872
+ -164.2398681640625,
873
+ 1480.3736572265625
874
+ ],
875
+ "size": [
876
+ 270,
877
+ 58
878
+ ],
879
+ "flags": {},
880
+ "order": 21,
881
+ "mode": 0,
882
+ "inputs": [
883
+ {
884
+ "name": "image",
885
+ "type": "IMAGE",
886
+ "link": 305
887
+ }
888
+ ],
889
+ "outputs": [
890
+ {
891
+ "name": "MASK",
892
+ "type": "MASK",
893
+ "links": [
894
+ 273,
895
+ 290
896
+ ]
897
+ }
898
+ ],
899
+ "properties": {
900
+ "cnr_id": "comfy-core",
901
+ "ver": "0.3.51",
902
+ "Node name for S&R": "ImageToMask"
903
+ },
904
+ "widgets_values": [
905
+ "red"
906
+ ]
907
+ },
908
+ {
909
+ "id": 96,
910
+ "type": "MarkdownNote",
911
+ "pos": [
912
+ -548.3401489257812,
913
+ 1051.436279296875
914
+ ],
915
+ "size": [
916
+ 280,
917
+ 88
918
+ ],
919
+ "flags": {},
920
+ "order": 6,
921
+ "mode": 0,
922
+ "inputs": [],
923
+ "outputs": [],
924
+ "properties": {},
925
+ "widgets_values": [
926
+ "This node is to avoid poor output results caused by excessively large input image sizes."
927
+ ],
928
+ "color": "#432",
929
+ "bgcolor": "#653"
930
+ },
931
+ {
932
+ "id": 135,
933
+ "type": "VAEEncode",
934
+ "pos": [
935
+ -453.77728271484375,
936
+ 1250.4849853515625
937
+ ],
938
+ "size": [
939
+ 140,
940
+ 46
941
+ ],
942
+ "flags": {},
943
+ "order": 12,
944
+ "mode": 0,
945
+ "inputs": [
946
+ {
947
+ "name": "pixels",
948
+ "type": "IMAGE",
949
+ "link": 310
950
+ },
951
+ {
952
+ "name": "vae",
953
+ "type": "VAE",
954
+ "link": 276
955
+ }
956
+ ],
957
+ "outputs": [
958
+ {
959
+ "name": "LATENT",
960
+ "type": "LATENT",
961
+ "links": [
962
+ 294
963
+ ]
964
+ }
965
+ ],
966
+ "properties": {
967
+ "cnr_id": "comfy-core",
968
+ "ver": "0.3.50",
969
+ "Node name for S&R": "VAEEncode",
970
+ "enableTabs": false,
971
+ "tabWidth": 65,
972
+ "tabXOffset": 10,
973
+ "hasSecondTab": false,
974
+ "secondTabText": "Send Back",
975
+ "secondTabOffset": 80,
976
+ "secondTabWidth": 65,
977
+ "ue_properties": {
978
+ "widget_ue_connectable": {}
979
+ }
980
+ },
981
+ "widgets_values": []
982
+ },
983
+ {
984
+ "id": 146,
985
+ "type": "ImageScale",
986
+ "pos": [
987
+ -165.53955078125,
988
+ 1306.8914794921875
989
+ ],
990
+ "size": [
991
+ 270,
992
+ 130
993
+ ],
994
+ "flags": {},
995
+ "order": 17,
996
+ "mode": 0,
997
+ "inputs": [
998
+ {
999
+ "name": "image",
1000
+ "type": "IMAGE",
1001
+ "link": 315
1002
+ },
1003
+ {
1004
+ "name": "width",
1005
+ "type": "INT",
1006
+ "widget": {
1007
+ "name": "width"
1008
+ },
1009
+ "link": 301
1010
+ },
1011
+ {
1012
+ "name": "height",
1013
+ "type": "INT",
1014
+ "widget": {
1015
+ "name": "height"
1016
+ },
1017
+ "link": 302
1018
+ }
1019
+ ],
1020
+ "outputs": [
1021
+ {
1022
+ "name": "IMAGE",
1023
+ "type": "IMAGE",
1024
+ "links": [
1025
+ 305
1026
+ ]
1027
+ }
1028
+ ],
1029
+ "properties": {
1030
+ "cnr_id": "comfy-core",
1031
+ "ver": "0.3.52",
1032
+ "Node name for S&R": "ImageScale"
1033
+ },
1034
+ "widgets_values": [
1035
+ "nearest-exact",
1036
+ 512,
1037
+ 512,
1038
+ "center"
1039
+ ]
1040
+ },
1041
+ {
1042
+ "id": 140,
1043
+ "type": "MarkdownNote",
1044
+ "pos": [
1045
+ 1361.85009765625,
1046
+ 360.32342529296875
1047
+ ],
1048
+ "size": [
1049
+ 300,
1050
+ 190
1051
+ ],
1052
+ "flags": {},
1053
+ "order": 7,
1054
+ "mode": 0,
1055
+ "inputs": [],
1056
+ "outputs": [],
1057
+ "title": "KSampler settings",
1058
+ "properties": {},
1059
+ "widgets_values": [
1060
+ "Decrease **LanPaint_NumSteps** for faster generation. \n"
1061
+ ],
1062
+ "color": "#432",
1063
+ "bgcolor": "#653"
1064
+ },
1065
+ {
1066
+ "id": 145,
1067
+ "type": "GetImageSize",
1068
+ "pos": [
1069
+ -456.3453063964844,
1070
+ 1442.398193359375
1071
+ ],
1072
+ "size": [
1073
+ 140,
1074
+ 124
1075
+ ],
1076
+ "flags": {},
1077
+ "order": 15,
1078
+ "mode": 0,
1079
+ "inputs": [
1080
+ {
1081
+ "name": "image",
1082
+ "type": "IMAGE",
1083
+ "link": 297
1084
+ }
1085
+ ],
1086
+ "outputs": [
1087
+ {
1088
+ "name": "width",
1089
+ "type": "INT",
1090
+ "links": [
1091
+ 298,
1092
+ 301
1093
+ ]
1094
+ },
1095
+ {
1096
+ "name": "height",
1097
+ "type": "INT",
1098
+ "links": [
1099
+ 299,
1100
+ 302
1101
+ ]
1102
+ },
1103
+ {
1104
+ "name": "batch_size",
1105
+ "type": "INT",
1106
+ "links": null
1107
+ }
1108
+ ],
1109
+ "properties": {
1110
+ "cnr_id": "comfy-core",
1111
+ "ver": "0.3.52",
1112
+ "Node name for S&R": "GetImageSize"
1113
+ },
1114
+ "widgets_values": [
1115
+ "width: 1024, height: 1024\n batch size: 1"
1116
+ ]
1117
+ },
1118
+ {
1119
+ "id": 131,
1120
+ "type": "ImageScaleToTotalPixels",
1121
+ "pos": [
1122
+ -851.1531982421875,
1123
+ 1230.9898681640625
1124
+ ],
1125
+ "size": [
1126
+ 270,
1127
+ 82
1128
+ ],
1129
+ "flags": {},
1130
+ "order": 9,
1131
+ "mode": 0,
1132
+ "inputs": [
1133
+ {
1134
+ "name": "image",
1135
+ "type": "IMAGE",
1136
+ "link": 275
1137
+ }
1138
+ ],
1139
+ "outputs": [
1140
+ {
1141
+ "name": "IMAGE",
1142
+ "type": "IMAGE",
1143
+ "links": [
1144
+ 310
1145
+ ]
1146
+ }
1147
+ ],
1148
+ "properties": {
1149
+ "cnr_id": "comfy-core",
1150
+ "ver": "0.3.50",
1151
+ "Node name for S&R": "ImageScaleToTotalPixels",
1152
+ "enableTabs": false,
1153
+ "tabWidth": 65,
1154
+ "tabXOffset": 10,
1155
+ "hasSecondTab": false,
1156
+ "secondTabText": "Send Back",
1157
+ "secondTabOffset": 80,
1158
+ "secondTabWidth": 65,
1159
+ "ue_properties": {
1160
+ "widget_ue_connectable": {
1161
+ "upscale_method": true,
1162
+ "megapixels": true
1163
+ }
1164
+ }
1165
+ },
1166
+ "widgets_values": [
1167
+ "nearest-exact",
1168
+ 1
1169
+ ]
1170
+ },
1171
+ {
1172
+ "id": 102,
1173
+ "type": "LanPaint_KSampler",
1174
+ "pos": [
1175
+ 935.6971435546875,
1176
+ 22.220111846923828
1177
+ ],
1178
+ "size": [
1179
+ 400,
1180
+ 572
1181
+ ],
1182
+ "flags": {},
1183
+ "order": 23,
1184
+ "mode": 0,
1185
+ "inputs": [
1186
+ {
1187
+ "name": "model",
1188
+ "type": "MODEL",
1189
+ "link": 269
1190
+ },
1191
+ {
1192
+ "name": "positive",
1193
+ "type": "CONDITIONING",
1194
+ "link": 267
1195
+ },
1196
+ {
1197
+ "name": "negative",
1198
+ "type": "CONDITIONING",
1199
+ "link": 268
1200
+ },
1201
+ {
1202
+ "name": "latent_image",
1203
+ "type": "LATENT",
1204
+ "link": 284
1205
+ }
1206
+ ],
1207
+ "outputs": [
1208
+ {
1209
+ "name": "LATENT",
1210
+ "type": "LATENT",
1211
+ "links": [
1212
+ 287
1213
+ ]
1214
+ }
1215
+ ],
1216
+ "properties": {
1217
+ "cnr_id": "LanPaint",
1218
+ "ver": "453b6c090e400123bb82f5bc0c97854031b09274",
1219
+ "Node name for S&R": "LanPaint_KSampler"
1220
+ },
1221
+ "widgets_values": [
1222
+ 0,
1223
+ "fixed",
1224
+ 20,
1225
+ 2.5,
1226
+ "euler",
1227
+ "simple",
1228
+ 1,
1229
+ 5,
1230
+ "Image First",
1231
+ "LanPaint KSampler. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!"
1232
+ ]
1233
+ },
1234
+ {
1235
+ "id": 137,
1236
+ "type": "VAEDecode",
1237
+ "pos": [
1238
+ 1453.6231689453125,
1239
+ 22.1680850982666
1240
+ ],
1241
+ "size": [
1242
+ 210,
1243
+ 46
1244
+ ],
1245
+ "flags": {},
1246
+ "order": 24,
1247
+ "mode": 0,
1248
+ "inputs": [
1249
+ {
1250
+ "name": "samples",
1251
+ "type": "LATENT",
1252
+ "link": 287
1253
+ },
1254
+ {
1255
+ "name": "vae",
1256
+ "type": "VAE",
1257
+ "link": 288
1258
+ }
1259
+ ],
1260
+ "outputs": [
1261
+ {
1262
+ "name": "IMAGE",
1263
+ "type": "IMAGE",
1264
+ "slot_index": 0,
1265
+ "links": [
1266
+ 286
1267
+ ]
1268
+ }
1269
+ ],
1270
+ "properties": {
1271
+ "cnr_id": "comfy-core",
1272
+ "ver": "0.3.23",
1273
+ "Node name for S&R": "VAEDecode"
1274
+ },
1275
+ "widgets_values": []
1276
+ }
1277
+ ],
1278
+ "links": [
1279
+ [
1280
+ 255,
1281
+ 125,
1282
+ 0,
1283
+ 127,
1284
+ 0,
1285
+ "CLIP"
1286
+ ],
1287
+ [
1288
+ 256,
1289
+ 126,
1290
+ 0,
1291
+ 127,
1292
+ 1,
1293
+ "VAE"
1294
+ ],
1295
+ [
1296
+ 257,
1297
+ 125,
1298
+ 0,
1299
+ 128,
1300
+ 0,
1301
+ "CLIP"
1302
+ ],
1303
+ [
1304
+ 258,
1305
+ 126,
1306
+ 0,
1307
+ 128,
1308
+ 1,
1309
+ "VAE"
1310
+ ],
1311
+ [
1312
+ 260,
1313
+ 129,
1314
+ 0,
1315
+ 130,
1316
+ 0,
1317
+ "MODEL"
1318
+ ],
1319
+ [
1320
+ 267,
1321
+ 127,
1322
+ 0,
1323
+ 102,
1324
+ 1,
1325
+ "CONDITIONING"
1326
+ ],
1327
+ [
1328
+ 268,
1329
+ 128,
1330
+ 0,
1331
+ 102,
1332
+ 2,
1333
+ "CONDITIONING"
1334
+ ],
1335
+ [
1336
+ 269,
1337
+ 130,
1338
+ 0,
1339
+ 102,
1340
+ 0,
1341
+ "MODEL"
1342
+ ],
1343
+ [
1344
+ 273,
1345
+ 133,
1346
+ 0,
1347
+ 134,
1348
+ 1,
1349
+ "MASK"
1350
+ ],
1351
+ [
1352
+ 275,
1353
+ 110,
1354
+ 0,
1355
+ 131,
1356
+ 0,
1357
+ "IMAGE"
1358
+ ],
1359
+ [
1360
+ 276,
1361
+ 126,
1362
+ 0,
1363
+ 135,
1364
+ 1,
1365
+ "VAE"
1366
+ ],
1367
+ [
1368
+ 277,
1369
+ 110,
1370
+ 1,
1371
+ 136,
1372
+ 0,
1373
+ "MASK"
1374
+ ],
1375
+ [
1376
+ 284,
1377
+ 134,
1378
+ 0,
1379
+ 102,
1380
+ 3,
1381
+ "LATENT"
1382
+ ],
1383
+ [
1384
+ 286,
1385
+ 137,
1386
+ 0,
1387
+ 138,
1388
+ 1,
1389
+ "IMAGE"
1390
+ ],
1391
+ [
1392
+ 287,
1393
+ 102,
1394
+ 0,
1395
+ 137,
1396
+ 0,
1397
+ "LATENT"
1398
+ ],
1399
+ [
1400
+ 288,
1401
+ 126,
1402
+ 0,
1403
+ 137,
1404
+ 1,
1405
+ "VAE"
1406
+ ],
1407
+ [
1408
+ 290,
1409
+ 133,
1410
+ 0,
1411
+ 138,
1412
+ 2,
1413
+ "MASK"
1414
+ ],
1415
+ [
1416
+ 291,
1417
+ 138,
1418
+ 0,
1419
+ 104,
1420
+ 0,
1421
+ "IMAGE"
1422
+ ],
1423
+ [
1424
+ 292,
1425
+ 124,
1426
+ 0,
1427
+ 141,
1428
+ 0,
1429
+ "MODEL"
1430
+ ],
1431
+ [
1432
+ 293,
1433
+ 141,
1434
+ 0,
1435
+ 129,
1436
+ 0,
1437
+ "MODEL"
1438
+ ],
1439
+ [
1440
+ 294,
1441
+ 135,
1442
+ 0,
1443
+ 142,
1444
+ 0,
1445
+ "LATENT"
1446
+ ],
1447
+ [
1448
+ 296,
1449
+ 126,
1450
+ 0,
1451
+ 142,
1452
+ 1,
1453
+ "VAE"
1454
+ ],
1455
+ [
1456
+ 297,
1457
+ 142,
1458
+ 0,
1459
+ 145,
1460
+ 0,
1461
+ "IMAGE"
1462
+ ],
1463
+ [
1464
+ 298,
1465
+ 145,
1466
+ 0,
1467
+ 144,
1468
+ 1,
1469
+ "INT"
1470
+ ],
1471
+ [
1472
+ 299,
1473
+ 145,
1474
+ 1,
1475
+ 144,
1476
+ 2,
1477
+ "INT"
1478
+ ],
1479
+ [
1480
+ 301,
1481
+ 145,
1482
+ 0,
1483
+ 146,
1484
+ 1,
1485
+ "INT"
1486
+ ],
1487
+ [
1488
+ 302,
1489
+ 145,
1490
+ 1,
1491
+ 146,
1492
+ 2,
1493
+ "INT"
1494
+ ],
1495
+ [
1496
+ 305,
1497
+ 146,
1498
+ 0,
1499
+ 133,
1500
+ 0,
1501
+ "IMAGE"
1502
+ ],
1503
+ [
1504
+ 306,
1505
+ 144,
1506
+ 0,
1507
+ 127,
1508
+ 2,
1509
+ "IMAGE"
1510
+ ],
1511
+ [
1512
+ 307,
1513
+ 144,
1514
+ 0,
1515
+ 128,
1516
+ 2,
1517
+ "IMAGE"
1518
+ ],
1519
+ [
1520
+ 309,
1521
+ 144,
1522
+ 0,
1523
+ 138,
1524
+ 0,
1525
+ "IMAGE"
1526
+ ],
1527
+ [
1528
+ 310,
1529
+ 131,
1530
+ 0,
1531
+ 135,
1532
+ 0,
1533
+ "IMAGE"
1534
+ ],
1535
+ [
1536
+ 311,
1537
+ 144,
1538
+ 0,
1539
+ 147,
1540
+ 0,
1541
+ "IMAGE"
1542
+ ],
1543
+ [
1544
+ 312,
1545
+ 147,
1546
+ 0,
1547
+ 134,
1548
+ 0,
1549
+ "LATENT"
1550
+ ],
1551
+ [
1552
+ 313,
1553
+ 126,
1554
+ 0,
1555
+ 147,
1556
+ 1,
1557
+ "VAE"
1558
+ ],
1559
+ [
1560
+ 314,
1561
+ 110,
1562
+ 0,
1563
+ 144,
1564
+ 0,
1565
+ "IMAGE"
1566
+ ],
1567
+ [
1568
+ 315,
1569
+ 136,
1570
+ 0,
1571
+ 146,
1572
+ 0,
1573
+ "IMAGE"
1574
+ ]
1575
+ ],
1576
+ "groups": [
1577
+ {
1578
+ "id": 1,
1579
+ "title": "Step1 - Load models",
1580
+ "bounding": [
1581
+ -270,
1582
+ -40,
1583
+ 370,
1584
+ 450
1585
+ ],
1586
+ "color": "#3f789e",
1587
+ "font_size": 24,
1588
+ "flags": {}
1589
+ },
1590
+ {
1591
+ "id": 2,
1592
+ "title": "Step 2 - Upload image for editing",
1593
+ "bounding": [
1594
+ -270,
1595
+ 430,
1596
+ 370,
1597
+ 400
1598
+ ],
1599
+ "color": "#3f789e",
1600
+ "font_size": 24,
1601
+ "flags": {}
1602
+ },
1603
+ {
1604
+ "id": 3,
1605
+ "title": "Step 3 - Prompt",
1606
+ "bounding": [
1607
+ 130,
1608
+ 130,
1609
+ 380,
1610
+ 433.6000061035156
1611
+ ],
1612
+ "color": "#3f789e",
1613
+ "font_size": 24,
1614
+ "flags": {}
1615
+ }
1616
+ ],
1617
+ "config": {},
1618
+ "extra": {
1619
+ "ds": {
1620
+ "scale": 0.8770472573513671,
1621
+ "offset": [
1622
+ -1288.739882247765,
1623
+ 215.50013247190662
1624
+ ]
1625
+ },
1626
+ "frontendVersion": "1.25.10",
1627
+ "ue_links": [],
1628
+ "links_added_by_ue": [],
1629
+ "VHS_latentpreview": false,
1630
+ "VHS_latentpreviewrate": 0,
1631
+ "VHS_MetadataImage": true,
1632
+ "VHS_KeepIntermediate": true,
1633
+ "groupNodes": {}
1634
+ },
1635
+ "version": 0.4
1636
+ }
LanPaint/example_workflows/Masked_Qwen_Image_Edit_2509.jpg ADDED

Git LFS Details

  • SHA256: 9994fe2e38218474e755959c00ab081c7e90565746132cba359da98b57240a76
  • Pointer size: 131 Bytes
  • Size of remote file: 690 kB
LanPaint/example_workflows/Masked_Qwen_Image_Edit_2509.json ADDED
@@ -0,0 +1,1829 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "91f6bbe2-ed41-4fd6-bac7-71d5b5864ecb",
3
+ "revision": 0,
4
+ "last_node_id": 127,
5
+ "last_link_id": 252,
6
+ "nodes": [
7
+ {
8
+ "id": 38,
9
+ "type": "CLIPLoader",
10
+ "pos": [
11
+ -250,
12
+ 160
13
+ ],
14
+ "size": [
15
+ 330,
16
+ 110
17
+ ],
18
+ "flags": {},
19
+ "order": 0,
20
+ "mode": 0,
21
+ "inputs": [],
22
+ "outputs": [
23
+ {
24
+ "name": "CLIP",
25
+ "type": "CLIP",
26
+ "slot_index": 0,
27
+ "links": [
28
+ 204,
29
+ 205
30
+ ]
31
+ }
32
+ ],
33
+ "properties": {
34
+ "cnr_id": "comfy-core",
35
+ "ver": "0.3.48",
36
+ "Node name for S&R": "CLIPLoader",
37
+ "models": [
38
+ {
39
+ "name": "qwen_2.5_vl_7b_fp8_scaled.safetensors",
40
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/text_encoders/qwen_2.5_vl_7b_fp8_scaled.safetensors",
41
+ "directory": "text_encoders"
42
+ }
43
+ ],
44
+ "enableTabs": false,
45
+ "tabWidth": 65,
46
+ "tabXOffset": 10,
47
+ "hasSecondTab": false,
48
+ "secondTabText": "Send Back",
49
+ "secondTabOffset": 80,
50
+ "secondTabWidth": 65,
51
+ "widget_ue_connectable": {}
52
+ },
53
+ "widgets_values": [
54
+ "qwen_2.5_vl_7b_fp8_scaled.safetensors",
55
+ "qwen_image",
56
+ "default"
57
+ ]
58
+ },
59
+ {
60
+ "id": 66,
61
+ "type": "ModelSamplingAuraFlow",
62
+ "pos": [
63
+ 740,
64
+ -130
65
+ ],
66
+ "size": [
67
+ 290,
68
+ 60
69
+ ],
70
+ "flags": {},
71
+ "order": 17,
72
+ "mode": 0,
73
+ "inputs": [
74
+ {
75
+ "name": "model",
76
+ "type": "MODEL",
77
+ "link": 185
78
+ }
79
+ ],
80
+ "outputs": [
81
+ {
82
+ "name": "MODEL",
83
+ "type": "MODEL",
84
+ "links": [
85
+ 141
86
+ ]
87
+ }
88
+ ],
89
+ "properties": {
90
+ "cnr_id": "comfy-core",
91
+ "ver": "0.3.48",
92
+ "Node name for S&R": "ModelSamplingAuraFlow",
93
+ "enableTabs": false,
94
+ "tabWidth": 65,
95
+ "tabXOffset": 10,
96
+ "hasSecondTab": false,
97
+ "secondTabText": "Send Back",
98
+ "secondTabOffset": 80,
99
+ "secondTabWidth": 65,
100
+ "widget_ue_connectable": {}
101
+ },
102
+ "widgets_values": [
103
+ 3
104
+ ]
105
+ },
106
+ {
107
+ "id": 106,
108
+ "type": "LoadImage",
109
+ "pos": [
110
+ 56.080078125,
111
+ 530
112
+ ],
113
+ "size": [
114
+ 274.080078125,
115
+ 314.0000305175781
116
+ ],
117
+ "flags": {},
118
+ "order": 1,
119
+ "mode": 4,
120
+ "inputs": [],
121
+ "outputs": [
122
+ {
123
+ "name": "IMAGE",
124
+ "type": "IMAGE",
125
+ "links": [
126
+ 219,
127
+ 220
128
+ ]
129
+ },
130
+ {
131
+ "name": "MASK",
132
+ "type": "MASK",
133
+ "links": null
134
+ }
135
+ ],
136
+ "properties": {
137
+ "cnr_id": "comfy-core",
138
+ "ver": "0.3.50",
139
+ "Node name for S&R": "LoadImage",
140
+ "enableTabs": false,
141
+ "tabWidth": 65,
142
+ "tabXOffset": 10,
143
+ "hasSecondTab": false,
144
+ "secondTabText": "Send Back",
145
+ "secondTabOffset": 80,
146
+ "secondTabWidth": 65,
147
+ "ue_properties": {
148
+ "widget_ue_connectable": {
149
+ "image": true,
150
+ "upload": true
151
+ }
152
+ }
153
+ },
154
+ "widgets_values": [
155
+ "0_1 (5).png",
156
+ "image"
157
+ ]
158
+ },
159
+ {
160
+ "id": 108,
161
+ "type": "LoadImage",
162
+ "pos": [
163
+ 352.16015625,
164
+ 530
165
+ ],
166
+ "size": [
167
+ 274.080078125,
168
+ 314.0000305175781
169
+ ],
170
+ "flags": {},
171
+ "order": 2,
172
+ "mode": 4,
173
+ "inputs": [],
174
+ "outputs": [
175
+ {
176
+ "name": "IMAGE",
177
+ "type": "IMAGE",
178
+ "links": [
179
+ 217,
180
+ 218
181
+ ]
182
+ },
183
+ {
184
+ "name": "MASK",
185
+ "type": "MASK",
186
+ "links": null
187
+ }
188
+ ],
189
+ "properties": {
190
+ "cnr_id": "comfy-core",
191
+ "ver": "0.3.50",
192
+ "Node name for S&R": "LoadImage",
193
+ "enableTabs": false,
194
+ "tabWidth": 65,
195
+ "tabXOffset": 10,
196
+ "hasSecondTab": false,
197
+ "secondTabText": "Send Back",
198
+ "secondTabOffset": 80,
199
+ "secondTabWidth": 65,
200
+ "ue_properties": {
201
+ "widget_ue_connectable": {
202
+ "image": true,
203
+ "upload": true
204
+ }
205
+ }
206
+ },
207
+ "widgets_values": [
208
+ "pose.png",
209
+ "image"
210
+ ]
211
+ },
212
+ {
213
+ "id": 112,
214
+ "type": "EmptySD3LatentImage",
215
+ "pos": [
216
+ 750,
217
+ 860
218
+ ],
219
+ "size": [
220
+ 270,
221
+ 106
222
+ ],
223
+ "flags": {},
224
+ "order": 3,
225
+ "mode": 0,
226
+ "inputs": [],
227
+ "outputs": [
228
+ {
229
+ "name": "LATENT",
230
+ "type": "LATENT",
231
+ "links": []
232
+ }
233
+ ],
234
+ "properties": {
235
+ "cnr_id": "comfy-core",
236
+ "ver": "0.3.59",
237
+ "Node name for S&R": "EmptySD3LatentImage"
238
+ },
239
+ "widgets_values": [
240
+ 1024,
241
+ 1024,
242
+ 1
243
+ ]
244
+ },
245
+ {
246
+ "id": 113,
247
+ "type": "MarkdownNote",
248
+ "pos": [
249
+ 730,
250
+ 1030
251
+ ],
252
+ "size": [
253
+ 330,
254
+ 90
255
+ ],
256
+ "flags": {},
257
+ "order": 4,
258
+ "mode": 0,
259
+ "inputs": [],
260
+ "outputs": [],
261
+ "title": "Note: About image size",
262
+ "properties": {},
263
+ "widgets_values": [
264
+ "You can use the latent from the **EmptySD3LatentImage** to replace **VAE Encode**, so you can customize the image size."
265
+ ],
266
+ "color": "#432",
267
+ "bgcolor": "#653"
268
+ },
269
+ {
270
+ "id": 97,
271
+ "type": "MarkdownNote",
272
+ "pos": [
273
+ 740,
274
+ 610
275
+ ],
276
+ "size": [
277
+ 300,
278
+ 160
279
+ ],
280
+ "flags": {},
281
+ "order": 5,
282
+ "mode": 0,
283
+ "inputs": [],
284
+ "outputs": [],
285
+ "title": "Note: KSampler settings",
286
+ "properties": {},
287
+ "widgets_values": [
288
+ "You can test and find the best setting by yourself. The following table is for reference.\n\n| Model | Steps | CFG |\n|---------------------|---------------|---------------|\n| Offical | 50 | 4.0 \n| fp8_e4m3fn | 20 | 2.5 |\n| fp8_e4m3fn + 4steps LoRA | 4 | 1.0 |\n"
289
+ ],
290
+ "color": "#432",
291
+ "bgcolor": "#653"
292
+ },
293
+ {
294
+ "id": 110,
295
+ "type": "TextEncodeQwenImageEditPlus",
296
+ "pos": [
297
+ 220.83323669433594,
298
+ 178.33360290527344
299
+ ],
300
+ "size": [
301
+ 400,
302
+ 200
303
+ ],
304
+ "flags": {},
305
+ "order": 15,
306
+ "mode": 0,
307
+ "inputs": [
308
+ {
309
+ "name": "clip",
310
+ "type": "CLIP",
311
+ "link": 204
312
+ },
313
+ {
314
+ "name": "vae",
315
+ "shape": 7,
316
+ "type": "VAE",
317
+ "link": 206
318
+ },
319
+ {
320
+ "name": "image1",
321
+ "shape": 7,
322
+ "type": "IMAGE",
323
+ "link": 225
324
+ },
325
+ {
326
+ "name": "image2",
327
+ "shape": 7,
328
+ "type": "IMAGE",
329
+ "link": 220
330
+ },
331
+ {
332
+ "name": "image3",
333
+ "shape": 7,
334
+ "type": "IMAGE",
335
+ "link": 218
336
+ }
337
+ ],
338
+ "outputs": [
339
+ {
340
+ "name": "CONDITIONING",
341
+ "type": "CONDITIONING",
342
+ "links": [
343
+ 245
344
+ ]
345
+ }
346
+ ],
347
+ "properties": {
348
+ "cnr_id": "comfy-core",
349
+ "ver": "0.3.59",
350
+ "Node name for S&R": "TextEncodeQwenImageEditPlus"
351
+ },
352
+ "widgets_values": [
353
+ ""
354
+ ],
355
+ "color": "#223",
356
+ "bgcolor": "#335"
357
+ },
358
+ {
359
+ "id": 99,
360
+ "type": "MarkdownNote",
361
+ "pos": [
362
+ -840,
363
+ -140
364
+ ],
365
+ "size": [
366
+ 550,
367
+ 550
368
+ ],
369
+ "flags": {},
370
+ "order": 6,
371
+ "mode": 0,
372
+ "inputs": [],
373
+ "outputs": [],
374
+ "title": "Model links",
375
+ "properties": {
376
+ "widget_ue_connectable": {}
377
+ },
378
+ "widgets_values": [
379
+ "[Tutorial](https://docs.comfy.org/tutorials/image/qwen/qwen-image-edit) | [教程](https://docs.comfy.org/zh-CN/tutorials/image/qwen/qwen-image-edit)\n\n\n## Model links\n\nYou can find all the models on [Comfy-Org/Qwen-Image_ComfyUI](https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/tree/main) and [Comfy-Org/Qwen-Image-Edit_ComfyUI](https://huggingface.co/Comfy-Org/Qwen-Image-Edit_ComfyUI) \n\n**Diffusion model**\n\n- [qwen_image_edit_2509_fp8_e4m3fn.safetensors](https://huggingface.co/Comfy-Org/Qwen-Image-Edit_ComfyUI/resolve/main/split_files/diffusion_models/qwen_image_edit_2509_fp8_e4m3fn.safetensors)\n\n**LoRA**\n\n- [Qwen-Image-Lightning-4steps-V1.0.safetensors](https://huggingface.co/lightx2v/Qwen-Image-Lightning/resolve/main/Qwen-Image-Lightning-4steps-V1.0.safetensors)\n\n**Text encoder**\n\n- [qwen_2.5_vl_7b_fp8_scaled.safetensors](https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/text_encoders/qwen_2.5_vl_7b_fp8_scaled.safetensors)\n\n**VAE**\n\n- [qwen_image_vae.safetensors](https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/vae/qwen_image_vae.safetensors)\n\nModel Storage Location\n\n```\n📂 ComfyUI/\n├── 📂 models/\n│ ├── 📂 diffusion_models/\n│ │ └── qwen_image_edit_2509_fp8_e4m3fn.safetensors\n│ ├── 📂 loras/\n│ │ └── Qwen-Image-Lightning-4steps-V1.0.safetensors\n│ ├── 📂 vae/\n│ │ └── qwen_image_vae.safetensors\n│ └── 📂 text_encoders/\n│ └── qwen_2.5_vl_7b_fp8_scaled.safetensors\n```\n"
380
+ ],
381
+ "color": "#432",
382
+ "bgcolor": "#653"
383
+ },
384
+ {
385
+ "id": 96,
386
+ "type": "MarkdownNote",
387
+ "pos": [
388
+ -240,
389
+ 1030
390
+ ],
391
+ "size": [
392
+ 290,
393
+ 140
394
+ ],
395
+ "flags": {},
396
+ "order": 7,
397
+ "mode": 0,
398
+ "inputs": [],
399
+ "outputs": [],
400
+ "properties": {},
401
+ "widgets_values": [
402
+ "This node is to avoid bad output results caused by excessively large input image sizes. Because when we input one image, we use the size of that input image.\n\nThe **TextEncodeQwenImageEditPlus** will scale your input to 1024×104 pixels. We use the size of your first input image. This node is to avoid having an input image size that is too large (such as 3000×3000 pixels), which could bring bad results."
403
+ ],
404
+ "color": "#432",
405
+ "bgcolor": "#653"
406
+ },
407
+ {
408
+ "id": 115,
409
+ "type": "VAEDecode",
410
+ "pos": [
411
+ -259.239990234375,
412
+ 1497.972412109375
413
+ ],
414
+ "size": [
415
+ 210,
416
+ 46
417
+ ],
418
+ "flags": {},
419
+ "order": 18,
420
+ "mode": 0,
421
+ "inputs": [
422
+ {
423
+ "name": "samples",
424
+ "type": "LATENT",
425
+ "link": 226
426
+ },
427
+ {
428
+ "name": "vae",
429
+ "type": "VAE",
430
+ "link": 243
431
+ }
432
+ ],
433
+ "outputs": [
434
+ {
435
+ "name": "IMAGE",
436
+ "type": "IMAGE",
437
+ "slot_index": 0,
438
+ "links": [
439
+ 234
440
+ ]
441
+ }
442
+ ],
443
+ "properties": {
444
+ "cnr_id": "comfy-core",
445
+ "ver": "0.3.23",
446
+ "Node name for S&R": "VAEDecode"
447
+ },
448
+ "widgets_values": []
449
+ },
450
+ {
451
+ "id": 117,
452
+ "type": "MaskToImage",
453
+ "pos": [
454
+ 88.0047607421875,
455
+ 1383.150390625
456
+ ],
457
+ "size": [
458
+ 184.62362670898438,
459
+ 26
460
+ ],
461
+ "flags": {},
462
+ "order": 12,
463
+ "mode": 0,
464
+ "inputs": [
465
+ {
466
+ "name": "mask",
467
+ "type": "MASK",
468
+ "link": 238
469
+ }
470
+ ],
471
+ "outputs": [
472
+ {
473
+ "name": "IMAGE",
474
+ "type": "IMAGE",
475
+ "links": [
476
+ 231
477
+ ]
478
+ }
479
+ ],
480
+ "properties": {
481
+ "cnr_id": "comfy-core",
482
+ "ver": "0.3.51",
483
+ "Node name for S&R": "MaskToImage"
484
+ },
485
+ "widgets_values": []
486
+ },
487
+ {
488
+ "id": 120,
489
+ "type": "VAEEncode",
490
+ "pos": [
491
+ -244.5130157470703,
492
+ 1405.4102783203125
493
+ ],
494
+ "size": [
495
+ 140,
496
+ 46
497
+ ],
498
+ "flags": {},
499
+ "order": 16,
500
+ "mode": 0,
501
+ "inputs": [
502
+ {
503
+ "name": "pixels",
504
+ "type": "IMAGE",
505
+ "link": 235
506
+ },
507
+ {
508
+ "name": "vae",
509
+ "type": "VAE",
510
+ "link": 236
511
+ }
512
+ ],
513
+ "outputs": [
514
+ {
515
+ "name": "LATENT",
516
+ "type": "LATENT",
517
+ "links": [
518
+ 226
519
+ ]
520
+ }
521
+ ],
522
+ "properties": {
523
+ "cnr_id": "comfy-core",
524
+ "ver": "0.3.50",
525
+ "Node name for S&R": "VAEEncode",
526
+ "enableTabs": false,
527
+ "tabWidth": 65,
528
+ "tabXOffset": 10,
529
+ "hasSecondTab": false,
530
+ "secondTabText": "Send Back",
531
+ "secondTabOffset": 80,
532
+ "secondTabWidth": 65,
533
+ "ue_properties": {
534
+ "widget_ue_connectable": {}
535
+ }
536
+ },
537
+ "widgets_values": []
538
+ },
539
+ {
540
+ "id": 121,
541
+ "type": "ImageScale",
542
+ "pos": [
543
+ 43.72477340698242,
544
+ 1461.8167724609375
545
+ ],
546
+ "size": [
547
+ 270,
548
+ 130
549
+ ],
550
+ "flags": {},
551
+ "order": 22,
552
+ "mode": 0,
553
+ "inputs": [
554
+ {
555
+ "name": "image",
556
+ "type": "IMAGE",
557
+ "link": 231
558
+ },
559
+ {
560
+ "name": "width",
561
+ "type": "INT",
562
+ "widget": {
563
+ "name": "width"
564
+ },
565
+ "link": 232
566
+ },
567
+ {
568
+ "name": "height",
569
+ "type": "INT",
570
+ "widget": {
571
+ "name": "height"
572
+ },
573
+ "link": 233
574
+ }
575
+ ],
576
+ "outputs": [
577
+ {
578
+ "name": "IMAGE",
579
+ "type": "IMAGE",
580
+ "links": [
581
+ 229
582
+ ]
583
+ }
584
+ ],
585
+ "properties": {
586
+ "cnr_id": "comfy-core",
587
+ "ver": "0.3.52",
588
+ "Node name for S&R": "ImageScale"
589
+ },
590
+ "widgets_values": [
591
+ "nearest-exact",
592
+ 512,
593
+ 512,
594
+ "center"
595
+ ]
596
+ },
597
+ {
598
+ "id": 122,
599
+ "type": "GetImageSize",
600
+ "pos": [
601
+ -247.08106994628906,
602
+ 1597.323486328125
603
+ ],
604
+ "size": [
605
+ 140,
606
+ 124
607
+ ],
608
+ "flags": {},
609
+ "order": 20,
610
+ "mode": 0,
611
+ "inputs": [
612
+ {
613
+ "name": "image",
614
+ "type": "IMAGE",
615
+ "link": 234
616
+ }
617
+ ],
618
+ "outputs": [
619
+ {
620
+ "name": "width",
621
+ "type": "INT",
622
+ "links": [
623
+ 227,
624
+ 232
625
+ ]
626
+ },
627
+ {
628
+ "name": "height",
629
+ "type": "INT",
630
+ "links": [
631
+ 228,
632
+ 233
633
+ ]
634
+ },
635
+ {
636
+ "name": "batch_size",
637
+ "type": "INT",
638
+ "links": null
639
+ }
640
+ ],
641
+ "properties": {
642
+ "cnr_id": "comfy-core",
643
+ "ver": "0.3.52",
644
+ "Node name for S&R": "GetImageSize"
645
+ },
646
+ "widgets_values": []
647
+ },
648
+ {
649
+ "id": 93,
650
+ "type": "ImageScaleToTotalPixels",
651
+ "pos": [
652
+ -230,
653
+ 890
654
+ ],
655
+ "size": [
656
+ 270,
657
+ 82
658
+ ],
659
+ "flags": {},
660
+ "order": 11,
661
+ "mode": 0,
662
+ "inputs": [
663
+ {
664
+ "name": "image",
665
+ "type": "IMAGE",
666
+ "link": 177
667
+ }
668
+ ],
669
+ "outputs": [
670
+ {
671
+ "name": "IMAGE",
672
+ "type": "IMAGE",
673
+ "links": [
674
+ 224,
675
+ 225,
676
+ 235
677
+ ]
678
+ }
679
+ ],
680
+ "properties": {
681
+ "cnr_id": "comfy-core",
682
+ "ver": "0.3.50",
683
+ "Node name for S&R": "ImageScaleToTotalPixels",
684
+ "enableTabs": false,
685
+ "tabWidth": 65,
686
+ "tabXOffset": 10,
687
+ "hasSecondTab": false,
688
+ "secondTabText": "Send Back",
689
+ "secondTabOffset": 80,
690
+ "secondTabWidth": 65,
691
+ "ue_properties": {
692
+ "widget_ue_connectable": {
693
+ "upscale_method": true,
694
+ "megapixels": true
695
+ }
696
+ }
697
+ },
698
+ "widgets_values": [
699
+ "lanczos",
700
+ 1
701
+ ]
702
+ },
703
+ {
704
+ "id": 88,
705
+ "type": "VAEEncode",
706
+ "pos": [
707
+ 264.1481018066406,
708
+ 899.3114624023438
709
+ ],
710
+ "size": [
711
+ 140,
712
+ 46
713
+ ],
714
+ "flags": {},
715
+ "order": 23,
716
+ "mode": 0,
717
+ "inputs": [
718
+ {
719
+ "name": "pixels",
720
+ "type": "IMAGE",
721
+ "link": 239
722
+ },
723
+ {
724
+ "name": "vae",
725
+ "type": "VAE",
726
+ "link": 168
727
+ }
728
+ ],
729
+ "outputs": [
730
+ {
731
+ "name": "LATENT",
732
+ "type": "LATENT",
733
+ "links": [
734
+ 240
735
+ ]
736
+ }
737
+ ],
738
+ "properties": {
739
+ "cnr_id": "comfy-core",
740
+ "ver": "0.3.50",
741
+ "Node name for S&R": "VAEEncode",
742
+ "enableTabs": false,
743
+ "tabWidth": 65,
744
+ "tabXOffset": 10,
745
+ "hasSecondTab": false,
746
+ "secondTabText": "Send Back",
747
+ "secondTabOffset": 80,
748
+ "secondTabWidth": 65,
749
+ "ue_properties": {
750
+ "widget_ue_connectable": {}
751
+ }
752
+ },
753
+ "widgets_values": []
754
+ },
755
+ {
756
+ "id": 124,
757
+ "type": "SetLatentNoiseMask",
758
+ "pos": [
759
+ 476.48956298828125,
760
+ 897.2662963867188
761
+ ],
762
+ "size": [
763
+ 180.74765014648438,
764
+ 46
765
+ ],
766
+ "flags": {},
767
+ "order": 25,
768
+ "mode": 0,
769
+ "inputs": [
770
+ {
771
+ "name": "samples",
772
+ "type": "LATENT",
773
+ "link": 240
774
+ },
775
+ {
776
+ "name": "mask",
777
+ "type": "MASK",
778
+ "link": 242
779
+ }
780
+ ],
781
+ "outputs": [
782
+ {
783
+ "name": "LATENT",
784
+ "type": "LATENT",
785
+ "links": [
786
+ 246
787
+ ]
788
+ }
789
+ ],
790
+ "properties": {
791
+ "cnr_id": "comfy-core",
792
+ "ver": "0.3.51",
793
+ "Node name for S&R": "SetLatentNoiseMask"
794
+ },
795
+ "widgets_values": []
796
+ },
797
+ {
798
+ "id": 111,
799
+ "type": "TextEncodeQwenImageEditPlus",
800
+ "pos": [
801
+ 220,
802
+ -90
803
+ ],
804
+ "size": [
805
+ 400,
806
+ 200
807
+ ],
808
+ "flags": {},
809
+ "order": 14,
810
+ "mode": 0,
811
+ "inputs": [
812
+ {
813
+ "name": "clip",
814
+ "type": "CLIP",
815
+ "link": 205
816
+ },
817
+ {
818
+ "name": "vae",
819
+ "shape": 7,
820
+ "type": "VAE",
821
+ "link": 207
822
+ },
823
+ {
824
+ "name": "image1",
825
+ "shape": 7,
826
+ "type": "IMAGE",
827
+ "link": 224
828
+ },
829
+ {
830
+ "name": "image2",
831
+ "shape": 7,
832
+ "type": "IMAGE",
833
+ "link": 219
834
+ },
835
+ {
836
+ "name": "image3",
837
+ "shape": 7,
838
+ "type": "IMAGE",
839
+ "link": 217
840
+ }
841
+ ],
842
+ "outputs": [
843
+ {
844
+ "name": "CONDITIONING",
845
+ "type": "CONDITIONING",
846
+ "links": [
847
+ 244
848
+ ]
849
+ }
850
+ ],
851
+ "properties": {
852
+ "cnr_id": "comfy-core",
853
+ "ver": "0.3.59",
854
+ "Node name for S&R": "TextEncodeQwenImageEditPlus"
855
+ },
856
+ "widgets_values": [
857
+ "change the girl's cloth to red evening gown "
858
+ ],
859
+ "color": "#232",
860
+ "bgcolor": "#353"
861
+ },
862
+ {
863
+ "id": 78,
864
+ "type": "LoadImage",
865
+ "pos": [
866
+ -238.3336944580078,
867
+ 517.50244140625
868
+ ],
869
+ "size": [
870
+ 274.080078125,
871
+ 314.0000305175781
872
+ ],
873
+ "flags": {},
874
+ "order": 8,
875
+ "mode": 0,
876
+ "inputs": [],
877
+ "outputs": [
878
+ {
879
+ "name": "IMAGE",
880
+ "type": "IMAGE",
881
+ "links": [
882
+ 177,
883
+ 237
884
+ ]
885
+ },
886
+ {
887
+ "name": "MASK",
888
+ "type": "MASK",
889
+ "links": [
890
+ 238
891
+ ]
892
+ }
893
+ ],
894
+ "properties": {
895
+ "cnr_id": "comfy-core",
896
+ "ver": "0.3.50",
897
+ "Node name for S&R": "LoadImage",
898
+ "enableTabs": false,
899
+ "tabWidth": 65,
900
+ "tabXOffset": 10,
901
+ "hasSecondTab": false,
902
+ "secondTabText": "Send Back",
903
+ "secondTabOffset": 80,
904
+ "secondTabWidth": 65,
905
+ "ue_properties": {
906
+ "widget_ue_connectable": {
907
+ "image": true,
908
+ "upload": true
909
+ }
910
+ }
911
+ },
912
+ "widgets_values": [
913
+ "Masked_Load_Me_in_Loader (9).png",
914
+ "image"
915
+ ]
916
+ },
917
+ {
918
+ "id": 39,
919
+ "type": "VAELoader",
920
+ "pos": [
921
+ -250,
922
+ 320
923
+ ],
924
+ "size": [
925
+ 330,
926
+ 60
927
+ ],
928
+ "flags": {},
929
+ "order": 9,
930
+ "mode": 0,
931
+ "inputs": [],
932
+ "outputs": [
933
+ {
934
+ "name": "VAE",
935
+ "type": "VAE",
936
+ "slot_index": 0,
937
+ "links": [
938
+ 76,
939
+ 168,
940
+ 206,
941
+ 207,
942
+ 236,
943
+ 243
944
+ ]
945
+ }
946
+ ],
947
+ "properties": {
948
+ "cnr_id": "comfy-core",
949
+ "ver": "0.3.48",
950
+ "Node name for S&R": "VAELoader",
951
+ "models": [
952
+ {
953
+ "name": "qwen_image_vae.safetensors",
954
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/vae/qwen_image_vae.safetensors",
955
+ "directory": "vae"
956
+ }
957
+ ],
958
+ "enableTabs": false,
959
+ "tabWidth": 65,
960
+ "tabXOffset": 10,
961
+ "hasSecondTab": false,
962
+ "secondTabText": "Send Back",
963
+ "secondTabOffset": 80,
964
+ "secondTabWidth": 65,
965
+ "widget_ue_connectable": {}
966
+ },
967
+ "widgets_values": [
968
+ "qwen_image_vae.safetensors"
969
+ ]
970
+ },
971
+ {
972
+ "id": 89,
973
+ "type": "LoraLoaderModelOnly",
974
+ "pos": [
975
+ -240,
976
+ 40
977
+ ],
978
+ "size": [
979
+ 310,
980
+ 82
981
+ ],
982
+ "flags": {},
983
+ "order": 13,
984
+ "mode": 4,
985
+ "inputs": [
986
+ {
987
+ "name": "model",
988
+ "type": "MODEL",
989
+ "link": 184
990
+ }
991
+ ],
992
+ "outputs": [
993
+ {
994
+ "name": "MODEL",
995
+ "type": "MODEL",
996
+ "links": [
997
+ 185
998
+ ]
999
+ }
1000
+ ],
1001
+ "properties": {
1002
+ "cnr_id": "comfy-core",
1003
+ "ver": "0.3.50",
1004
+ "Node name for S&R": "LoraLoaderModelOnly",
1005
+ "models": [
1006
+ {
1007
+ "name": "Qwen-Image-Lightning-4steps-V1.0.safetensors",
1008
+ "url": "https://huggingface.co/lightx2v/Qwen-Image-Lightning/resolve/main/Qwen-Image-Lightning-4steps-V1.0.safetensors",
1009
+ "directory": "loras"
1010
+ }
1011
+ ],
1012
+ "enableTabs": false,
1013
+ "tabWidth": 65,
1014
+ "tabXOffset": 10,
1015
+ "hasSecondTab": false,
1016
+ "secondTabText": "Send Back",
1017
+ "secondTabOffset": 80,
1018
+ "secondTabWidth": 65,
1019
+ "ue_properties": {
1020
+ "widget_ue_connectable": {
1021
+ "lora_name": true,
1022
+ "strength_model": true
1023
+ }
1024
+ }
1025
+ },
1026
+ "widgets_values": [
1027
+ "Qwen-Image-Lightning-4steps-V1.0.safetensors",
1028
+ 1
1029
+ ]
1030
+ },
1031
+ {
1032
+ "id": 75,
1033
+ "type": "CFGNorm",
1034
+ "pos": [
1035
+ 740,
1036
+ -20
1037
+ ],
1038
+ "size": [
1039
+ 290,
1040
+ 60
1041
+ ],
1042
+ "flags": {},
1043
+ "order": 19,
1044
+ "mode": 0,
1045
+ "inputs": [
1046
+ {
1047
+ "name": "model",
1048
+ "type": "MODEL",
1049
+ "link": 141
1050
+ }
1051
+ ],
1052
+ "outputs": [
1053
+ {
1054
+ "name": "patched_model",
1055
+ "type": "MODEL",
1056
+ "links": [
1057
+ 247
1058
+ ]
1059
+ }
1060
+ ],
1061
+ "properties": {
1062
+ "cnr_id": "comfy-core",
1063
+ "ver": "0.3.50",
1064
+ "Node name for S&R": "CFGNorm",
1065
+ "enableTabs": false,
1066
+ "tabWidth": 65,
1067
+ "tabXOffset": 10,
1068
+ "hasSecondTab": false,
1069
+ "secondTabText": "Send Back",
1070
+ "secondTabOffset": 80,
1071
+ "secondTabWidth": 65,
1072
+ "ue_properties": {
1073
+ "widget_ue_connectable": {
1074
+ "strength": true
1075
+ }
1076
+ }
1077
+ },
1078
+ "widgets_values": [
1079
+ 1
1080
+ ]
1081
+ },
1082
+ {
1083
+ "id": 37,
1084
+ "type": "UNETLoader",
1085
+ "pos": [
1086
+ -250,
1087
+ -100
1088
+ ],
1089
+ "size": [
1090
+ 330,
1091
+ 90
1092
+ ],
1093
+ "flags": {},
1094
+ "order": 10,
1095
+ "mode": 0,
1096
+ "inputs": [],
1097
+ "outputs": [
1098
+ {
1099
+ "name": "MODEL",
1100
+ "type": "MODEL",
1101
+ "slot_index": 0,
1102
+ "links": [
1103
+ 184
1104
+ ]
1105
+ }
1106
+ ],
1107
+ "properties": {
1108
+ "cnr_id": "comfy-core",
1109
+ "ver": "0.3.48",
1110
+ "Node name for S&R": "UNETLoader",
1111
+ "models": [
1112
+ {
1113
+ "name": "qwen_image_edit_2509_fp8_e4m3fn.safetensors",
1114
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image-Edit_ComfyUI/resolve/main/split_files/diffusion_models/qwen_image_edit_2509_fp8_e4m3fn.safetensors",
1115
+ "directory": "diffusion_models"
1116
+ }
1117
+ ],
1118
+ "enableTabs": false,
1119
+ "tabWidth": 65,
1120
+ "tabXOffset": 10,
1121
+ "hasSecondTab": false,
1122
+ "secondTabText": "Send Back",
1123
+ "secondTabOffset": 80,
1124
+ "secondTabWidth": 65,
1125
+ "widget_ue_connectable": {}
1126
+ },
1127
+ "widgets_values": [
1128
+ "qwen_image_edit_2509_fp8_e4m3fn.safetensors",
1129
+ "default"
1130
+ ]
1131
+ },
1132
+ {
1133
+ "id": 8,
1134
+ "type": "VAEDecode",
1135
+ "pos": [
1136
+ 1080,
1137
+ -130
1138
+ ],
1139
+ "size": [
1140
+ 210,
1141
+ 46
1142
+ ],
1143
+ "flags": {
1144
+ "collapsed": false
1145
+ },
1146
+ "order": 27,
1147
+ "mode": 0,
1148
+ "inputs": [
1149
+ {
1150
+ "name": "samples",
1151
+ "type": "LATENT",
1152
+ "link": 248
1153
+ },
1154
+ {
1155
+ "name": "vae",
1156
+ "type": "VAE",
1157
+ "link": 76
1158
+ }
1159
+ ],
1160
+ "outputs": [
1161
+ {
1162
+ "name": "IMAGE",
1163
+ "type": "IMAGE",
1164
+ "slot_index": 0,
1165
+ "links": [
1166
+ 250
1167
+ ]
1168
+ }
1169
+ ],
1170
+ "properties": {
1171
+ "cnr_id": "comfy-core",
1172
+ "ver": "0.3.48",
1173
+ "Node name for S&R": "VAEDecode",
1174
+ "enableTabs": false,
1175
+ "tabWidth": 65,
1176
+ "tabXOffset": 10,
1177
+ "hasSecondTab": false,
1178
+ "secondTabText": "Send Back",
1179
+ "secondTabOffset": 80,
1180
+ "secondTabWidth": 65,
1181
+ "widget_ue_connectable": {}
1182
+ },
1183
+ "widgets_values": []
1184
+ },
1185
+ {
1186
+ "id": 116,
1187
+ "type": "ImageScale",
1188
+ "pos": [
1189
+ 45.519248962402344,
1190
+ 1207.10595703125
1191
+ ],
1192
+ "size": [
1193
+ 270,
1194
+ 130
1195
+ ],
1196
+ "flags": {},
1197
+ "order": 21,
1198
+ "mode": 0,
1199
+ "inputs": [
1200
+ {
1201
+ "name": "image",
1202
+ "type": "IMAGE",
1203
+ "link": 237
1204
+ },
1205
+ {
1206
+ "name": "width",
1207
+ "type": "INT",
1208
+ "widget": {
1209
+ "name": "width"
1210
+ },
1211
+ "link": 227
1212
+ },
1213
+ {
1214
+ "name": "height",
1215
+ "type": "INT",
1216
+ "widget": {
1217
+ "name": "height"
1218
+ },
1219
+ "link": 228
1220
+ }
1221
+ ],
1222
+ "outputs": [
1223
+ {
1224
+ "name": "IMAGE",
1225
+ "type": "IMAGE",
1226
+ "links": [
1227
+ 239,
1228
+ 251
1229
+ ]
1230
+ }
1231
+ ],
1232
+ "properties": {
1233
+ "cnr_id": "comfy-core",
1234
+ "ver": "0.3.52",
1235
+ "Node name for S&R": "ImageScale"
1236
+ },
1237
+ "widgets_values": [
1238
+ "lanczos",
1239
+ 512,
1240
+ 512,
1241
+ "center"
1242
+ ]
1243
+ },
1244
+ {
1245
+ "id": 118,
1246
+ "type": "ImageToMask",
1247
+ "pos": [
1248
+ 45.0244255065918,
1249
+ 1635.2989501953125
1250
+ ],
1251
+ "size": [
1252
+ 270,
1253
+ 58
1254
+ ],
1255
+ "flags": {},
1256
+ "order": 24,
1257
+ "mode": 0,
1258
+ "inputs": [
1259
+ {
1260
+ "name": "image",
1261
+ "type": "IMAGE",
1262
+ "link": 229
1263
+ }
1264
+ ],
1265
+ "outputs": [
1266
+ {
1267
+ "name": "MASK",
1268
+ "type": "MASK",
1269
+ "links": [
1270
+ 242,
1271
+ 252
1272
+ ]
1273
+ }
1274
+ ],
1275
+ "properties": {
1276
+ "cnr_id": "comfy-core",
1277
+ "ver": "0.3.51",
1278
+ "Node name for S&R": "ImageToMask"
1279
+ },
1280
+ "widgets_values": [
1281
+ "red"
1282
+ ]
1283
+ },
1284
+ {
1285
+ "id": 126,
1286
+ "type": "LanPaint_MaskBlend",
1287
+ "pos": [
1288
+ 1087.578857421875,
1289
+ -12.272896766662598
1290
+ ],
1291
+ "size": [
1292
+ 210,
1293
+ 98
1294
+ ],
1295
+ "flags": {},
1296
+ "order": 28,
1297
+ "mode": 0,
1298
+ "inputs": [
1299
+ {
1300
+ "name": "image1",
1301
+ "type": "IMAGE",
1302
+ "link": 251
1303
+ },
1304
+ {
1305
+ "name": "image2",
1306
+ "type": "IMAGE",
1307
+ "link": 250
1308
+ },
1309
+ {
1310
+ "name": "mask",
1311
+ "type": "MASK",
1312
+ "link": 252
1313
+ }
1314
+ ],
1315
+ "outputs": [
1316
+ {
1317
+ "name": "IMAGE",
1318
+ "type": "IMAGE",
1319
+ "links": [
1320
+ 249
1321
+ ]
1322
+ }
1323
+ ],
1324
+ "properties": {
1325
+ "cnr_id": "LanPaint",
1326
+ "ver": "4d3d5d17f0105b673df92da5b084cce567c9c712",
1327
+ "Node name for S&R": "LanPaint_MaskBlend"
1328
+ },
1329
+ "widgets_values": [
1330
+ 9
1331
+ ]
1332
+ },
1333
+ {
1334
+ "id": 125,
1335
+ "type": "LanPaint_KSampler",
1336
+ "pos": [
1337
+ 739.589599609375,
1338
+ 84.47759246826172
1339
+ ],
1340
+ "size": [
1341
+ 292.9582214355469,
1342
+ 572
1343
+ ],
1344
+ "flags": {},
1345
+ "order": 26,
1346
+ "mode": 0,
1347
+ "inputs": [
1348
+ {
1349
+ "name": "model",
1350
+ "type": "MODEL",
1351
+ "link": 247
1352
+ },
1353
+ {
1354
+ "name": "positive",
1355
+ "type": "CONDITIONING",
1356
+ "link": 244
1357
+ },
1358
+ {
1359
+ "name": "negative",
1360
+ "type": "CONDITIONING",
1361
+ "link": 245
1362
+ },
1363
+ {
1364
+ "name": "latent_image",
1365
+ "type": "LATENT",
1366
+ "link": 246
1367
+ }
1368
+ ],
1369
+ "outputs": [
1370
+ {
1371
+ "name": "LATENT",
1372
+ "type": "LATENT",
1373
+ "links": [
1374
+ 248
1375
+ ]
1376
+ }
1377
+ ],
1378
+ "properties": {
1379
+ "cnr_id": "LanPaint",
1380
+ "ver": "453b6c090e400123bb82f5bc0c97854031b09274",
1381
+ "Node name for S&R": "LanPaint_KSampler"
1382
+ },
1383
+ "widgets_values": [
1384
+ 0,
1385
+ "fixed",
1386
+ 20,
1387
+ 2.5,
1388
+ "euler",
1389
+ "simple",
1390
+ 1,
1391
+ 1,
1392
+ "Image First",
1393
+ "LanPaint KSampler. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!"
1394
+ ]
1395
+ },
1396
+ {
1397
+ "id": 127,
1398
+ "type": "SaveImage",
1399
+ "pos": [
1400
+ 1090.8616943359375,
1401
+ 133.32968139648438
1402
+ ],
1403
+ "size": [
1404
+ 711.9912109375,
1405
+ 634.4884643554688
1406
+ ],
1407
+ "flags": {},
1408
+ "order": 29,
1409
+ "mode": 0,
1410
+ "inputs": [
1411
+ {
1412
+ "name": "images",
1413
+ "type": "IMAGE",
1414
+ "link": 249
1415
+ }
1416
+ ],
1417
+ "outputs": [],
1418
+ "properties": {
1419
+ "cnr_id": "comfy-core",
1420
+ "ver": "0.3.23"
1421
+ },
1422
+ "widgets_values": [
1423
+ "ComfyUI"
1424
+ ]
1425
+ }
1426
+ ],
1427
+ "links": [
1428
+ [
1429
+ 76,
1430
+ 39,
1431
+ 0,
1432
+ 8,
1433
+ 1,
1434
+ "VAE"
1435
+ ],
1436
+ [
1437
+ 141,
1438
+ 66,
1439
+ 0,
1440
+ 75,
1441
+ 0,
1442
+ "MODEL"
1443
+ ],
1444
+ [
1445
+ 168,
1446
+ 39,
1447
+ 0,
1448
+ 88,
1449
+ 1,
1450
+ "VAE"
1451
+ ],
1452
+ [
1453
+ 177,
1454
+ 78,
1455
+ 0,
1456
+ 93,
1457
+ 0,
1458
+ "IMAGE"
1459
+ ],
1460
+ [
1461
+ 184,
1462
+ 37,
1463
+ 0,
1464
+ 89,
1465
+ 0,
1466
+ "MODEL"
1467
+ ],
1468
+ [
1469
+ 185,
1470
+ 89,
1471
+ 0,
1472
+ 66,
1473
+ 0,
1474
+ "MODEL"
1475
+ ],
1476
+ [
1477
+ 204,
1478
+ 38,
1479
+ 0,
1480
+ 110,
1481
+ 0,
1482
+ "CLIP"
1483
+ ],
1484
+ [
1485
+ 205,
1486
+ 38,
1487
+ 0,
1488
+ 111,
1489
+ 0,
1490
+ "CLIP"
1491
+ ],
1492
+ [
1493
+ 206,
1494
+ 39,
1495
+ 0,
1496
+ 110,
1497
+ 1,
1498
+ "VAE"
1499
+ ],
1500
+ [
1501
+ 207,
1502
+ 39,
1503
+ 0,
1504
+ 111,
1505
+ 1,
1506
+ "VAE"
1507
+ ],
1508
+ [
1509
+ 217,
1510
+ 108,
1511
+ 0,
1512
+ 111,
1513
+ 4,
1514
+ "IMAGE"
1515
+ ],
1516
+ [
1517
+ 218,
1518
+ 108,
1519
+ 0,
1520
+ 110,
1521
+ 4,
1522
+ "IMAGE"
1523
+ ],
1524
+ [
1525
+ 219,
1526
+ 106,
1527
+ 0,
1528
+ 111,
1529
+ 3,
1530
+ "IMAGE"
1531
+ ],
1532
+ [
1533
+ 220,
1534
+ 106,
1535
+ 0,
1536
+ 110,
1537
+ 3,
1538
+ "IMAGE"
1539
+ ],
1540
+ [
1541
+ 224,
1542
+ 93,
1543
+ 0,
1544
+ 111,
1545
+ 2,
1546
+ "IMAGE"
1547
+ ],
1548
+ [
1549
+ 225,
1550
+ 93,
1551
+ 0,
1552
+ 110,
1553
+ 2,
1554
+ "IMAGE"
1555
+ ],
1556
+ [
1557
+ 226,
1558
+ 120,
1559
+ 0,
1560
+ 115,
1561
+ 0,
1562
+ "LATENT"
1563
+ ],
1564
+ [
1565
+ 227,
1566
+ 122,
1567
+ 0,
1568
+ 116,
1569
+ 1,
1570
+ "INT"
1571
+ ],
1572
+ [
1573
+ 228,
1574
+ 122,
1575
+ 1,
1576
+ 116,
1577
+ 2,
1578
+ "INT"
1579
+ ],
1580
+ [
1581
+ 229,
1582
+ 121,
1583
+ 0,
1584
+ 118,
1585
+ 0,
1586
+ "IMAGE"
1587
+ ],
1588
+ [
1589
+ 231,
1590
+ 117,
1591
+ 0,
1592
+ 121,
1593
+ 0,
1594
+ "IMAGE"
1595
+ ],
1596
+ [
1597
+ 232,
1598
+ 122,
1599
+ 0,
1600
+ 121,
1601
+ 1,
1602
+ "INT"
1603
+ ],
1604
+ [
1605
+ 233,
1606
+ 122,
1607
+ 1,
1608
+ 121,
1609
+ 2,
1610
+ "INT"
1611
+ ],
1612
+ [
1613
+ 234,
1614
+ 115,
1615
+ 0,
1616
+ 122,
1617
+ 0,
1618
+ "IMAGE"
1619
+ ],
1620
+ [
1621
+ 235,
1622
+ 93,
1623
+ 0,
1624
+ 120,
1625
+ 0,
1626
+ "IMAGE"
1627
+ ],
1628
+ [
1629
+ 236,
1630
+ 39,
1631
+ 0,
1632
+ 120,
1633
+ 1,
1634
+ "VAE"
1635
+ ],
1636
+ [
1637
+ 237,
1638
+ 78,
1639
+ 0,
1640
+ 116,
1641
+ 0,
1642
+ "IMAGE"
1643
+ ],
1644
+ [
1645
+ 238,
1646
+ 78,
1647
+ 1,
1648
+ 117,
1649
+ 0,
1650
+ "MASK"
1651
+ ],
1652
+ [
1653
+ 239,
1654
+ 116,
1655
+ 0,
1656
+ 88,
1657
+ 0,
1658
+ "IMAGE"
1659
+ ],
1660
+ [
1661
+ 240,
1662
+ 88,
1663
+ 0,
1664
+ 124,
1665
+ 0,
1666
+ "LATENT"
1667
+ ],
1668
+ [
1669
+ 242,
1670
+ 118,
1671
+ 0,
1672
+ 124,
1673
+ 1,
1674
+ "MASK"
1675
+ ],
1676
+ [
1677
+ 243,
1678
+ 39,
1679
+ 0,
1680
+ 115,
1681
+ 1,
1682
+ "VAE"
1683
+ ],
1684
+ [
1685
+ 244,
1686
+ 111,
1687
+ 0,
1688
+ 125,
1689
+ 1,
1690
+ "CONDITIONING"
1691
+ ],
1692
+ [
1693
+ 245,
1694
+ 110,
1695
+ 0,
1696
+ 125,
1697
+ 2,
1698
+ "CONDITIONING"
1699
+ ],
1700
+ [
1701
+ 246,
1702
+ 124,
1703
+ 0,
1704
+ 125,
1705
+ 3,
1706
+ "LATENT"
1707
+ ],
1708
+ [
1709
+ 247,
1710
+ 75,
1711
+ 0,
1712
+ 125,
1713
+ 0,
1714
+ "MODEL"
1715
+ ],
1716
+ [
1717
+ 248,
1718
+ 125,
1719
+ 0,
1720
+ 8,
1721
+ 0,
1722
+ "LATENT"
1723
+ ],
1724
+ [
1725
+ 249,
1726
+ 126,
1727
+ 0,
1728
+ 127,
1729
+ 0,
1730
+ "IMAGE"
1731
+ ],
1732
+ [
1733
+ 250,
1734
+ 8,
1735
+ 0,
1736
+ 126,
1737
+ 1,
1738
+ "IMAGE"
1739
+ ],
1740
+ [
1741
+ 251,
1742
+ 116,
1743
+ 0,
1744
+ 126,
1745
+ 0,
1746
+ "IMAGE"
1747
+ ],
1748
+ [
1749
+ 252,
1750
+ 118,
1751
+ 0,
1752
+ 126,
1753
+ 2,
1754
+ "MASK"
1755
+ ]
1756
+ ],
1757
+ "groups": [
1758
+ {
1759
+ "id": 1,
1760
+ "title": "Step1 - Load models",
1761
+ "bounding": [
1762
+ -270,
1763
+ -170,
1764
+ 370,
1765
+ 570
1766
+ ],
1767
+ "color": "#3f789e",
1768
+ "font_size": 24,
1769
+ "flags": {}
1770
+ },
1771
+ {
1772
+ "id": 2,
1773
+ "title": "Step 2 - Upload image for editing",
1774
+ "bounding": [
1775
+ -270,
1776
+ 430,
1777
+ 970,
1778
+ 550
1779
+ ],
1780
+ "color": "#3f789e",
1781
+ "font_size": 24,
1782
+ "flags": {}
1783
+ },
1784
+ {
1785
+ "id": 3,
1786
+ "title": "Step 4 - Prompt",
1787
+ "bounding": [
1788
+ 130,
1789
+ -170,
1790
+ 570,
1791
+ 570
1792
+ ],
1793
+ "color": "#3f789e",
1794
+ "font_size": 24,
1795
+ "flags": {}
1796
+ },
1797
+ {
1798
+ "id": 4,
1799
+ "title": "Step3 - Image Size",
1800
+ "bounding": [
1801
+ 730,
1802
+ 780,
1803
+ 310,
1804
+ 200
1805
+ ],
1806
+ "color": "#3f789e",
1807
+ "font_size": 24,
1808
+ "flags": {}
1809
+ }
1810
+ ],
1811
+ "config": {},
1812
+ "extra": {
1813
+ "ds": {
1814
+ "scale": 0.6413348663336585,
1815
+ "offset": [
1816
+ -528.1379465475136,
1817
+ 63.45086652498852
1818
+ ]
1819
+ },
1820
+ "frontendVersion": "1.26.15",
1821
+ "ue_links": [],
1822
+ "links_added_by_ue": [],
1823
+ "VHS_latentpreview": false,
1824
+ "VHS_latentpreviewrate": 0,
1825
+ "VHS_MetadataImage": true,
1826
+ "VHS_KeepIntermediate": true
1827
+ },
1828
+ "version": 0.4
1829
+ }
LanPaint/example_workflows/Qwen_Image_Inpaint.jpg ADDED

Git LFS Details

  • SHA256: b0ad37bbc61db9627a5e1c8a98a35675cca813ebf699f2ebe051414fe70ea2c7
  • Pointer size: 131 Bytes
  • Size of remote file: 943 kB
LanPaint/example_workflows/Qwen_Image_Inpaint.json ADDED
@@ -0,0 +1,806 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "11cce4ab-536b-4f42-a95c-0be437d04ace",
3
+ "revision": 0,
4
+ "last_node_id": 128,
5
+ "last_link_id": 338,
6
+ "nodes": [
7
+ {
8
+ "id": 74,
9
+ "type": "LanPaint_KSampler",
10
+ "pos": [
11
+ 276.219970703125,
12
+ 179.55892944335938
13
+ ],
14
+ "size": [
15
+ 388.97625732421875,
16
+ 572
17
+ ],
18
+ "flags": {},
19
+ "order": 10,
20
+ "mode": 0,
21
+ "inputs": [
22
+ {
23
+ "name": "model",
24
+ "type": "MODEL",
25
+ "link": 325
26
+ },
27
+ {
28
+ "name": "positive",
29
+ "type": "CONDITIONING",
30
+ "link": 323
31
+ },
32
+ {
33
+ "name": "negative",
34
+ "type": "CONDITIONING",
35
+ "link": 324
36
+ },
37
+ {
38
+ "name": "latent_image",
39
+ "type": "LATENT",
40
+ "link": 332
41
+ }
42
+ ],
43
+ "outputs": [
44
+ {
45
+ "name": "LATENT",
46
+ "type": "LATENT",
47
+ "slot_index": 0,
48
+ "links": [
49
+ 334
50
+ ]
51
+ }
52
+ ],
53
+ "properties": {
54
+ "cnr_id": "LanPaint",
55
+ "ver": "56bd6c04e89124cd06682b304245d6ddf8b20522",
56
+ "Node name for S&R": "LanPaint_KSampler"
57
+ },
58
+ "widgets_values": [
59
+ 0,
60
+ "fixed",
61
+ 20,
62
+ 4,
63
+ "euler",
64
+ "simple",
65
+ 1,
66
+ 5,
67
+ "Image First",
68
+ "LanPaint KSampler. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!"
69
+ ]
70
+ },
71
+ {
72
+ "id": 113,
73
+ "type": "SaveImage",
74
+ "pos": [
75
+ 807.1268310546875,
76
+ 868.395263671875
77
+ ],
78
+ "size": [
79
+ 311.2532653808594,
80
+ 484.7096252441406
81
+ ],
82
+ "flags": {},
83
+ "order": 13,
84
+ "mode": 0,
85
+ "inputs": [
86
+ {
87
+ "name": "images",
88
+ "type": "IMAGE",
89
+ "link": 338
90
+ }
91
+ ],
92
+ "outputs": [],
93
+ "properties": {
94
+ "cnr_id": "comfy-core",
95
+ "ver": "0.3.23"
96
+ },
97
+ "widgets_values": [
98
+ "ComfyUI"
99
+ ]
100
+ },
101
+ {
102
+ "id": 117,
103
+ "type": "CLIPLoader",
104
+ "pos": [
105
+ -824.4296875,
106
+ 177.9814910888672
107
+ ],
108
+ "size": [
109
+ 330,
110
+ 110
111
+ ],
112
+ "flags": {},
113
+ "order": 0,
114
+ "mode": 0,
115
+ "inputs": [],
116
+ "outputs": [
117
+ {
118
+ "name": "CLIP",
119
+ "type": "CLIP",
120
+ "slot_index": 0,
121
+ "links": [
122
+ 318,
123
+ 319
124
+ ]
125
+ }
126
+ ],
127
+ "properties": {
128
+ "cnr_id": "comfy-core",
129
+ "ver": "0.3.48",
130
+ "Node name for S&R": "CLIPLoader",
131
+ "models": [
132
+ {
133
+ "name": "qwen_2.5_vl_7b_fp8_scaled.safetensors",
134
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/text_encoders/qwen_2.5_vl_7b_fp8_scaled.safetensors",
135
+ "directory": "text_encoders"
136
+ }
137
+ ],
138
+ "enableTabs": false,
139
+ "tabWidth": 65,
140
+ "tabXOffset": 10,
141
+ "hasSecondTab": false,
142
+ "secondTabText": "Send Back",
143
+ "secondTabOffset": 80,
144
+ "secondTabWidth": 65,
145
+ "widget_ue_connectable": {}
146
+ },
147
+ "widgets_values": [
148
+ "qwen_2.5_vl_7b_fp8_scaled.safetensors",
149
+ "qwen_image",
150
+ "default"
151
+ ]
152
+ },
153
+ {
154
+ "id": 118,
155
+ "type": "VAELoader",
156
+ "pos": [
157
+ -824.4296875,
158
+ 327.9817199707031
159
+ ],
160
+ "size": [
161
+ 330,
162
+ 60
163
+ ],
164
+ "flags": {},
165
+ "order": 1,
166
+ "mode": 0,
167
+ "inputs": [],
168
+ "outputs": [
169
+ {
170
+ "name": "VAE",
171
+ "type": "VAE",
172
+ "slot_index": 0,
173
+ "links": [
174
+ 329,
175
+ 335
176
+ ]
177
+ }
178
+ ],
179
+ "properties": {
180
+ "cnr_id": "comfy-core",
181
+ "ver": "0.3.48",
182
+ "Node name for S&R": "VAELoader",
183
+ "models": [
184
+ {
185
+ "name": "qwen_image_vae.safetensors",
186
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/vae/qwen_image_vae.safetensors",
187
+ "directory": "vae"
188
+ }
189
+ ],
190
+ "enableTabs": false,
191
+ "tabWidth": 65,
192
+ "tabXOffset": 10,
193
+ "hasSecondTab": false,
194
+ "secondTabText": "Send Back",
195
+ "secondTabOffset": 80,
196
+ "secondTabWidth": 65,
197
+ "widget_ue_connectable": {}
198
+ },
199
+ "widgets_values": [
200
+ "qwen_image_vae.safetensors"
201
+ ]
202
+ },
203
+ {
204
+ "id": 121,
205
+ "type": "CLIPTextEncode",
206
+ "pos": [
207
+ -454.4298095703125,
208
+ 247.9816436767578
209
+ ],
210
+ "size": [
211
+ 425.27801513671875,
212
+ 180.6060791015625
213
+ ],
214
+ "flags": {},
215
+ "order": 6,
216
+ "mode": 0,
217
+ "inputs": [
218
+ {
219
+ "name": "clip",
220
+ "type": "CLIP",
221
+ "link": 319
222
+ }
223
+ ],
224
+ "outputs": [
225
+ {
226
+ "name": "CONDITIONING",
227
+ "type": "CONDITIONING",
228
+ "slot_index": 0,
229
+ "links": [
230
+ 324
231
+ ]
232
+ }
233
+ ],
234
+ "title": "CLIP Text Encode (Negative Prompt)",
235
+ "properties": {
236
+ "cnr_id": "comfy-core",
237
+ "ver": "0.3.48",
238
+ "Node name for S&R": "CLIPTextEncode",
239
+ "enableTabs": false,
240
+ "tabWidth": 65,
241
+ "tabXOffset": 10,
242
+ "hasSecondTab": false,
243
+ "secondTabText": "Send Back",
244
+ "secondTabOffset": 80,
245
+ "secondTabWidth": 65,
246
+ "widget_ue_connectable": {}
247
+ },
248
+ "widgets_values": [
249
+ " low quality, bad anatomy, extra digits, missing digits, extra limbs, missing limbs"
250
+ ],
251
+ "color": "#322",
252
+ "bgcolor": "#533"
253
+ },
254
+ {
255
+ "id": 122,
256
+ "type": "ModelSamplingAuraFlow",
257
+ "pos": [
258
+ -34.14249038696289,
259
+ -43.64523696899414
260
+ ],
261
+ "size": [
262
+ 300,
263
+ 58
264
+ ],
265
+ "flags": {},
266
+ "order": 7,
267
+ "mode": 0,
268
+ "inputs": [
269
+ {
270
+ "name": "model",
271
+ "type": "MODEL",
272
+ "link": 320
273
+ }
274
+ ],
275
+ "outputs": [
276
+ {
277
+ "name": "MODEL",
278
+ "type": "MODEL",
279
+ "links": [
280
+ 325
281
+ ]
282
+ }
283
+ ],
284
+ "properties": {
285
+ "cnr_id": "comfy-core",
286
+ "ver": "0.3.48",
287
+ "Node name for S&R": "ModelSamplingAuraFlow",
288
+ "enableTabs": false,
289
+ "tabWidth": 65,
290
+ "tabXOffset": 10,
291
+ "hasSecondTab": false,
292
+ "secondTabText": "Send Back",
293
+ "secondTabOffset": 80,
294
+ "secondTabWidth": 65,
295
+ "widget_ue_connectable": {}
296
+ },
297
+ "widgets_values": [
298
+ 3.5
299
+ ]
300
+ },
301
+ {
302
+ "id": 119,
303
+ "type": "UNETLoader",
304
+ "pos": [
305
+ -824.4296875,
306
+ 37.98154830932617
307
+ ],
308
+ "size": [
309
+ 330,
310
+ 90
311
+ ],
312
+ "flags": {},
313
+ "order": 2,
314
+ "mode": 0,
315
+ "inputs": [],
316
+ "outputs": [
317
+ {
318
+ "name": "MODEL",
319
+ "type": "MODEL",
320
+ "slot_index": 0,
321
+ "links": [
322
+ 320
323
+ ]
324
+ }
325
+ ],
326
+ "properties": {
327
+ "cnr_id": "comfy-core",
328
+ "ver": "0.3.48",
329
+ "Node name for S&R": "UNETLoader",
330
+ "models": [
331
+ {
332
+ "name": "qwen_image_fp8_e4m3fn.safetensors",
333
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/diffusion_models/qwen_image_fp8_e4m3fn.safetensors",
334
+ "directory": "diffusion_models"
335
+ }
336
+ ],
337
+ "enableTabs": false,
338
+ "tabWidth": 65,
339
+ "tabXOffset": 10,
340
+ "hasSecondTab": false,
341
+ "secondTabText": "Send Back",
342
+ "secondTabOffset": 80,
343
+ "secondTabWidth": 65,
344
+ "widget_ue_connectable": {}
345
+ },
346
+ "widgets_values": [
347
+ "qwen_image_fp8_e4m3fn.safetensors",
348
+ "default"
349
+ ]
350
+ },
351
+ {
352
+ "id": 124,
353
+ "type": "VAEEncode",
354
+ "pos": [
355
+ -530.8583984375,
356
+ 708.7066650390625
357
+ ],
358
+ "size": [
359
+ 210,
360
+ 46
361
+ ],
362
+ "flags": {},
363
+ "order": 8,
364
+ "mode": 0,
365
+ "inputs": [
366
+ {
367
+ "name": "pixels",
368
+ "type": "IMAGE",
369
+ "link": 326
370
+ },
371
+ {
372
+ "name": "vae",
373
+ "type": "VAE",
374
+ "link": 329
375
+ }
376
+ ],
377
+ "outputs": [
378
+ {
379
+ "name": "LATENT",
380
+ "type": "LATENT",
381
+ "slot_index": 0,
382
+ "links": [
383
+ 327
384
+ ]
385
+ }
386
+ ],
387
+ "properties": {
388
+ "cnr_id": "comfy-core",
389
+ "ver": "0.3.23",
390
+ "Node name for S&R": "VAEEncode"
391
+ },
392
+ "widgets_values": []
393
+ },
394
+ {
395
+ "id": 125,
396
+ "type": "SetLatentNoiseMask",
397
+ "pos": [
398
+ -234.4196014404297,
399
+ 705.1629638671875
400
+ ],
401
+ "size": [
402
+ 264.5999755859375,
403
+ 46
404
+ ],
405
+ "flags": {},
406
+ "order": 9,
407
+ "mode": 0,
408
+ "inputs": [
409
+ {
410
+ "name": "samples",
411
+ "type": "LATENT",
412
+ "link": 327
413
+ },
414
+ {
415
+ "name": "mask",
416
+ "type": "MASK",
417
+ "link": 328
418
+ }
419
+ ],
420
+ "outputs": [
421
+ {
422
+ "name": "LATENT",
423
+ "type": "LATENT",
424
+ "slot_index": 0,
425
+ "links": [
426
+ 332
427
+ ]
428
+ }
429
+ ],
430
+ "properties": {
431
+ "cnr_id": "comfy-core",
432
+ "ver": "0.3.23",
433
+ "Node name for S&R": "SetLatentNoiseMask"
434
+ },
435
+ "widgets_values": []
436
+ },
437
+ {
438
+ "id": 127,
439
+ "type": "LanPaint_MaskBlend",
440
+ "pos": [
441
+ 405.3840637207031,
442
+ 938.8120727539062
443
+ ],
444
+ "size": [
445
+ 210,
446
+ 98
447
+ ],
448
+ "flags": {},
449
+ "order": 12,
450
+ "mode": 0,
451
+ "inputs": [
452
+ {
453
+ "name": "image1",
454
+ "type": "IMAGE",
455
+ "link": 336
456
+ },
457
+ {
458
+ "name": "image2",
459
+ "type": "IMAGE",
460
+ "link": 333
461
+ },
462
+ {
463
+ "name": "mask",
464
+ "type": "MASK",
465
+ "link": 337
466
+ }
467
+ ],
468
+ "outputs": [
469
+ {
470
+ "name": "IMAGE",
471
+ "type": "IMAGE",
472
+ "links": [
473
+ 338
474
+ ]
475
+ }
476
+ ],
477
+ "properties": {
478
+ "cnr_id": "LanPaint",
479
+ "ver": "4d3d5d17f0105b673df92da5b084cce567c9c712",
480
+ "Node name for S&R": "LanPaint_MaskBlend"
481
+ },
482
+ "widgets_values": [
483
+ 9
484
+ ]
485
+ },
486
+ {
487
+ "id": 126,
488
+ "type": "VAEDecode",
489
+ "pos": [
490
+ 115.07575225830078,
491
+ 878.4630737304688
492
+ ],
493
+ "size": [
494
+ 210,
495
+ 46
496
+ ],
497
+ "flags": {},
498
+ "order": 11,
499
+ "mode": 0,
500
+ "inputs": [
501
+ {
502
+ "name": "samples",
503
+ "type": "LATENT",
504
+ "link": 334
505
+ },
506
+ {
507
+ "name": "vae",
508
+ "type": "VAE",
509
+ "link": 335
510
+ }
511
+ ],
512
+ "outputs": [
513
+ {
514
+ "name": "IMAGE",
515
+ "type": "IMAGE",
516
+ "slot_index": 0,
517
+ "links": [
518
+ 333
519
+ ]
520
+ }
521
+ ],
522
+ "properties": {
523
+ "cnr_id": "comfy-core",
524
+ "ver": "0.3.23",
525
+ "Node name for S&R": "VAEDecode"
526
+ },
527
+ "widgets_values": []
528
+ },
529
+ {
530
+ "id": 123,
531
+ "type": "LoadImage",
532
+ "pos": [
533
+ -543.5358276367188,
534
+ 851.759765625
535
+ ],
536
+ "size": [
537
+ 262.12347412109375,
538
+ 487.22296142578125
539
+ ],
540
+ "flags": {},
541
+ "order": 3,
542
+ "mode": 0,
543
+ "inputs": [],
544
+ "outputs": [
545
+ {
546
+ "name": "IMAGE",
547
+ "type": "IMAGE",
548
+ "slot_index": 0,
549
+ "links": [
550
+ 326,
551
+ 336
552
+ ]
553
+ },
554
+ {
555
+ "name": "MASK",
556
+ "type": "MASK",
557
+ "slot_index": 1,
558
+ "links": [
559
+ 328,
560
+ 337
561
+ ]
562
+ }
563
+ ],
564
+ "properties": {
565
+ "cnr_id": "comfy-core",
566
+ "ver": "0.3.23",
567
+ "Node name for S&R": "LoadImage"
568
+ },
569
+ "widgets_values": [
570
+ "Masked_Load_Me_in_Loader (7).png",
571
+ "image"
572
+ ]
573
+ },
574
+ {
575
+ "id": 120,
576
+ "type": "CLIPTextEncode",
577
+ "pos": [
578
+ -454.86480712890625,
579
+ 41.89194869995117
580
+ ],
581
+ "size": [
582
+ 422.84503173828125,
583
+ 164.31304931640625
584
+ ],
585
+ "flags": {},
586
+ "order": 5,
587
+ "mode": 0,
588
+ "inputs": [
589
+ {
590
+ "name": "clip",
591
+ "type": "CLIP",
592
+ "link": 318
593
+ }
594
+ ],
595
+ "outputs": [
596
+ {
597
+ "name": "CONDITIONING",
598
+ "type": "CONDITIONING",
599
+ "slot_index": 0,
600
+ "links": [
601
+ 323
602
+ ]
603
+ }
604
+ ],
605
+ "title": "CLIP Text Encode (Positive Prompt)",
606
+ "properties": {
607
+ "cnr_id": "comfy-core",
608
+ "ver": "0.3.48",
609
+ "Node name for S&R": "CLIPTextEncode",
610
+ "enableTabs": false,
611
+ "tabWidth": 65,
612
+ "tabXOffset": 10,
613
+ "hasSecondTab": false,
614
+ "secondTabText": "Send Back",
615
+ "secondTabOffset": 80,
616
+ "secondTabWidth": 65,
617
+ "widget_ue_connectable": {}
618
+ },
619
+ "widgets_values": [
620
+ "Cyberpunk-style Einstein portrait: He wears a sleek black coat with glowing cyan circuit patterns, silver-rimmed cybernetic glasses (lenses display faint data streams), and his hair has subtle neon blue highlights. His expression is calm, with a faint smile. Behind him: a dark, rain-washed cybercity backdrop—towering skyscrapers with flickering holographic ads, wet pavement reflecting neon pink/magenta lights. In front of him: giant, glowing white 3D text of \"LanPaint\", with electric blue energy pulses swirling around the equation. Cinematic lighting, hyper-detailed textures, rain droplets visible in the air."
621
+ ],
622
+ "color": "#232",
623
+ "bgcolor": "#353"
624
+ },
625
+ {
626
+ "id": 128,
627
+ "type": "MarkdownNote",
628
+ "pos": [
629
+ 715.929931640625,
630
+ 371.1071472167969
631
+ ],
632
+ "size": [
633
+ 300,
634
+ 190
635
+ ],
636
+ "flags": {},
637
+ "order": 4,
638
+ "mode": 0,
639
+ "inputs": [],
640
+ "outputs": [],
641
+ "title": "KSampler settings",
642
+ "properties": {},
643
+ "widgets_values": [
644
+ "Decrease **LanPaint_NumSteps** for faster generation. \n"
645
+ ],
646
+ "color": "#432",
647
+ "bgcolor": "#653"
648
+ }
649
+ ],
650
+ "links": [
651
+ [
652
+ 318,
653
+ 117,
654
+ 0,
655
+ 120,
656
+ 0,
657
+ "CLIP"
658
+ ],
659
+ [
660
+ 319,
661
+ 117,
662
+ 0,
663
+ 121,
664
+ 0,
665
+ "CLIP"
666
+ ],
667
+ [
668
+ 320,
669
+ 119,
670
+ 0,
671
+ 122,
672
+ 0,
673
+ "MODEL"
674
+ ],
675
+ [
676
+ 323,
677
+ 120,
678
+ 0,
679
+ 74,
680
+ 1,
681
+ "CONDITIONING"
682
+ ],
683
+ [
684
+ 324,
685
+ 121,
686
+ 0,
687
+ 74,
688
+ 2,
689
+ "CONDITIONING"
690
+ ],
691
+ [
692
+ 325,
693
+ 122,
694
+ 0,
695
+ 74,
696
+ 0,
697
+ "MODEL"
698
+ ],
699
+ [
700
+ 326,
701
+ 123,
702
+ 0,
703
+ 124,
704
+ 0,
705
+ "IMAGE"
706
+ ],
707
+ [
708
+ 327,
709
+ 124,
710
+ 0,
711
+ 125,
712
+ 0,
713
+ "LATENT"
714
+ ],
715
+ [
716
+ 328,
717
+ 123,
718
+ 1,
719
+ 125,
720
+ 1,
721
+ "MASK"
722
+ ],
723
+ [
724
+ 329,
725
+ 118,
726
+ 0,
727
+ 124,
728
+ 1,
729
+ "VAE"
730
+ ],
731
+ [
732
+ 332,
733
+ 125,
734
+ 0,
735
+ 74,
736
+ 3,
737
+ "LATENT"
738
+ ],
739
+ [
740
+ 333,
741
+ 126,
742
+ 0,
743
+ 127,
744
+ 1,
745
+ "IMAGE"
746
+ ],
747
+ [
748
+ 334,
749
+ 74,
750
+ 0,
751
+ 126,
752
+ 0,
753
+ "LATENT"
754
+ ],
755
+ [
756
+ 335,
757
+ 118,
758
+ 0,
759
+ 126,
760
+ 1,
761
+ "VAE"
762
+ ],
763
+ [
764
+ 336,
765
+ 123,
766
+ 0,
767
+ 127,
768
+ 0,
769
+ "IMAGE"
770
+ ],
771
+ [
772
+ 337,
773
+ 123,
774
+ 1,
775
+ 127,
776
+ 2,
777
+ "MASK"
778
+ ],
779
+ [
780
+ 338,
781
+ 127,
782
+ 0,
783
+ 113,
784
+ 0,
785
+ "IMAGE"
786
+ ]
787
+ ],
788
+ "groups": [],
789
+ "config": {},
790
+ "extra": {
791
+ "ds": {
792
+ "scale": 0.7162766973052638,
793
+ "offset": [
794
+ 1084.0595529886727,
795
+ 5.084234529384386
796
+ ]
797
+ },
798
+ "frontendVersion": "1.25.10",
799
+ "node_versions": {
800
+ "comfy-core": "0.3.18",
801
+ "LanPaint": "0f509469ed2cd60c6032f739e282aad5dfc06166"
802
+ },
803
+ "groupNodes": {}
804
+ },
805
+ "version": 0.4
806
+ }
LanPaint/example_workflows/Qwen_Image_Outpaint.jpg ADDED

Git LFS Details

  • SHA256: 464f2cd7bfcef06bfc32f79b8d08f8c064048b5cc2e83b3eb58da4eb5139143d
  • Pointer size: 131 Bytes
  • Size of remote file: 830 kB
LanPaint/example_workflows/Qwen_Image_Outpaint.json ADDED
@@ -0,0 +1,909 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "11cce4ab-536b-4f42-a95c-0be437d04ace",
3
+ "revision": 0,
4
+ "last_node_id": 136,
5
+ "last_link_id": 351,
6
+ "nodes": [
7
+ {
8
+ "id": 74,
9
+ "type": "LanPaint_KSampler",
10
+ "pos": [
11
+ 276.219970703125,
12
+ 179.55892944335938
13
+ ],
14
+ "size": [
15
+ 388.97625732421875,
16
+ 572
17
+ ],
18
+ "flags": {},
19
+ "order": 12,
20
+ "mode": 0,
21
+ "inputs": [
22
+ {
23
+ "name": "model",
24
+ "type": "MODEL",
25
+ "link": 336
26
+ },
27
+ {
28
+ "name": "positive",
29
+ "type": "CONDITIONING",
30
+ "link": 334
31
+ },
32
+ {
33
+ "name": "negative",
34
+ "type": "CONDITIONING",
35
+ "link": 335
36
+ },
37
+ {
38
+ "name": "latent_image",
39
+ "type": "LATENT",
40
+ "link": 345
41
+ }
42
+ ],
43
+ "outputs": [
44
+ {
45
+ "name": "LATENT",
46
+ "type": "LATENT",
47
+ "slot_index": 0,
48
+ "links": [
49
+ 347
50
+ ]
51
+ }
52
+ ],
53
+ "properties": {
54
+ "cnr_id": "LanPaint",
55
+ "ver": "56bd6c04e89124cd06682b304245d6ddf8b20522",
56
+ "Node name for S&R": "LanPaint_KSampler"
57
+ },
58
+ "widgets_values": [
59
+ 0,
60
+ "fixed",
61
+ 20,
62
+ 4,
63
+ "euler",
64
+ "simple",
65
+ 1,
66
+ 5,
67
+ "Image First",
68
+ "LanPaint KSampler. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!"
69
+ ]
70
+ },
71
+ {
72
+ "id": 113,
73
+ "type": "SaveImage",
74
+ "pos": [
75
+ 807.1268310546875,
76
+ 868.395263671875
77
+ ],
78
+ "size": [
79
+ 311.2532653808594,
80
+ 484.7096252441406
81
+ ],
82
+ "flags": {},
83
+ "order": 15,
84
+ "mode": 0,
85
+ "inputs": [
86
+ {
87
+ "name": "images",
88
+ "type": "IMAGE",
89
+ "link": 351
90
+ }
91
+ ],
92
+ "outputs": [],
93
+ "properties": {
94
+ "cnr_id": "comfy-core",
95
+ "ver": "0.3.23"
96
+ },
97
+ "widgets_values": [
98
+ "ComfyUI"
99
+ ]
100
+ },
101
+ {
102
+ "id": 123,
103
+ "type": "CLIPLoader",
104
+ "pos": [
105
+ -730.1405029296875,
106
+ 183.70140075683594
107
+ ],
108
+ "size": [
109
+ 330,
110
+ 110
111
+ ],
112
+ "flags": {},
113
+ "order": 0,
114
+ "mode": 0,
115
+ "inputs": [],
116
+ "outputs": [
117
+ {
118
+ "name": "CLIP",
119
+ "type": "CLIP",
120
+ "slot_index": 0,
121
+ "links": [
122
+ 329,
123
+ 330
124
+ ]
125
+ }
126
+ ],
127
+ "properties": {
128
+ "cnr_id": "comfy-core",
129
+ "ver": "0.3.48",
130
+ "Node name for S&R": "CLIPLoader",
131
+ "models": [
132
+ {
133
+ "name": "qwen_2.5_vl_7b_fp8_scaled.safetensors",
134
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/text_encoders/qwen_2.5_vl_7b_fp8_scaled.safetensors",
135
+ "directory": "text_encoders"
136
+ }
137
+ ],
138
+ "enableTabs": false,
139
+ "tabWidth": 65,
140
+ "tabXOffset": 10,
141
+ "hasSecondTab": false,
142
+ "secondTabText": "Send Back",
143
+ "secondTabOffset": 80,
144
+ "secondTabWidth": 65,
145
+ "widget_ue_connectable": {}
146
+ },
147
+ "widgets_values": [
148
+ "qwen_2.5_vl_7b_fp8_scaled.safetensors",
149
+ "qwen_image",
150
+ "default"
151
+ ]
152
+ },
153
+ {
154
+ "id": 124,
155
+ "type": "VAELoader",
156
+ "pos": [
157
+ -730.1405029296875,
158
+ 333.70147705078125
159
+ ],
160
+ "size": [
161
+ 330,
162
+ 60
163
+ ],
164
+ "flags": {},
165
+ "order": 1,
166
+ "mode": 0,
167
+ "inputs": [],
168
+ "outputs": [
169
+ {
170
+ "name": "VAE",
171
+ "type": "VAE",
172
+ "slot_index": 0,
173
+ "links": [
174
+ 342,
175
+ 348
176
+ ]
177
+ }
178
+ ],
179
+ "properties": {
180
+ "cnr_id": "comfy-core",
181
+ "ver": "0.3.48",
182
+ "Node name for S&R": "VAELoader",
183
+ "models": [
184
+ {
185
+ "name": "qwen_image_vae.safetensors",
186
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/vae/qwen_image_vae.safetensors",
187
+ "directory": "vae"
188
+ }
189
+ ],
190
+ "enableTabs": false,
191
+ "tabWidth": 65,
192
+ "tabXOffset": 10,
193
+ "hasSecondTab": false,
194
+ "secondTabText": "Send Back",
195
+ "secondTabOffset": 80,
196
+ "secondTabWidth": 65,
197
+ "widget_ue_connectable": {}
198
+ },
199
+ "widgets_values": [
200
+ "qwen_image_vae.safetensors"
201
+ ]
202
+ },
203
+ {
204
+ "id": 125,
205
+ "type": "UNETLoader",
206
+ "pos": [
207
+ -730.1405029296875,
208
+ 43.7014274597168
209
+ ],
210
+ "size": [
211
+ 330,
212
+ 90
213
+ ],
214
+ "flags": {},
215
+ "order": 2,
216
+ "mode": 0,
217
+ "inputs": [],
218
+ "outputs": [
219
+ {
220
+ "name": "MODEL",
221
+ "type": "MODEL",
222
+ "slot_index": 0,
223
+ "links": [
224
+ 331
225
+ ]
226
+ }
227
+ ],
228
+ "properties": {
229
+ "cnr_id": "comfy-core",
230
+ "ver": "0.3.48",
231
+ "Node name for S&R": "UNETLoader",
232
+ "models": [
233
+ {
234
+ "name": "qwen_image_fp8_e4m3fn.safetensors",
235
+ "url": "https://huggingface.co/Comfy-Org/Qwen-Image_ComfyUI/resolve/main/split_files/diffusion_models/qwen_image_fp8_e4m3fn.safetensors",
236
+ "directory": "diffusion_models"
237
+ }
238
+ ],
239
+ "enableTabs": false,
240
+ "tabWidth": 65,
241
+ "tabXOffset": 10,
242
+ "hasSecondTab": false,
243
+ "secondTabText": "Send Back",
244
+ "secondTabOffset": 80,
245
+ "secondTabWidth": 65,
246
+ "widget_ue_connectable": {}
247
+ },
248
+ "widgets_values": [
249
+ "qwen_image_fp8_e4m3fn.safetensors",
250
+ "default"
251
+ ]
252
+ },
253
+ {
254
+ "id": 127,
255
+ "type": "CLIPTextEncode",
256
+ "pos": [
257
+ -360.1405029296875,
258
+ 253.70147705078125
259
+ ],
260
+ "size": [
261
+ 425.27801513671875,
262
+ 180.6060791015625
263
+ ],
264
+ "flags": {},
265
+ "order": 6,
266
+ "mode": 0,
267
+ "inputs": [
268
+ {
269
+ "name": "clip",
270
+ "type": "CLIP",
271
+ "link": 330
272
+ }
273
+ ],
274
+ "outputs": [
275
+ {
276
+ "name": "CONDITIONING",
277
+ "type": "CONDITIONING",
278
+ "slot_index": 0,
279
+ "links": [
280
+ 335
281
+ ]
282
+ }
283
+ ],
284
+ "title": "CLIP Text Encode (Negative Prompt)",
285
+ "properties": {
286
+ "cnr_id": "comfy-core",
287
+ "ver": "0.3.48",
288
+ "Node name for S&R": "CLIPTextEncode",
289
+ "enableTabs": false,
290
+ "tabWidth": 65,
291
+ "tabXOffset": 10,
292
+ "hasSecondTab": false,
293
+ "secondTabText": "Send Back",
294
+ "secondTabOffset": 80,
295
+ "secondTabWidth": 65,
296
+ "widget_ue_connectable": {}
297
+ },
298
+ "widgets_values": [
299
+ " low quality, bad anatomy, extra digits, missing digits, extra limbs, missing limbs"
300
+ ],
301
+ "color": "#322",
302
+ "bgcolor": "#533"
303
+ },
304
+ {
305
+ "id": 128,
306
+ "type": "ModelSamplingAuraFlow",
307
+ "pos": [
308
+ 60.14683151245117,
309
+ -37.92536544799805
310
+ ],
311
+ "size": [
312
+ 300,
313
+ 58
314
+ ],
315
+ "flags": {},
316
+ "order": 7,
317
+ "mode": 0,
318
+ "inputs": [
319
+ {
320
+ "name": "model",
321
+ "type": "MODEL",
322
+ "link": 331
323
+ }
324
+ ],
325
+ "outputs": [
326
+ {
327
+ "name": "MODEL",
328
+ "type": "MODEL",
329
+ "links": [
330
+ 336
331
+ ]
332
+ }
333
+ ],
334
+ "properties": {
335
+ "cnr_id": "comfy-core",
336
+ "ver": "0.3.48",
337
+ "Node name for S&R": "ModelSamplingAuraFlow",
338
+ "enableTabs": false,
339
+ "tabWidth": 65,
340
+ "tabXOffset": 10,
341
+ "hasSecondTab": false,
342
+ "secondTabText": "Send Back",
343
+ "secondTabOffset": 80,
344
+ "secondTabWidth": 65,
345
+ "widget_ue_connectable": {}
346
+ },
347
+ "widgets_values": [
348
+ 3.5
349
+ ]
350
+ },
351
+ {
352
+ "id": 126,
353
+ "type": "CLIPTextEncode",
354
+ "pos": [
355
+ -360.57550048828125,
356
+ 47.6118278503418
357
+ ],
358
+ "size": [
359
+ 422.84503173828125,
360
+ 164.31304931640625
361
+ ],
362
+ "flags": {},
363
+ "order": 5,
364
+ "mode": 0,
365
+ "inputs": [
366
+ {
367
+ "name": "clip",
368
+ "type": "CLIP",
369
+ "link": 329
370
+ }
371
+ ],
372
+ "outputs": [
373
+ {
374
+ "name": "CONDITIONING",
375
+ "type": "CONDITIONING",
376
+ "slot_index": 0,
377
+ "links": [
378
+ 334
379
+ ]
380
+ }
381
+ ],
382
+ "title": "CLIP Text Encode (Positive Prompt)",
383
+ "properties": {
384
+ "cnr_id": "comfy-core",
385
+ "ver": "0.3.48",
386
+ "Node name for S&R": "CLIPTextEncode",
387
+ "enableTabs": false,
388
+ "tabWidth": 65,
389
+ "tabXOffset": 10,
390
+ "hasSecondTab": false,
391
+ "secondTabText": "Send Back",
392
+ "secondTabOffset": 80,
393
+ "secondTabWidth": 65,
394
+ "widget_ue_connectable": {}
395
+ },
396
+ "widgets_values": [
397
+ "Cyberpunk-inspired portrait of a beautiful young woman with ethereal features: She has long, flowing silver hair with glowing purple neon streaks, wearing a form-fitting black leather jacket adorned with holographic circuit designs in electric blue, and augmented reality earrings that project faint digital fractals. Her eyes are piercing emerald green with subtle cybernetic enhancements showing data overlays, and her expression is mysterious yet alluring, with a subtle smirk. Behind her: a foggy, neon-lit futuristic alleyway—crumbling brick walls covered in vibrant graffiti and flickering LED signs, puddles on the ground reflecting turquoise and violet lights from overhead drones. Dramatic volumetric lighting, ultra-realistic details, mist particles in the air."
398
+ ],
399
+ "color": "#232",
400
+ "bgcolor": "#353"
401
+ },
402
+ {
403
+ "id": 130,
404
+ "type": "ImagePadForOutpaint",
405
+ "pos": [
406
+ -437.0110168457031,
407
+ 895.0103759765625
408
+ ],
409
+ "size": [
410
+ 210,
411
+ 174
412
+ ],
413
+ "flags": {},
414
+ "order": 8,
415
+ "mode": 0,
416
+ "inputs": [
417
+ {
418
+ "name": "image",
419
+ "type": "IMAGE",
420
+ "link": 337
421
+ }
422
+ ],
423
+ "outputs": [
424
+ {
425
+ "name": "IMAGE",
426
+ "type": "IMAGE",
427
+ "links": [
428
+ 338,
429
+ 349
430
+ ]
431
+ },
432
+ {
433
+ "name": "MASK",
434
+ "type": "MASK",
435
+ "links": [
436
+ 339
437
+ ]
438
+ }
439
+ ],
440
+ "properties": {
441
+ "cnr_id": "comfy-core",
442
+ "ver": "0.3.39",
443
+ "Node name for S&R": "ImagePadForOutpaint",
444
+ "widget_ue_connectable": {}
445
+ },
446
+ "widgets_values": [
447
+ 200,
448
+ 200,
449
+ 200,
450
+ 200,
451
+ 20
452
+ ]
453
+ },
454
+ {
455
+ "id": 131,
456
+ "type": "VAEEncode",
457
+ "pos": [
458
+ -455.7289123535156,
459
+ 723.4658203125
460
+ ],
461
+ "size": [
462
+ 210,
463
+ 46
464
+ ],
465
+ "flags": {},
466
+ "order": 9,
467
+ "mode": 0,
468
+ "inputs": [
469
+ {
470
+ "name": "pixels",
471
+ "type": "IMAGE",
472
+ "link": 338
473
+ },
474
+ {
475
+ "name": "vae",
476
+ "type": "VAE",
477
+ "link": 342
478
+ }
479
+ ],
480
+ "outputs": [
481
+ {
482
+ "name": "LATENT",
483
+ "type": "LATENT",
484
+ "slot_index": 0,
485
+ "links": [
486
+ 340
487
+ ]
488
+ }
489
+ ],
490
+ "properties": {
491
+ "cnr_id": "comfy-core",
492
+ "ver": "0.3.23",
493
+ "Node name for S&R": "VAEEncode"
494
+ },
495
+ "widgets_values": []
496
+ },
497
+ {
498
+ "id": 132,
499
+ "type": "ThresholdMask",
500
+ "pos": [
501
+ -67.46508026123047,
502
+ 903.83642578125
503
+ ],
504
+ "size": [
505
+ 270,
506
+ 58
507
+ ],
508
+ "flags": {},
509
+ "order": 10,
510
+ "mode": 0,
511
+ "inputs": [
512
+ {
513
+ "name": "mask",
514
+ "type": "MASK",
515
+ "link": 339
516
+ }
517
+ ],
518
+ "outputs": [
519
+ {
520
+ "name": "MASK",
521
+ "type": "MASK",
522
+ "links": [
523
+ 341,
524
+ 350
525
+ ]
526
+ }
527
+ ],
528
+ "properties": {
529
+ "cnr_id": "comfy-core",
530
+ "ver": "0.3.38",
531
+ "Node name for S&R": "ThresholdMask"
532
+ },
533
+ "widgets_values": [
534
+ 0.010000000000000002
535
+ ]
536
+ },
537
+ {
538
+ "id": 133,
539
+ "type": "SetLatentNoiseMask",
540
+ "pos": [
541
+ -152.71241760253906,
542
+ 712.6437377929688
543
+ ],
544
+ "size": [
545
+ 264.5999755859375,
546
+ 46
547
+ ],
548
+ "flags": {},
549
+ "order": 11,
550
+ "mode": 0,
551
+ "inputs": [
552
+ {
553
+ "name": "samples",
554
+ "type": "LATENT",
555
+ "link": 340
556
+ },
557
+ {
558
+ "name": "mask",
559
+ "type": "MASK",
560
+ "link": 341
561
+ }
562
+ ],
563
+ "outputs": [
564
+ {
565
+ "name": "LATENT",
566
+ "type": "LATENT",
567
+ "slot_index": 0,
568
+ "links": [
569
+ 345
570
+ ]
571
+ }
572
+ ],
573
+ "properties": {
574
+ "cnr_id": "comfy-core",
575
+ "ver": "0.3.23",
576
+ "Node name for S&R": "SetLatentNoiseMask"
577
+ },
578
+ "widgets_values": []
579
+ },
580
+ {
581
+ "id": 129,
582
+ "type": "LoadImage",
583
+ "pos": [
584
+ -789.0392456054688,
585
+ 827.515380859375
586
+ ],
587
+ "size": [
588
+ 295,
589
+ 399
590
+ ],
591
+ "flags": {},
592
+ "order": 3,
593
+ "mode": 0,
594
+ "inputs": [],
595
+ "outputs": [
596
+ {
597
+ "name": "IMAGE",
598
+ "type": "IMAGE",
599
+ "links": [
600
+ 337
601
+ ]
602
+ },
603
+ {
604
+ "name": "MASK",
605
+ "type": "MASK",
606
+ "links": []
607
+ }
608
+ ],
609
+ "properties": {
610
+ "cnr_id": "comfy-core",
611
+ "ver": "0.3.27",
612
+ "Node name for S&R": "LoadImage",
613
+ "widget_ue_connectable": {}
614
+ },
615
+ "widgets_values": [
616
+ "ComfyUI_07699_.png",
617
+ "image"
618
+ ]
619
+ },
620
+ {
621
+ "id": 134,
622
+ "type": "VAEDecode",
623
+ "pos": [
624
+ 256.8516540527344,
625
+ 900.2234497070312
626
+ ],
627
+ "size": [
628
+ 210,
629
+ 46
630
+ ],
631
+ "flags": {},
632
+ "order": 13,
633
+ "mode": 0,
634
+ "inputs": [
635
+ {
636
+ "name": "samples",
637
+ "type": "LATENT",
638
+ "link": 347
639
+ },
640
+ {
641
+ "name": "vae",
642
+ "type": "VAE",
643
+ "link": 348
644
+ }
645
+ ],
646
+ "outputs": [
647
+ {
648
+ "name": "IMAGE",
649
+ "type": "IMAGE",
650
+ "slot_index": 0,
651
+ "links": [
652
+ 346
653
+ ]
654
+ }
655
+ ],
656
+ "properties": {
657
+ "cnr_id": "comfy-core",
658
+ "ver": "0.3.23",
659
+ "Node name for S&R": "VAEDecode"
660
+ },
661
+ "widgets_values": []
662
+ },
663
+ {
664
+ "id": 135,
665
+ "type": "LanPaint_MaskBlend",
666
+ "pos": [
667
+ 547.1599731445312,
668
+ 960.5724487304688
669
+ ],
670
+ "size": [
671
+ 210,
672
+ 98
673
+ ],
674
+ "flags": {},
675
+ "order": 14,
676
+ "mode": 0,
677
+ "inputs": [
678
+ {
679
+ "name": "image1",
680
+ "type": "IMAGE",
681
+ "link": 349
682
+ },
683
+ {
684
+ "name": "image2",
685
+ "type": "IMAGE",
686
+ "link": 346
687
+ },
688
+ {
689
+ "name": "mask",
690
+ "type": "MASK",
691
+ "link": 350
692
+ }
693
+ ],
694
+ "outputs": [
695
+ {
696
+ "name": "IMAGE",
697
+ "type": "IMAGE",
698
+ "links": [
699
+ 351
700
+ ]
701
+ }
702
+ ],
703
+ "properties": {
704
+ "cnr_id": "LanPaint",
705
+ "ver": "4d3d5d17f0105b673df92da5b084cce567c9c712",
706
+ "Node name for S&R": "LanPaint_MaskBlend"
707
+ },
708
+ "widgets_values": [
709
+ 9
710
+ ]
711
+ },
712
+ {
713
+ "id": 136,
714
+ "type": "MarkdownNote",
715
+ "pos": [
716
+ 728.9194946289062,
717
+ 332.5254821777344
718
+ ],
719
+ "size": [
720
+ 300,
721
+ 190
722
+ ],
723
+ "flags": {},
724
+ "order": 4,
725
+ "mode": 0,
726
+ "inputs": [],
727
+ "outputs": [],
728
+ "title": "KSampler settings",
729
+ "properties": {},
730
+ "widgets_values": [
731
+ "Decrease **LanPaint_NumSteps** for faster generation. \n"
732
+ ],
733
+ "color": "#432",
734
+ "bgcolor": "#653"
735
+ }
736
+ ],
737
+ "links": [
738
+ [
739
+ 329,
740
+ 123,
741
+ 0,
742
+ 126,
743
+ 0,
744
+ "CLIP"
745
+ ],
746
+ [
747
+ 330,
748
+ 123,
749
+ 0,
750
+ 127,
751
+ 0,
752
+ "CLIP"
753
+ ],
754
+ [
755
+ 331,
756
+ 125,
757
+ 0,
758
+ 128,
759
+ 0,
760
+ "MODEL"
761
+ ],
762
+ [
763
+ 334,
764
+ 126,
765
+ 0,
766
+ 74,
767
+ 1,
768
+ "CONDITIONING"
769
+ ],
770
+ [
771
+ 335,
772
+ 127,
773
+ 0,
774
+ 74,
775
+ 2,
776
+ "CONDITIONING"
777
+ ],
778
+ [
779
+ 336,
780
+ 128,
781
+ 0,
782
+ 74,
783
+ 0,
784
+ "MODEL"
785
+ ],
786
+ [
787
+ 337,
788
+ 129,
789
+ 0,
790
+ 130,
791
+ 0,
792
+ "IMAGE"
793
+ ],
794
+ [
795
+ 338,
796
+ 130,
797
+ 0,
798
+ 131,
799
+ 0,
800
+ "IMAGE"
801
+ ],
802
+ [
803
+ 339,
804
+ 130,
805
+ 1,
806
+ 132,
807
+ 0,
808
+ "MASK"
809
+ ],
810
+ [
811
+ 340,
812
+ 131,
813
+ 0,
814
+ 133,
815
+ 0,
816
+ "LATENT"
817
+ ],
818
+ [
819
+ 341,
820
+ 132,
821
+ 0,
822
+ 133,
823
+ 1,
824
+ "MASK"
825
+ ],
826
+ [
827
+ 342,
828
+ 124,
829
+ 0,
830
+ 131,
831
+ 1,
832
+ "VAE"
833
+ ],
834
+ [
835
+ 345,
836
+ 133,
837
+ 0,
838
+ 74,
839
+ 3,
840
+ "LATENT"
841
+ ],
842
+ [
843
+ 346,
844
+ 134,
845
+ 0,
846
+ 135,
847
+ 1,
848
+ "IMAGE"
849
+ ],
850
+ [
851
+ 347,
852
+ 74,
853
+ 0,
854
+ 134,
855
+ 0,
856
+ "LATENT"
857
+ ],
858
+ [
859
+ 348,
860
+ 124,
861
+ 0,
862
+ 134,
863
+ 1,
864
+ "VAE"
865
+ ],
866
+ [
867
+ 349,
868
+ 130,
869
+ 0,
870
+ 135,
871
+ 0,
872
+ "IMAGE"
873
+ ],
874
+ [
875
+ 350,
876
+ 132,
877
+ 0,
878
+ 135,
879
+ 2,
880
+ "MASK"
881
+ ],
882
+ [
883
+ 351,
884
+ 135,
885
+ 0,
886
+ 113,
887
+ 0,
888
+ "IMAGE"
889
+ ]
890
+ ],
891
+ "groups": [],
892
+ "config": {},
893
+ "extra": {
894
+ "ds": {
895
+ "scale": 0.6087272163919795,
896
+ "offset": [
897
+ 1617.0504979084035,
898
+ 167.0583828525509
899
+ ]
900
+ },
901
+ "frontendVersion": "1.25.10",
902
+ "node_versions": {
903
+ "comfy-core": "0.3.18",
904
+ "LanPaint": "0f509469ed2cd60c6032f739e282aad5dfc06166"
905
+ },
906
+ "groupNodes": {}
907
+ },
908
+ "version": 0.4
909
+ }
LanPaint/example_workflows/SDXL_Inpaint.jpg ADDED

Git LFS Details

  • SHA256: 32f61d5899e8b6e741f992fe163e5d18cd28f72d4fe49f3b348a465ffb1268bc
  • Pointer size: 132 Bytes
  • Size of remote file: 1.41 MB
LanPaint/example_workflows/SDXL_Inpaint.json ADDED
@@ -0,0 +1,735 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "26fb90cb-eb4a-422e-97d0-8b84dd6c3302",
3
+ "revision": 0,
4
+ "last_node_id": 75,
5
+ "last_link_id": 192,
6
+ "nodes": [
7
+ {
8
+ "id": 6,
9
+ "type": "CLIPTextEncode",
10
+ "pos": [
11
+ 333.06903076171875,
12
+ 249.68698120117188
13
+ ],
14
+ "size": [
15
+ 422.84503173828125,
16
+ 164.31304931640625
17
+ ],
18
+ "flags": {},
19
+ "order": 2,
20
+ "mode": 0,
21
+ "inputs": [
22
+ {
23
+ "name": "clip",
24
+ "type": "CLIP",
25
+ "link": 81
26
+ }
27
+ ],
28
+ "outputs": [
29
+ {
30
+ "name": "CONDITIONING",
31
+ "type": "CONDITIONING",
32
+ "slot_index": 0,
33
+ "links": [
34
+ 184
35
+ ]
36
+ }
37
+ ],
38
+ "properties": {
39
+ "cnr_id": "comfy-core",
40
+ "ver": "0.3.23",
41
+ "Node name for S&R": "CLIPTextEncode"
42
+ },
43
+ "widgets_values": [
44
+ "1girl, blue shirt, masterpiece, high score, great score, absurdres"
45
+ ]
46
+ },
47
+ {
48
+ "id": 7,
49
+ "type": "CLIPTextEncode",
50
+ "pos": [
51
+ 335.06903076171875,
52
+ 462.68701171875
53
+ ],
54
+ "size": [
55
+ 425.27801513671875,
56
+ 180.6060791015625
57
+ ],
58
+ "flags": {},
59
+ "order": 3,
60
+ "mode": 0,
61
+ "inputs": [
62
+ {
63
+ "name": "clip",
64
+ "type": "CLIP",
65
+ "link": 82
66
+ }
67
+ ],
68
+ "outputs": [
69
+ {
70
+ "name": "CONDITIONING",
71
+ "type": "CONDITIONING",
72
+ "slot_index": 0,
73
+ "links": [
74
+ 185
75
+ ]
76
+ }
77
+ ],
78
+ "properties": {
79
+ "cnr_id": "comfy-core",
80
+ "ver": "0.3.23",
81
+ "Node name for S&R": "CLIPTextEncode"
82
+ },
83
+ "widgets_values": [
84
+ "lowres, bad anatomy, bad hands, text, error, missing finger, extra digits, fewer digits, cropped, worst quality, low quality, low score, bad score, average score, signature, watermark, username, blurry, nude, NSFW"
85
+ ]
86
+ },
87
+ {
88
+ "id": 29,
89
+ "type": "CheckpointLoaderSimple",
90
+ "pos": [
91
+ -62.627220153808594,
92
+ 407.01416015625
93
+ ],
94
+ "size": [
95
+ 315,
96
+ 98
97
+ ],
98
+ "flags": {},
99
+ "order": 0,
100
+ "mode": 0,
101
+ "inputs": [],
102
+ "outputs": [
103
+ {
104
+ "name": "MODEL",
105
+ "type": "MODEL",
106
+ "slot_index": 0,
107
+ "links": [
108
+ 183
109
+ ]
110
+ },
111
+ {
112
+ "name": "CLIP",
113
+ "type": "CLIP",
114
+ "slot_index": 1,
115
+ "links": [
116
+ 81,
117
+ 82
118
+ ]
119
+ },
120
+ {
121
+ "name": "VAE",
122
+ "type": "VAE",
123
+ "slot_index": 2,
124
+ "links": [
125
+ 84,
126
+ 157
127
+ ]
128
+ }
129
+ ],
130
+ "properties": {
131
+ "cnr_id": "comfy-core",
132
+ "ver": "0.3.23",
133
+ "Node name for S&R": "CheckpointLoaderSimple"
134
+ },
135
+ "widgets_values": [
136
+ "animagineXL40_v4Opt.safetensors"
137
+ ]
138
+ },
139
+ {
140
+ "id": 48,
141
+ "type": "SaveImage",
142
+ "pos": [
143
+ 1091.036376953125,
144
+ 1158.526611328125
145
+ ],
146
+ "size": [
147
+ 311.2532653808594,
148
+ 484.7096252441406
149
+ ],
150
+ "flags": {},
151
+ "order": 8,
152
+ "mode": 0,
153
+ "inputs": [
154
+ {
155
+ "name": "images",
156
+ "type": "IMAGE",
157
+ "link": 103
158
+ }
159
+ ],
160
+ "outputs": [],
161
+ "properties": {
162
+ "cnr_id": "comfy-core",
163
+ "ver": "0.3.23"
164
+ },
165
+ "widgets_values": [
166
+ "ComfyUI"
167
+ ]
168
+ },
169
+ {
170
+ "id": 8,
171
+ "type": "VAEDecode",
172
+ "pos": [
173
+ 1211.46484375,
174
+ 1065.318359375
175
+ ],
176
+ "size": [
177
+ 210,
178
+ 46
179
+ ],
180
+ "flags": {},
181
+ "order": 7,
182
+ "mode": 0,
183
+ "inputs": [
184
+ {
185
+ "name": "samples",
186
+ "type": "LATENT",
187
+ "link": 187
188
+ },
189
+ {
190
+ "name": "vae",
191
+ "type": "VAE",
192
+ "link": 84
193
+ }
194
+ ],
195
+ "outputs": [
196
+ {
197
+ "name": "IMAGE",
198
+ "type": "IMAGE",
199
+ "slot_index": 0,
200
+ "links": [
201
+ 103,
202
+ 189
203
+ ]
204
+ }
205
+ ],
206
+ "properties": {
207
+ "cnr_id": "comfy-core",
208
+ "ver": "0.3.23",
209
+ "Node name for S&R": "VAEDecode"
210
+ },
211
+ "widgets_values": []
212
+ },
213
+ {
214
+ "id": 20,
215
+ "type": "LoadImage",
216
+ "pos": [
217
+ 45.70227813720703,
218
+ 1147.2928466796875
219
+ ],
220
+ "size": [
221
+ 262.12347412109375,
222
+ 487.22296142578125
223
+ ],
224
+ "flags": {},
225
+ "order": 1,
226
+ "mode": 0,
227
+ "inputs": [],
228
+ "outputs": [
229
+ {
230
+ "name": "IMAGE",
231
+ "type": "IMAGE",
232
+ "slot_index": 0,
233
+ "links": [
234
+ 156,
235
+ 190
236
+ ]
237
+ },
238
+ {
239
+ "name": "MASK",
240
+ "type": "MASK",
241
+ "slot_index": 1,
242
+ "links": [
243
+ 155,
244
+ 191
245
+ ]
246
+ }
247
+ ],
248
+ "properties": {
249
+ "cnr_id": "comfy-core",
250
+ "ver": "0.3.23",
251
+ "Node name for S&R": "LoadImage"
252
+ },
253
+ "widgets_values": [
254
+ "clipspace/clipspace-mask-2620525.399999976.png [input]",
255
+ "image"
256
+ ]
257
+ },
258
+ {
259
+ "id": 75,
260
+ "type": "SaveImage",
261
+ "pos": [
262
+ 1845.7059326171875,
263
+ 1044.06201171875
264
+ ],
265
+ "size": [
266
+ 311.2532653808594,
267
+ 484.7096252441406
268
+ ],
269
+ "flags": {},
270
+ "order": 10,
271
+ "mode": 0,
272
+ "inputs": [
273
+ {
274
+ "name": "images",
275
+ "type": "IMAGE",
276
+ "link": 188
277
+ }
278
+ ],
279
+ "outputs": [],
280
+ "properties": {
281
+ "cnr_id": "comfy-core",
282
+ "ver": "0.3.23"
283
+ },
284
+ "widgets_values": [
285
+ "ComfyUI"
286
+ ]
287
+ },
288
+ {
289
+ "id": 73,
290
+ "type": "LanPaint_KSampler",
291
+ "pos": [
292
+ 996.4982299804688,
293
+ 299.599365234375
294
+ ],
295
+ "size": [
296
+ 413.6495666503906,
297
+ 572
298
+ ],
299
+ "flags": {},
300
+ "order": 6,
301
+ "mode": 0,
302
+ "inputs": [
303
+ {
304
+ "name": "model",
305
+ "type": "MODEL",
306
+ "link": 183
307
+ },
308
+ {
309
+ "name": "positive",
310
+ "type": "CONDITIONING",
311
+ "link": 184
312
+ },
313
+ {
314
+ "name": "negative",
315
+ "type": "CONDITIONING",
316
+ "link": 185
317
+ },
318
+ {
319
+ "name": "latent_image",
320
+ "type": "LATENT",
321
+ "link": 186
322
+ }
323
+ ],
324
+ "outputs": [
325
+ {
326
+ "name": "LATENT",
327
+ "type": "LATENT",
328
+ "slot_index": 0,
329
+ "links": [
330
+ 187
331
+ ]
332
+ }
333
+ ],
334
+ "properties": {
335
+ "cnr_id": "LanPaint",
336
+ "ver": "56bd6c04e89124cd06682b304245d6ddf8b20522",
337
+ "Node name for S&R": "LanPaint_KSampler"
338
+ },
339
+ "widgets_values": [
340
+ 0,
341
+ "fixed",
342
+ 30,
343
+ 5,
344
+ "euler",
345
+ "karras",
346
+ 1,
347
+ 5,
348
+ "Image First",
349
+ "LanPaint KSampler. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!"
350
+ ]
351
+ },
352
+ {
353
+ "id": 74,
354
+ "type": "LanPaint_MaskBlend",
355
+ "pos": [
356
+ 1512.2730712890625,
357
+ 1176.3270263671875
358
+ ],
359
+ "size": [
360
+ 210,
361
+ 98
362
+ ],
363
+ "flags": {},
364
+ "order": 9,
365
+ "mode": 0,
366
+ "inputs": [
367
+ {
368
+ "name": "image1",
369
+ "type": "IMAGE",
370
+ "link": 190
371
+ },
372
+ {
373
+ "name": "image2",
374
+ "type": "IMAGE",
375
+ "link": 189
376
+ },
377
+ {
378
+ "name": "mask",
379
+ "type": "MASK",
380
+ "link": 191
381
+ }
382
+ ],
383
+ "outputs": [
384
+ {
385
+ "name": "IMAGE",
386
+ "type": "IMAGE",
387
+ "links": [
388
+ 188
389
+ ]
390
+ }
391
+ ],
392
+ "properties": {
393
+ "cnr_id": "LanPaint",
394
+ "ver": "4d3d5d17f0105b673df92da5b084cce567c9c712",
395
+ "Node name for S&R": "LanPaint_MaskBlend"
396
+ },
397
+ "widgets_values": [
398
+ 9
399
+ ]
400
+ },
401
+ {
402
+ "id": 66,
403
+ "type": "SetLatentNoiseMask",
404
+ "pos": [
405
+ 480.30780029296875,
406
+ 821.3880004882812
407
+ ],
408
+ "size": [
409
+ 264.5999755859375,
410
+ 46
411
+ ],
412
+ "flags": {},
413
+ "order": 5,
414
+ "mode": 0,
415
+ "inputs": [
416
+ {
417
+ "name": "samples",
418
+ "type": "LATENT",
419
+ "link": 192
420
+ },
421
+ {
422
+ "name": "mask",
423
+ "type": "MASK",
424
+ "link": 155
425
+ }
426
+ ],
427
+ "outputs": [
428
+ {
429
+ "name": "LATENT",
430
+ "type": "LATENT",
431
+ "slot_index": 0,
432
+ "links": [
433
+ 186
434
+ ]
435
+ }
436
+ ],
437
+ "properties": {
438
+ "cnr_id": "comfy-core",
439
+ "ver": "0.3.23",
440
+ "Node name for S&R": "SetLatentNoiseMask"
441
+ },
442
+ "widgets_values": []
443
+ },
444
+ {
445
+ "id": 65,
446
+ "type": "VAEEncode",
447
+ "pos": [
448
+ 206.43878173828125,
449
+ 818.9985961914062
450
+ ],
451
+ "size": [
452
+ 210,
453
+ 46
454
+ ],
455
+ "flags": {},
456
+ "order": 4,
457
+ "mode": 0,
458
+ "inputs": [
459
+ {
460
+ "name": "pixels",
461
+ "type": "IMAGE",
462
+ "link": 156
463
+ },
464
+ {
465
+ "name": "vae",
466
+ "type": "VAE",
467
+ "link": 157
468
+ }
469
+ ],
470
+ "outputs": [
471
+ {
472
+ "name": "LATENT",
473
+ "type": "LATENT",
474
+ "slot_index": 0,
475
+ "links": [
476
+ 192
477
+ ]
478
+ }
479
+ ],
480
+ "properties": {
481
+ "cnr_id": "comfy-core",
482
+ "ver": "0.3.23",
483
+ "Node name for S&R": "VAEEncode"
484
+ },
485
+ "widgets_values": []
486
+ }
487
+ ],
488
+ "links": [
489
+ [
490
+ 81,
491
+ 29,
492
+ 1,
493
+ 6,
494
+ 0,
495
+ "CLIP"
496
+ ],
497
+ [
498
+ 82,
499
+ 29,
500
+ 1,
501
+ 7,
502
+ 0,
503
+ "CLIP"
504
+ ],
505
+ [
506
+ 84,
507
+ 29,
508
+ 2,
509
+ 8,
510
+ 1,
511
+ "VAE"
512
+ ],
513
+ [
514
+ 103,
515
+ 8,
516
+ 0,
517
+ 48,
518
+ 0,
519
+ "IMAGE"
520
+ ],
521
+ [
522
+ 155,
523
+ 20,
524
+ 1,
525
+ 66,
526
+ 1,
527
+ "MASK"
528
+ ],
529
+ [
530
+ 156,
531
+ 20,
532
+ 0,
533
+ 65,
534
+ 0,
535
+ "IMAGE"
536
+ ],
537
+ [
538
+ 157,
539
+ 29,
540
+ 2,
541
+ 65,
542
+ 1,
543
+ "VAE"
544
+ ],
545
+ [
546
+ 183,
547
+ 29,
548
+ 0,
549
+ 73,
550
+ 0,
551
+ "MODEL"
552
+ ],
553
+ [
554
+ 184,
555
+ 6,
556
+ 0,
557
+ 73,
558
+ 1,
559
+ "CONDITIONING"
560
+ ],
561
+ [
562
+ 185,
563
+ 7,
564
+ 0,
565
+ 73,
566
+ 2,
567
+ "CONDITIONING"
568
+ ],
569
+ [
570
+ 186,
571
+ 66,
572
+ 0,
573
+ 73,
574
+ 3,
575
+ "LATENT"
576
+ ],
577
+ [
578
+ 187,
579
+ 73,
580
+ 0,
581
+ 8,
582
+ 0,
583
+ "LATENT"
584
+ ],
585
+ [
586
+ 188,
587
+ 74,
588
+ 0,
589
+ 75,
590
+ 0,
591
+ "IMAGE"
592
+ ],
593
+ [
594
+ 189,
595
+ 8,
596
+ 0,
597
+ 74,
598
+ 1,
599
+ "IMAGE"
600
+ ],
601
+ [
602
+ 190,
603
+ 20,
604
+ 0,
605
+ 74,
606
+ 0,
607
+ "IMAGE"
608
+ ],
609
+ [
610
+ 191,
611
+ 20,
612
+ 1,
613
+ 74,
614
+ 2,
615
+ "MASK"
616
+ ],
617
+ [
618
+ 192,
619
+ 65,
620
+ 0,
621
+ 66,
622
+ 0,
623
+ "LATENT"
624
+ ]
625
+ ],
626
+ "groups": [
627
+ {
628
+ "id": 1,
629
+ "title": "Mask image for inpainting.",
630
+ "bounding": [
631
+ 36.04227828979492,
632
+ 989.7313232421875,
633
+ 278.89093017578125,
634
+ 669.3414916992188
635
+ ],
636
+ "color": "#3f789e",
637
+ "font_size": 24,
638
+ "flags": {}
639
+ },
640
+ {
641
+ "id": 2,
642
+ "title": "Convert Latents for LanPaint",
643
+ "bounding": [
644
+ 286.0640563964844,
645
+ 714.343505859375,
646
+ 489.16796875,
647
+ 197.81044006347656
648
+ ],
649
+ "color": "#3f789e",
650
+ "font_size": 24,
651
+ "flags": {}
652
+ },
653
+ {
654
+ "id": 3,
655
+ "title": "Load Model and Set Prompts",
656
+ "bounding": [
657
+ -78.9311294555664,
658
+ 176.08712768554688,
659
+ 1006.1721801757812,
660
+ 514.258544921875
661
+ ],
662
+ "color": "#3f789e",
663
+ "font_size": 24,
664
+ "flags": {}
665
+ },
666
+ {
667
+ "id": 4,
668
+ "title": "Inpaint with the LanPaint KSampler",
669
+ "bounding": [
670
+ 960.8922729492188,
671
+ 179.17588806152344,
672
+ 474.8909606933594,
673
+ 630.4742431640625
674
+ ],
675
+ "color": "#3f789e",
676
+ "font_size": 24,
677
+ "flags": {}
678
+ },
679
+ {
680
+ "id": 5,
681
+ "title": "LanPaint OutPut",
682
+ "bounding": [
683
+ 1085.6029052734375,
684
+ 994.0775756835938,
685
+ 345.4561767578125,
686
+ 669.4969482421875
687
+ ],
688
+ "color": "#3f789e",
689
+ "font_size": 24,
690
+ "flags": {}
691
+ },
692
+ {
693
+ "id": 11,
694
+ "title": "LanPaint",
695
+ "bounding": [
696
+ -262.59381103515625,
697
+ 140.46656799316406,
698
+ 1737.328857421875,
699
+ 797.4443359375
700
+ ],
701
+ "color": "#3f789e",
702
+ "font_size": 24,
703
+ "flags": {}
704
+ },
705
+ {
706
+ "id": 13,
707
+ "title": "Paste back the original to preserve it exactly, if you want",
708
+ "bounding": [
709
+ 1491.586181640625,
710
+ 984.3547973632812,
711
+ 749.66455078125,
712
+ 637.360595703125
713
+ ],
714
+ "color": "#3f789e",
715
+ "font_size": 24,
716
+ "flags": {}
717
+ }
718
+ ],
719
+ "config": {},
720
+ "extra": {
721
+ "ds": {
722
+ "scale": 0.6209213230591556,
723
+ "offset": [
724
+ 850.0803535605011,
725
+ 86.6432096141053
726
+ ]
727
+ },
728
+ "frontendVersion": "1.25.10",
729
+ "node_versions": {
730
+ "comfy-core": "0.3.18",
731
+ "LanPaint": "0f509469ed2cd60c6032f739e282aad5dfc06166"
732
+ }
733
+ },
734
+ "version": 0.4
735
+ }
LanPaint/example_workflows/Z_image_Inpaint.jpg ADDED

Git LFS Details

  • SHA256: bbf29021eee787d5b6e81f094719206ed06db75335e992db94454b68b8330121
  • Pointer size: 132 Bytes
  • Size of remote file: 1.15 MB
LanPaint/example_workflows/Z_image_Inpaint.json ADDED
@@ -0,0 +1,1475 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "9ae6082b-c7f4-433c-9971-7a8f65a3ea65",
3
+ "revision": 0,
4
+ "last_node_id": 73,
5
+ "last_link_id": 95,
6
+ "nodes": [
7
+ {
8
+ "id": 39,
9
+ "type": "CLIPLoader",
10
+ "pos": [
11
+ 158.31605577680375,
12
+ 488.30506119064967
13
+ ],
14
+ "size": [
15
+ 323.734375,
16
+ 179.390625
17
+ ],
18
+ "flags": {},
19
+ "order": 0,
20
+ "mode": 0,
21
+ "inputs": [],
22
+ "outputs": [
23
+ {
24
+ "name": "CLIP",
25
+ "type": "CLIP",
26
+ "links": [
27
+ 44
28
+ ]
29
+ }
30
+ ],
31
+ "properties": {
32
+ "Node name for S&R": "CLIPLoader",
33
+ "cnr_id": "comfy-core",
34
+ "ver": "0.3.73",
35
+ "models": [
36
+ {
37
+ "name": "qwen_3_4b.safetensors",
38
+ "url": "https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/text_encoders/qwen_3_4b.safetensors",
39
+ "directory": "text_encoders"
40
+ }
41
+ ],
42
+ "enableTabs": false,
43
+ "tabWidth": 65,
44
+ "tabXOffset": 10,
45
+ "hasSecondTab": false,
46
+ "secondTabText": "Send Back",
47
+ "secondTabOffset": 80,
48
+ "secondTabWidth": 65
49
+ },
50
+ "widgets_values": [
51
+ "qwen_3_4b.safetensors",
52
+ "lumina2",
53
+ "default"
54
+ ]
55
+ },
56
+ {
57
+ "id": 40,
58
+ "type": "VAELoader",
59
+ "pos": [
60
+ 159.30157212272297,
61
+ 693.9279006020886
62
+ ],
63
+ "size": [
64
+ 323.734375,
65
+ 111.390625
66
+ ],
67
+ "flags": {},
68
+ "order": 1,
69
+ "mode": 0,
70
+ "inputs": [],
71
+ "outputs": [
72
+ {
73
+ "name": "VAE",
74
+ "type": "VAE",
75
+ "links": [
76
+ 39,
77
+ 70,
78
+ 86,
79
+ 87
80
+ ]
81
+ }
82
+ ],
83
+ "properties": {
84
+ "Node name for S&R": "VAELoader",
85
+ "cnr_id": "comfy-core",
86
+ "ver": "0.3.73",
87
+ "models": [
88
+ {
89
+ "name": "ae.safetensors",
90
+ "url": "https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/vae/ae.safetensors",
91
+ "directory": "vae"
92
+ }
93
+ ],
94
+ "enableTabs": false,
95
+ "tabWidth": 65,
96
+ "tabXOffset": 10,
97
+ "hasSecondTab": false,
98
+ "secondTabText": "Send Back",
99
+ "secondTabOffset": 80,
100
+ "secondTabWidth": 65
101
+ },
102
+ "widgets_values": [
103
+ "ae.safetensors"
104
+ ]
105
+ },
106
+ {
107
+ "id": 42,
108
+ "type": "ConditioningZeroOut",
109
+ "pos": [
110
+ 794.3164307166835,
111
+ 836.3052371197768
112
+ ],
113
+ "size": [
114
+ 236.984375,
115
+ 77.421875
116
+ ],
117
+ "flags": {},
118
+ "order": 11,
119
+ "mode": 0,
120
+ "inputs": [
121
+ {
122
+ "name": "conditioning",
123
+ "type": "CONDITIONING",
124
+ "link": 36
125
+ }
126
+ ],
127
+ "outputs": [
128
+ {
129
+ "name": "CONDITIONING",
130
+ "type": "CONDITIONING",
131
+ "links": [
132
+ 64
133
+ ]
134
+ }
135
+ ],
136
+ "properties": {
137
+ "Node name for S&R": "ConditioningZeroOut",
138
+ "cnr_id": "comfy-core",
139
+ "ver": "0.3.73",
140
+ "enableTabs": false,
141
+ "tabWidth": 65,
142
+ "tabXOffset": 10,
143
+ "hasSecondTab": false,
144
+ "secondTabText": "Send Back",
145
+ "secondTabOffset": 80,
146
+ "secondTabWidth": 65
147
+ },
148
+ "widgets_values": []
149
+ },
150
+ {
151
+ "id": 41,
152
+ "type": "EmptySD3LatentImage",
153
+ "pos": [
154
+ 158.31605577680375,
155
+ 848.3047505883683
156
+ ],
157
+ "size": [
158
+ 311.734375,
159
+ 179.390625
160
+ ],
161
+ "flags": {},
162
+ "order": 2,
163
+ "mode": 0,
164
+ "inputs": [],
165
+ "outputs": [
166
+ {
167
+ "name": "LATENT",
168
+ "type": "LATENT",
169
+ "slot_index": 0,
170
+ "links": []
171
+ }
172
+ ],
173
+ "properties": {
174
+ "Node name for S&R": "EmptySD3LatentImage",
175
+ "cnr_id": "comfy-core",
176
+ "ver": "0.3.64",
177
+ "enableTabs": false,
178
+ "tabWidth": 65,
179
+ "tabXOffset": 10,
180
+ "hasSecondTab": false,
181
+ "secondTabText": "Send Back",
182
+ "secondTabOffset": 80,
183
+ "secondTabWidth": 65
184
+ },
185
+ "widgets_values": [
186
+ 1024,
187
+ 1024,
188
+ 1
189
+ ]
190
+ },
191
+ {
192
+ "id": 47,
193
+ "type": "ModelSamplingAuraFlow",
194
+ "pos": [
195
+ 1106.844558468847,
196
+ 300.1767719883135
197
+ ],
198
+ "size": [
199
+ 371.875,
200
+ 111.390625
201
+ ],
202
+ "flags": {},
203
+ "order": 13,
204
+ "mode": 0,
205
+ "inputs": [
206
+ {
207
+ "name": "model",
208
+ "type": "MODEL",
209
+ "link": 60
210
+ }
211
+ ],
212
+ "outputs": [
213
+ {
214
+ "name": "MODEL",
215
+ "type": "MODEL",
216
+ "slot_index": 0,
217
+ "links": [
218
+ 62
219
+ ]
220
+ }
221
+ ],
222
+ "properties": {
223
+ "Node name for S&R": "ModelSamplingAuraFlow",
224
+ "cnr_id": "comfy-core",
225
+ "ver": "0.3.64",
226
+ "enableTabs": false,
227
+ "tabWidth": 65,
228
+ "tabXOffset": 10,
229
+ "hasSecondTab": false,
230
+ "secondTabText": "Send Back",
231
+ "secondTabOffset": 80,
232
+ "secondTabWidth": 65
233
+ },
234
+ "widgets_values": [
235
+ 3
236
+ ]
237
+ },
238
+ {
239
+ "id": 43,
240
+ "type": "VAEDecode",
241
+ "pos": [
242
+ 1490.0007839701339,
243
+ 169.99989031781615
244
+ ],
245
+ "size": [
246
+ 251.734375,
247
+ 101.421875
248
+ ],
249
+ "flags": {},
250
+ "order": 21,
251
+ "mode": 0,
252
+ "inputs": [
253
+ {
254
+ "name": "samples",
255
+ "type": "LATENT",
256
+ "link": 66
257
+ },
258
+ {
259
+ "name": "vae",
260
+ "type": "VAE",
261
+ "link": 39
262
+ }
263
+ ],
264
+ "outputs": [
265
+ {
266
+ "name": "IMAGE",
267
+ "type": "IMAGE",
268
+ "slot_index": 0,
269
+ "links": [
270
+ 73,
271
+ 93
272
+ ]
273
+ }
274
+ ],
275
+ "properties": {
276
+ "Node name for S&R": "VAEDecode",
277
+ "cnr_id": "comfy-core",
278
+ "ver": "0.3.64",
279
+ "enableTabs": false,
280
+ "tabWidth": 65,
281
+ "tabXOffset": 10,
282
+ "hasSecondTab": false,
283
+ "secondTabText": "Send Back",
284
+ "secondTabOffset": 80,
285
+ "secondTabWidth": 65
286
+ },
287
+ "widgets_values": []
288
+ },
289
+ {
290
+ "id": 45,
291
+ "type": "CLIPTextEncode",
292
+ "pos": [
293
+ 542.3159768994137,
294
+ 332.3053621604172
295
+ ],
296
+ "size": [
297
+ 491.734375,
298
+ 479.734375
299
+ ],
300
+ "flags": {},
301
+ "order": 7,
302
+ "mode": 0,
303
+ "inputs": [
304
+ {
305
+ "name": "clip",
306
+ "type": "CLIP",
307
+ "link": 44
308
+ }
309
+ ],
310
+ "outputs": [
311
+ {
312
+ "name": "CONDITIONING",
313
+ "type": "CONDITIONING",
314
+ "links": [
315
+ 36,
316
+ 63
317
+ ]
318
+ }
319
+ ],
320
+ "properties": {
321
+ "Node name for S&R": "CLIPTextEncode",
322
+ "cnr_id": "comfy-core",
323
+ "ver": "0.3.73",
324
+ "enableTabs": false,
325
+ "tabWidth": 65,
326
+ "tabXOffset": 10,
327
+ "hasSecondTab": false,
328
+ "secondTabText": "Send Back",
329
+ "secondTabOffset": 80,
330
+ "secondTabWidth": 65
331
+ },
332
+ "widgets_values": [
333
+ "Latina female with thick wavy hair, white shirt, harbor boats and pastel houses behind. Breezy seaside light, warm tones, cinematic close-up."
334
+ ],
335
+ "color": "#232",
336
+ "bgcolor": "#353"
337
+ },
338
+ {
339
+ "id": 48,
340
+ "type": "LoraLoaderModelOnly",
341
+ "pos": [
342
+ 553.9994917632011,
343
+ 133.99988695553816
344
+ ],
345
+ "size": [
346
+ 443.75,
347
+ 145.390625
348
+ ],
349
+ "flags": {},
350
+ "order": 10,
351
+ "mode": 4,
352
+ "inputs": [
353
+ {
354
+ "name": "model",
355
+ "type": "MODEL",
356
+ "link": 54
357
+ }
358
+ ],
359
+ "outputs": [
360
+ {
361
+ "name": "MODEL",
362
+ "type": "MODEL",
363
+ "links": [
364
+ 60
365
+ ]
366
+ }
367
+ ],
368
+ "properties": {
369
+ "Node name for S&R": "LoraLoaderModelOnly",
370
+ "cnr_id": "comfy-core",
371
+ "ver": "0.3.75",
372
+ "models": [
373
+ {
374
+ "name": "pixel_art_style_z_image_turbo.safetensors",
375
+ "url": "https://huggingface.co/tarn59/pixel_art_style_lora_z_image_turbo/resolve/main/pixel_art_style_z_image_turbo.safetensors",
376
+ "directory": "loras"
377
+ }
378
+ ],
379
+ "enableTabs": false,
380
+ "tabWidth": 65,
381
+ "tabXOffset": 10,
382
+ "hasSecondTab": false,
383
+ "secondTabText": "Send Back",
384
+ "secondTabOffset": 80,
385
+ "secondTabWidth": 65
386
+ },
387
+ "widgets_values": [
388
+ "pixel_art_style_z_image_turbo.safetensors",
389
+ 1
390
+ ]
391
+ },
392
+ {
393
+ "id": 35,
394
+ "type": "MarkdownNote",
395
+ "pos": [
396
+ -466.00011584916956,
397
+ 289.9999302108306
398
+ ],
399
+ "size": [
400
+ 587.734375,
401
+ 770.859375
402
+ ],
403
+ "flags": {
404
+ "collapsed": false
405
+ },
406
+ "order": 3,
407
+ "mode": 0,
408
+ "inputs": [],
409
+ "outputs": [],
410
+ "title": "Model link",
411
+ "properties": {},
412
+ "widgets_values": [
413
+ "## Report workflow issue\n\nIf you found any issues when running this workflow, [report template issue here](https://github.com/Comfy-Org/workflow_templates/issues)\n\n\n## Model links\n\n**text_encoders**\n\n- [qwen_3_4b.safetensors](https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/text_encoders/qwen_3_4b.safetensors)\n\n**loras**\n\n- [pixel_art_style_z_image_turbo.safetensors](https://huggingface.co/tarn59/pixel_art_style_lora_z_image_turbo/resolve/main/pixel_art_style_z_image_turbo.safetensors)\n\n**diffusion_models**\n\n- [z_image_turbo_bf16.safetensors](https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/diffusion_models/z_image_turbo_bf16.safetensors)\n\n**vae**\n\n- [ae.safetensors](https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/vae/ae.safetensors)\n\n\nModel Storage Location\n\n```\n📂 ComfyUI/\n├── 📂 models/\n│ ├── 📂 text_encoders/\n│ │ └── qwen_3_4b.safetensors\n│ ├── 📂 loras/\n│ │ └── pixel_art_style_z_image_turbo.safetensors\n│ ├── 📂 diffusion_models/\n│ │ └── z_image_turbo_bf16.safetensors\n│ └── 📂 vae/\n│ └── ae.safetensors\n```\n"
414
+ ],
415
+ "color": "#432",
416
+ "bgcolor": "#653"
417
+ },
418
+ {
419
+ "id": 56,
420
+ "type": "LanPaint_KSampler",
421
+ "pos": [
422
+ 1280.6434468860161,
423
+ 480.42471689895115
424
+ ],
425
+ "size": [
426
+ 479.765625,
427
+ 887.59375
428
+ ],
429
+ "flags": {},
430
+ "order": 20,
431
+ "mode": 0,
432
+ "inputs": [
433
+ {
434
+ "name": "model",
435
+ "type": "MODEL",
436
+ "link": 62
437
+ },
438
+ {
439
+ "name": "positive",
440
+ "type": "CONDITIONING",
441
+ "link": 63
442
+ },
443
+ {
444
+ "name": "negative",
445
+ "type": "CONDITIONING",
446
+ "link": 64
447
+ },
448
+ {
449
+ "name": "latent_image",
450
+ "type": "LATENT",
451
+ "link": 71
452
+ }
453
+ ],
454
+ "outputs": [
455
+ {
456
+ "name": "LATENT",
457
+ "type": "LATENT",
458
+ "links": [
459
+ 66
460
+ ]
461
+ }
462
+ ],
463
+ "properties": {
464
+ "Node name for S&R": "LanPaint_KSampler",
465
+ "cnr_id": "LanPaint",
466
+ "ver": "6109df6591a4cf2bc9d3b113d03f7297fa9248e9"
467
+ },
468
+ "widgets_values": [
469
+ 880311146947153,
470
+ "randomize",
471
+ 9,
472
+ 1,
473
+ "euler",
474
+ "simple",
475
+ 1,
476
+ 5,
477
+ "Image First",
478
+ "LanPaint KSampler. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!",
479
+ "🖼️ Image Inpainting"
480
+ ]
481
+ },
482
+ {
483
+ "id": 57,
484
+ "type": "LoadImage",
485
+ "pos": [
486
+ 9.292593918969033,
487
+ 1110.6054508670231
488
+ ],
489
+ "size": [
490
+ 328.65625,
491
+ 686.171875
492
+ ],
493
+ "flags": {},
494
+ "order": 4,
495
+ "mode": 0,
496
+ "inputs": [],
497
+ "outputs": [
498
+ {
499
+ "name": "IMAGE",
500
+ "type": "IMAGE",
501
+ "links": [
502
+ 85,
503
+ 88
504
+ ]
505
+ },
506
+ {
507
+ "name": "MASK",
508
+ "type": "MASK",
509
+ "links": [
510
+ 89
511
+ ]
512
+ }
513
+ ],
514
+ "properties": {
515
+ "Node name for S&R": "LoadImage",
516
+ "cnr_id": "comfy-core",
517
+ "ver": "0.3.59",
518
+ "ue_properties": {
519
+ "widget_ue_connectable": {},
520
+ "version": "7.1",
521
+ "input_ue_unconnectable": {}
522
+ },
523
+ "image": "clipspace/clipspace-painted-masked-1764827669471.png [input]"
524
+ },
525
+ "widgets_values": [
526
+ "clipspace/clipspace-painted-masked-1764827669471.png [input]",
527
+ "image"
528
+ ]
529
+ },
530
+ {
531
+ "id": 58,
532
+ "type": "VAEEncode",
533
+ "pos": [
534
+ 1701.3714934284335,
535
+ 1667.0261553802961
536
+ ],
537
+ "size": [
538
+ 225,
539
+ 101.421875
540
+ ],
541
+ "flags": {},
542
+ "order": 17,
543
+ "mode": 0,
544
+ "inputs": [
545
+ {
546
+ "name": "pixels",
547
+ "type": "IMAGE",
548
+ "link": 90
549
+ },
550
+ {
551
+ "name": "vae",
552
+ "type": "VAE",
553
+ "link": 70
554
+ }
555
+ ],
556
+ "outputs": [
557
+ {
558
+ "name": "LATENT",
559
+ "type": "LATENT",
560
+ "links": [
561
+ 67
562
+ ]
563
+ }
564
+ ],
565
+ "properties": {
566
+ "Node name for S&R": "VAEEncode",
567
+ "cnr_id": "comfy-core",
568
+ "ver": "0.3.59",
569
+ "ue_properties": {
570
+ "widget_ue_connectable": {},
571
+ "version": "7.1",
572
+ "input_ue_unconnectable": {}
573
+ }
574
+ },
575
+ "widgets_values": []
576
+ },
577
+ {
578
+ "id": 59,
579
+ "type": "SetLatentNoiseMask",
580
+ "pos": [
581
+ 2169.0494285384316,
582
+ 1637.2004308575815
583
+ ],
584
+ "size": [
585
+ 225,
586
+ 101.421875
587
+ ],
588
+ "flags": {},
589
+ "order": 19,
590
+ "mode": 0,
591
+ "inputs": [
592
+ {
593
+ "name": "samples",
594
+ "type": "LATENT",
595
+ "link": 67
596
+ },
597
+ {
598
+ "name": "mask",
599
+ "type": "MASK",
600
+ "link": 91
601
+ }
602
+ ],
603
+ "outputs": [
604
+ {
605
+ "name": "LATENT",
606
+ "type": "LATENT",
607
+ "links": [
608
+ 71
609
+ ]
610
+ }
611
+ ],
612
+ "properties": {
613
+ "Node name for S&R": "SetLatentNoiseMask",
614
+ "cnr_id": "comfy-core",
615
+ "ver": "0.3.59",
616
+ "ue_properties": {
617
+ "widget_ue_connectable": {},
618
+ "version": "7.1",
619
+ "input_ue_unconnectable": {}
620
+ }
621
+ },
622
+ "widgets_values": []
623
+ },
624
+ {
625
+ "id": 60,
626
+ "type": "LanPaint_MaskBlend",
627
+ "pos": [
628
+ 2744.756891034133,
629
+ 1245.7532005683747
630
+ ],
631
+ "size": [
632
+ 251.84375,
633
+ 159.40625
634
+ ],
635
+ "flags": {},
636
+ "order": 22,
637
+ "mode": 0,
638
+ "inputs": [
639
+ {
640
+ "name": "image1",
641
+ "type": "IMAGE",
642
+ "link": 94
643
+ },
644
+ {
645
+ "name": "image2",
646
+ "type": "IMAGE",
647
+ "link": 73
648
+ },
649
+ {
650
+ "name": "mask",
651
+ "type": "MASK",
652
+ "link": 95
653
+ }
654
+ ],
655
+ "outputs": [
656
+ {
657
+ "name": "IMAGE",
658
+ "type": "IMAGE",
659
+ "links": [
660
+ 72
661
+ ]
662
+ }
663
+ ],
664
+ "properties": {
665
+ "Node name for S&R": "LanPaint_MaskBlend",
666
+ "cnr_id": "LanPaint",
667
+ "ver": "4d3d5d17f0105b673df92da5b084cce567c9c712"
668
+ },
669
+ "widgets_values": [
670
+ 9
671
+ ]
672
+ },
673
+ {
674
+ "id": 61,
675
+ "type": "SaveImage",
676
+ "pos": [
677
+ 3313.9622863771715,
678
+ 1191.2159032348995
679
+ ],
680
+ "size": [
681
+ 1304.078125,
682
+ 1434.015625
683
+ ],
684
+ "flags": {},
685
+ "order": 24,
686
+ "mode": 0,
687
+ "inputs": [
688
+ {
689
+ "name": "images",
690
+ "type": "IMAGE",
691
+ "link": 72
692
+ }
693
+ ],
694
+ "outputs": [],
695
+ "properties": {
696
+ "cnr_id": "comfy-core",
697
+ "ver": "0.3.23"
698
+ },
699
+ "widgets_values": [
700
+ "ComfyUI"
701
+ ]
702
+ },
703
+ {
704
+ "id": 62,
705
+ "type": "VAEDecode",
706
+ "pos": [
707
+ 909.4390596825519,
708
+ 2032.1553145051257
709
+ ],
710
+ "size": [
711
+ 251.90625,
712
+ 101.421875
713
+ ],
714
+ "flags": {},
715
+ "order": 12,
716
+ "mode": 0,
717
+ "inputs": [
718
+ {
719
+ "name": "samples",
720
+ "type": "LATENT",
721
+ "link": 76
722
+ },
723
+ {
724
+ "name": "vae",
725
+ "type": "VAE",
726
+ "link": 87
727
+ }
728
+ ],
729
+ "outputs": [
730
+ {
731
+ "name": "IMAGE",
732
+ "type": "IMAGE",
733
+ "slot_index": 0,
734
+ "links": [
735
+ 84
736
+ ]
737
+ }
738
+ ],
739
+ "properties": {
740
+ "Node name for S&R": "VAEDecode",
741
+ "cnr_id": "comfy-core",
742
+ "ver": "0.3.23"
743
+ },
744
+ "widgets_values": []
745
+ },
746
+ {
747
+ "id": 64,
748
+ "type": "MaskToImage",
749
+ "pos": [
750
+ 1280.1054231177059,
751
+ 1881.6714778315163
752
+ ],
753
+ "size": [
754
+ 225,
755
+ 77.421875
756
+ ],
757
+ "flags": {},
758
+ "order": 9,
759
+ "mode": 0,
760
+ "inputs": [
761
+ {
762
+ "name": "mask",
763
+ "type": "MASK",
764
+ "link": 89
765
+ }
766
+ ],
767
+ "outputs": [
768
+ {
769
+ "name": "IMAGE",
770
+ "type": "IMAGE",
771
+ "links": [
772
+ 81
773
+ ]
774
+ }
775
+ ],
776
+ "properties": {
777
+ "Node name for S&R": "MaskToImage",
778
+ "cnr_id": "comfy-core",
779
+ "ver": "0.3.51"
780
+ },
781
+ "widgets_values": []
782
+ },
783
+ {
784
+ "id": 67,
785
+ "type": "VAEEncode",
786
+ "pos": [
787
+ 927.11123002246,
788
+ 1921.0804280162624
789
+ ],
790
+ "size": [
791
+ 225,
792
+ 101.421875
793
+ ],
794
+ "flags": {},
795
+ "order": 8,
796
+ "mode": 0,
797
+ "inputs": [
798
+ {
799
+ "name": "pixels",
800
+ "type": "IMAGE",
801
+ "link": 85
802
+ },
803
+ {
804
+ "name": "vae",
805
+ "type": "VAE",
806
+ "link": 86
807
+ }
808
+ ],
809
+ "outputs": [
810
+ {
811
+ "name": "LATENT",
812
+ "type": "LATENT",
813
+ "links": [
814
+ 76
815
+ ]
816
+ }
817
+ ],
818
+ "properties": {
819
+ "Node name for S&R": "VAEEncode",
820
+ "cnr_id": "comfy-core",
821
+ "ver": "0.3.50",
822
+ "enableTabs": false,
823
+ "tabWidth": 65,
824
+ "tabXOffset": 10,
825
+ "hasSecondTab": false,
826
+ "secondTabText": "Send Back",
827
+ "secondTabOffset": 80,
828
+ "secondTabWidth": 65,
829
+ "ue_properties": {
830
+ "widget_ue_connectable": {}
831
+ }
832
+ },
833
+ "widgets_values": []
834
+ },
835
+ {
836
+ "id": 68,
837
+ "type": "ImageScale",
838
+ "pos": [
839
+ 1272.9968314098537,
840
+ 1988.7684995304935
841
+ ],
842
+ "size": [
843
+ 323.90625,
844
+ 213.375
845
+ ],
846
+ "flags": {},
847
+ "order": 16,
848
+ "mode": 0,
849
+ "inputs": [
850
+ {
851
+ "name": "image",
852
+ "type": "IMAGE",
853
+ "link": 81
854
+ },
855
+ {
856
+ "name": "width",
857
+ "type": "INT",
858
+ "widget": {
859
+ "name": "width"
860
+ },
861
+ "link": 82
862
+ },
863
+ {
864
+ "name": "height",
865
+ "type": "INT",
866
+ "widget": {
867
+ "name": "height"
868
+ },
869
+ "link": 83
870
+ }
871
+ ],
872
+ "outputs": [
873
+ {
874
+ "name": "IMAGE",
875
+ "type": "IMAGE",
876
+ "links": [
877
+ 79
878
+ ]
879
+ }
880
+ ],
881
+ "properties": {
882
+ "Node name for S&R": "ImageScale",
883
+ "cnr_id": "comfy-core",
884
+ "ver": "0.3.52"
885
+ },
886
+ "widgets_values": [
887
+ "nearest-exact",
888
+ 512,
889
+ 512,
890
+ "center"
891
+ ]
892
+ },
893
+ {
894
+ "id": 69,
895
+ "type": "GetImageSize",
896
+ "pos": [
897
+ 924.0300715130902,
898
+ 2151.376631256835
899
+ ],
900
+ "size": [
901
+ 225,
902
+ 190.171875
903
+ ],
904
+ "flags": {},
905
+ "order": 14,
906
+ "mode": 0,
907
+ "inputs": [
908
+ {
909
+ "name": "image",
910
+ "type": "IMAGE",
911
+ "link": 84
912
+ }
913
+ ],
914
+ "outputs": [
915
+ {
916
+ "name": "width",
917
+ "type": "INT",
918
+ "links": [
919
+ 77,
920
+ 82
921
+ ]
922
+ },
923
+ {
924
+ "name": "height",
925
+ "type": "INT",
926
+ "links": [
927
+ 78,
928
+ 83
929
+ ]
930
+ },
931
+ {
932
+ "name": "batch_size",
933
+ "type": "INT",
934
+ "links": null
935
+ }
936
+ ],
937
+ "properties": {
938
+ "Node name for S&R": "GetImageSize",
939
+ "cnr_id": "comfy-core",
940
+ "ver": "0.3.52"
941
+ },
942
+ "widgets_values": [
943
+ "width: 1024, height: 1024\n batch size: 1"
944
+ ]
945
+ },
946
+ {
947
+ "id": 73,
948
+ "type": "PreviewImage",
949
+ "pos": [
950
+ 2226.506787053337,
951
+ 107.57278250350078
952
+ ],
953
+ "size": [
954
+ 225,
955
+ 246
956
+ ],
957
+ "flags": {},
958
+ "order": 23,
959
+ "mode": 0,
960
+ "inputs": [
961
+ {
962
+ "name": "images",
963
+ "type": "IMAGE",
964
+ "link": 93
965
+ }
966
+ ],
967
+ "outputs": [],
968
+ "properties": {
969
+ "Node name for S&R": "PreviewImage",
970
+ "cnr_id": "comfy-core",
971
+ "ver": "0.3.76"
972
+ },
973
+ "widgets_values": []
974
+ },
975
+ {
976
+ "id": 63,
977
+ "type": "ImageScale",
978
+ "pos": [
979
+ 1283.837511214967,
980
+ 1657.4367336671903
981
+ ],
982
+ "size": [
983
+ 323.90625,
984
+ 213.375
985
+ ],
986
+ "flags": {},
987
+ "order": 15,
988
+ "mode": 0,
989
+ "inputs": [
990
+ {
991
+ "name": "image",
992
+ "type": "IMAGE",
993
+ "link": 88
994
+ },
995
+ {
996
+ "name": "width",
997
+ "type": "INT",
998
+ "widget": {
999
+ "name": "width"
1000
+ },
1001
+ "link": 77
1002
+ },
1003
+ {
1004
+ "name": "height",
1005
+ "type": "INT",
1006
+ "widget": {
1007
+ "name": "height"
1008
+ },
1009
+ "link": 78
1010
+ }
1011
+ ],
1012
+ "outputs": [
1013
+ {
1014
+ "name": "IMAGE",
1015
+ "type": "IMAGE",
1016
+ "links": [
1017
+ 90,
1018
+ 94
1019
+ ]
1020
+ }
1021
+ ],
1022
+ "properties": {
1023
+ "Node name for S&R": "ImageScale",
1024
+ "cnr_id": "comfy-core",
1025
+ "ver": "0.3.52"
1026
+ },
1027
+ "widgets_values": [
1028
+ "area",
1029
+ 512,
1030
+ 512,
1031
+ "center"
1032
+ ]
1033
+ },
1034
+ {
1035
+ "id": 65,
1036
+ "type": "ImageToMask",
1037
+ "pos": [
1038
+ 1274.556170930292,
1039
+ 2196.94755423526
1040
+ ],
1041
+ "size": [
1042
+ 323.90625,
1043
+ 111.390625
1044
+ ],
1045
+ "flags": {},
1046
+ "order": 18,
1047
+ "mode": 0,
1048
+ "inputs": [
1049
+ {
1050
+ "name": "image",
1051
+ "type": "IMAGE",
1052
+ "link": 79
1053
+ }
1054
+ ],
1055
+ "outputs": [
1056
+ {
1057
+ "name": "MASK",
1058
+ "type": "MASK",
1059
+ "links": [
1060
+ 91,
1061
+ 95
1062
+ ]
1063
+ }
1064
+ ],
1065
+ "properties": {
1066
+ "Node name for S&R": "ImageToMask",
1067
+ "cnr_id": "comfy-core",
1068
+ "ver": "0.3.51"
1069
+ },
1070
+ "widgets_values": [
1071
+ "red"
1072
+ ]
1073
+ },
1074
+ {
1075
+ "id": 46,
1076
+ "type": "UNETLoader",
1077
+ "pos": [
1078
+ 159.05646022112083,
1079
+ 288.62105108441466
1080
+ ],
1081
+ "size": [
1082
+ 323.734375,
1083
+ 145.390625
1084
+ ],
1085
+ "flags": {},
1086
+ "order": 5,
1087
+ "mode": 0,
1088
+ "inputs": [],
1089
+ "outputs": [
1090
+ {
1091
+ "name": "MODEL",
1092
+ "type": "MODEL",
1093
+ "links": [
1094
+ 54
1095
+ ]
1096
+ }
1097
+ ],
1098
+ "properties": {
1099
+ "Node name for S&R": "UNETLoader",
1100
+ "cnr_id": "comfy-core",
1101
+ "ver": "0.3.73",
1102
+ "models": [
1103
+ {
1104
+ "name": "z_image_turbo_bf16.safetensors",
1105
+ "url": "https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/diffusion_models/z_image_turbo_bf16.safetensors",
1106
+ "directory": "diffusion_models"
1107
+ }
1108
+ ],
1109
+ "enableTabs": false,
1110
+ "tabWidth": 65,
1111
+ "tabXOffset": 10,
1112
+ "hasSecondTab": false,
1113
+ "secondTabText": "Send Back",
1114
+ "secondTabOffset": 80,
1115
+ "secondTabWidth": 65
1116
+ },
1117
+ "widgets_values": [
1118
+ "z_image_turbo_bf16.safetensors",
1119
+ "default"
1120
+ ]
1121
+ },
1122
+ {
1123
+ "id": 72,
1124
+ "type": "Note",
1125
+ "pos": [
1126
+ 1288.7909707861209,
1127
+ 1503.5796522859714
1128
+ ],
1129
+ "size": [
1130
+ 225,
1131
+ 109.765625
1132
+ ],
1133
+ "flags": {},
1134
+ "order": 6,
1135
+ "mode": 0,
1136
+ "inputs": [],
1137
+ "outputs": [],
1138
+ "properties": {},
1139
+ "widgets_values": [
1140
+ "Reshape image to suit VAE "
1141
+ ],
1142
+ "color": "#432",
1143
+ "bgcolor": "#653"
1144
+ }
1145
+ ],
1146
+ "links": [
1147
+ [
1148
+ 36,
1149
+ 45,
1150
+ 0,
1151
+ 42,
1152
+ 0,
1153
+ "CONDITIONING"
1154
+ ],
1155
+ [
1156
+ 39,
1157
+ 40,
1158
+ 0,
1159
+ 43,
1160
+ 1,
1161
+ "VAE"
1162
+ ],
1163
+ [
1164
+ 44,
1165
+ 39,
1166
+ 0,
1167
+ 45,
1168
+ 0,
1169
+ "CLIP"
1170
+ ],
1171
+ [
1172
+ 54,
1173
+ 46,
1174
+ 0,
1175
+ 48,
1176
+ 0,
1177
+ "MODEL"
1178
+ ],
1179
+ [
1180
+ 60,
1181
+ 48,
1182
+ 0,
1183
+ 47,
1184
+ 0,
1185
+ "MODEL"
1186
+ ],
1187
+ [
1188
+ 62,
1189
+ 47,
1190
+ 0,
1191
+ 56,
1192
+ 0,
1193
+ "MODEL"
1194
+ ],
1195
+ [
1196
+ 63,
1197
+ 45,
1198
+ 0,
1199
+ 56,
1200
+ 1,
1201
+ "CONDITIONING"
1202
+ ],
1203
+ [
1204
+ 64,
1205
+ 42,
1206
+ 0,
1207
+ 56,
1208
+ 2,
1209
+ "CONDITIONING"
1210
+ ],
1211
+ [
1212
+ 66,
1213
+ 56,
1214
+ 0,
1215
+ 43,
1216
+ 0,
1217
+ "LATENT"
1218
+ ],
1219
+ [
1220
+ 67,
1221
+ 58,
1222
+ 0,
1223
+ 59,
1224
+ 0,
1225
+ "LATENT"
1226
+ ],
1227
+ [
1228
+ 70,
1229
+ 40,
1230
+ 0,
1231
+ 58,
1232
+ 1,
1233
+ "VAE"
1234
+ ],
1235
+ [
1236
+ 71,
1237
+ 59,
1238
+ 0,
1239
+ 56,
1240
+ 3,
1241
+ "LATENT"
1242
+ ],
1243
+ [
1244
+ 72,
1245
+ 60,
1246
+ 0,
1247
+ 61,
1248
+ 0,
1249
+ "IMAGE"
1250
+ ],
1251
+ [
1252
+ 73,
1253
+ 43,
1254
+ 0,
1255
+ 60,
1256
+ 1,
1257
+ "IMAGE"
1258
+ ],
1259
+ [
1260
+ 76,
1261
+ 67,
1262
+ 0,
1263
+ 62,
1264
+ 0,
1265
+ "LATENT"
1266
+ ],
1267
+ [
1268
+ 77,
1269
+ 69,
1270
+ 0,
1271
+ 63,
1272
+ 1,
1273
+ "INT"
1274
+ ],
1275
+ [
1276
+ 78,
1277
+ 69,
1278
+ 1,
1279
+ 63,
1280
+ 2,
1281
+ "INT"
1282
+ ],
1283
+ [
1284
+ 79,
1285
+ 68,
1286
+ 0,
1287
+ 65,
1288
+ 0,
1289
+ "IMAGE"
1290
+ ],
1291
+ [
1292
+ 81,
1293
+ 64,
1294
+ 0,
1295
+ 68,
1296
+ 0,
1297
+ "IMAGE"
1298
+ ],
1299
+ [
1300
+ 82,
1301
+ 69,
1302
+ 0,
1303
+ 68,
1304
+ 1,
1305
+ "INT"
1306
+ ],
1307
+ [
1308
+ 83,
1309
+ 69,
1310
+ 1,
1311
+ 68,
1312
+ 2,
1313
+ "INT"
1314
+ ],
1315
+ [
1316
+ 84,
1317
+ 62,
1318
+ 0,
1319
+ 69,
1320
+ 0,
1321
+ "IMAGE"
1322
+ ],
1323
+ [
1324
+ 85,
1325
+ 57,
1326
+ 0,
1327
+ 67,
1328
+ 0,
1329
+ "IMAGE"
1330
+ ],
1331
+ [
1332
+ 86,
1333
+ 40,
1334
+ 0,
1335
+ 67,
1336
+ 1,
1337
+ "VAE"
1338
+ ],
1339
+ [
1340
+ 87,
1341
+ 40,
1342
+ 0,
1343
+ 62,
1344
+ 1,
1345
+ "VAE"
1346
+ ],
1347
+ [
1348
+ 88,
1349
+ 57,
1350
+ 0,
1351
+ 63,
1352
+ 0,
1353
+ "IMAGE"
1354
+ ],
1355
+ [
1356
+ 89,
1357
+ 57,
1358
+ 1,
1359
+ 64,
1360
+ 0,
1361
+ "MASK"
1362
+ ],
1363
+ [
1364
+ 90,
1365
+ 63,
1366
+ 0,
1367
+ 58,
1368
+ 0,
1369
+ "IMAGE"
1370
+ ],
1371
+ [
1372
+ 91,
1373
+ 65,
1374
+ 0,
1375
+ 59,
1376
+ 1,
1377
+ "MASK"
1378
+ ],
1379
+ [
1380
+ 93,
1381
+ 43,
1382
+ 0,
1383
+ 73,
1384
+ 0,
1385
+ "IMAGE"
1386
+ ],
1387
+ [
1388
+ 94,
1389
+ 63,
1390
+ 0,
1391
+ 60,
1392
+ 0,
1393
+ "IMAGE"
1394
+ ],
1395
+ [
1396
+ 95,
1397
+ 65,
1398
+ 0,
1399
+ 60,
1400
+ 2,
1401
+ "MASK"
1402
+ ]
1403
+ ],
1404
+ "groups": [
1405
+ {
1406
+ "id": 2,
1407
+ "title": "Step2 - Image size",
1408
+ "bounding": [
1409
+ 146,
1410
+ 770,
1411
+ 348,
1412
+ 240
1413
+ ],
1414
+ "color": "#3f789e",
1415
+ "font_size": 24,
1416
+ "flags": {}
1417
+ },
1418
+ {
1419
+ "id": 3,
1420
+ "title": "Step3 - Prompt",
1421
+ "bounding": [
1422
+ 518,
1423
+ 254,
1424
+ 540,
1425
+ 648
1426
+ ],
1427
+ "color": "#3f789e",
1428
+ "font_size": 24,
1429
+ "flags": {}
1430
+ },
1431
+ {
1432
+ "id": 4,
1433
+ "title": "Step1 - Load models",
1434
+ "bounding": [
1435
+ 146,
1436
+ 254,
1437
+ 348,
1438
+ 496.32
1439
+ ],
1440
+ "color": "#3f789e",
1441
+ "font_size": 24,
1442
+ "flags": {}
1443
+ },
1444
+ {
1445
+ "id": 5,
1446
+ "title": "Ctrl-B to enable LoRA input",
1447
+ "bounding": [
1448
+ 518,
1449
+ 50,
1450
+ 528,
1451
+ 192
1452
+ ],
1453
+ "color": "#3f789e",
1454
+ "font_size": 24,
1455
+ "flags": {}
1456
+ }
1457
+ ],
1458
+ "config": {},
1459
+ "extra": {
1460
+ "ds": {
1461
+ "scale": 0.3800835362432756,
1462
+ "offset": [
1463
+ -902.897494105397,
1464
+ -396.4805064253962
1465
+ ]
1466
+ },
1467
+ "frontendVersion": "1.33.14",
1468
+ "VHS_latentpreview": false,
1469
+ "VHS_latentpreviewrate": 0,
1470
+ "VHS_MetadataImage": true,
1471
+ "VHS_KeepIntermediate": true,
1472
+ "workflowRendererVersion": "Vue"
1473
+ },
1474
+ "version": 0.4
1475
+ }
LanPaint/example_workflows/Z_image_base_Inpaint.jpg ADDED

Git LFS Details

  • SHA256: a0a7c8946f52c092a10320542d316285f3fbe6c469be0084d636f94c7aad5383
  • Pointer size: 132 Bytes
  • Size of remote file: 1.2 MB
LanPaint/example_workflows/Z_image_base_Inpaint.json ADDED
@@ -0,0 +1,1548 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "9ae6082b-c7f4-433c-9971-7a8f65a3ea65",
3
+ "revision": 0,
4
+ "last_node_id": 79,
5
+ "last_link_id": 106,
6
+ "nodes": [
7
+ {
8
+ "id": 40,
9
+ "type": "VAELoader",
10
+ "pos": [
11
+ 131.0846434356025,
12
+ 576.6065838350738
13
+ ],
14
+ "size": [
15
+ 269.77864583333337,
16
+ 67.82552083333334
17
+ ],
18
+ "flags": {},
19
+ "order": 0,
20
+ "mode": 0,
21
+ "inputs": [],
22
+ "outputs": [
23
+ {
24
+ "name": "VAE",
25
+ "type": "VAE",
26
+ "links": [
27
+ 39,
28
+ 70,
29
+ 86,
30
+ 87
31
+ ]
32
+ }
33
+ ],
34
+ "properties": {
35
+ "Node name for S&R": "VAELoader",
36
+ "cnr_id": "comfy-core",
37
+ "ver": "0.3.73",
38
+ "models": [
39
+ {
40
+ "name": "ae.safetensors",
41
+ "url": "https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/vae/ae.safetensors",
42
+ "directory": "vae"
43
+ }
44
+ ],
45
+ "enableTabs": false,
46
+ "tabWidth": 65,
47
+ "tabXOffset": 10,
48
+ "hasSecondTab": false,
49
+ "secondTabText": "Send Back",
50
+ "secondTabOffset": 80,
51
+ "secondTabWidth": 65
52
+ },
53
+ "widgets_values": [
54
+ "ae.safetensors"
55
+ ]
56
+ },
57
+ {
58
+ "id": 41,
59
+ "type": "EmptySD3LatentImage",
60
+ "pos": [
61
+ 130.26337981400314,
62
+ 705.2539588236402
63
+ ],
64
+ "size": [
65
+ 259.77864583333337,
66
+ 124.4921875
67
+ ],
68
+ "flags": {},
69
+ "order": 1,
70
+ "mode": 0,
71
+ "inputs": [],
72
+ "outputs": [
73
+ {
74
+ "name": "LATENT",
75
+ "type": "LATENT",
76
+ "slot_index": 0,
77
+ "links": []
78
+ }
79
+ ],
80
+ "properties": {
81
+ "Node name for S&R": "EmptySD3LatentImage",
82
+ "cnr_id": "comfy-core",
83
+ "ver": "0.3.64",
84
+ "enableTabs": false,
85
+ "tabWidth": 65,
86
+ "tabXOffset": 10,
87
+ "hasSecondTab": false,
88
+ "secondTabText": "Send Back",
89
+ "secondTabOffset": 80,
90
+ "secondTabWidth": 65
91
+ },
92
+ "widgets_values": [
93
+ 1024,
94
+ 1024,
95
+ 1
96
+ ]
97
+ },
98
+ {
99
+ "id": 43,
100
+ "type": "VAEDecode",
101
+ "pos": [
102
+ 1240.000653308445,
103
+ 139.99990859818013
104
+ ],
105
+ "size": [
106
+ 209.77864583333334,
107
+ 59.51822916666667
108
+ ],
109
+ "flags": {},
110
+ "order": 22,
111
+ "mode": 0,
112
+ "inputs": [
113
+ {
114
+ "name": "samples",
115
+ "type": "LATENT",
116
+ "link": 104
117
+ },
118
+ {
119
+ "name": "vae",
120
+ "type": "VAE",
121
+ "link": 39
122
+ }
123
+ ],
124
+ "outputs": [
125
+ {
126
+ "name": "IMAGE",
127
+ "type": "IMAGE",
128
+ "slot_index": 0,
129
+ "links": [
130
+ 73,
131
+ 93
132
+ ]
133
+ }
134
+ ],
135
+ "properties": {
136
+ "Node name for S&R": "VAEDecode",
137
+ "cnr_id": "comfy-core",
138
+ "ver": "0.3.64",
139
+ "enableTabs": false,
140
+ "tabWidth": 65,
141
+ "tabXOffset": 10,
142
+ "hasSecondTab": false,
143
+ "secondTabText": "Send Back",
144
+ "secondTabOffset": 80,
145
+ "secondTabWidth": 65
146
+ },
147
+ "widgets_values": []
148
+ },
149
+ {
150
+ "id": 48,
151
+ "type": "LoraLoaderModelOnly",
152
+ "pos": [
153
+ 459.99957646933433,
154
+ 109.99990579628181
155
+ ],
156
+ "size": [
157
+ 369.7916666666667,
158
+ 96.15885416666667
159
+ ],
160
+ "flags": {},
161
+ "order": 8,
162
+ "mode": 4,
163
+ "inputs": [
164
+ {
165
+ "name": "model",
166
+ "type": "MODEL",
167
+ "link": 54
168
+ }
169
+ ],
170
+ "outputs": [
171
+ {
172
+ "name": "MODEL",
173
+ "type": "MODEL",
174
+ "links": [
175
+ 60
176
+ ]
177
+ }
178
+ ],
179
+ "properties": {
180
+ "Node name for S&R": "LoraLoaderModelOnly",
181
+ "cnr_id": "comfy-core",
182
+ "ver": "0.3.75",
183
+ "models": [
184
+ {
185
+ "name": "pixel_art_style_z_image_turbo.safetensors",
186
+ "url": "https://huggingface.co/tarn59/pixel_art_style_lora_z_image_turbo/resolve/main/pixel_art_style_z_image_turbo.safetensors",
187
+ "directory": "loras"
188
+ }
189
+ ],
190
+ "enableTabs": false,
191
+ "tabWidth": 65,
192
+ "tabXOffset": 10,
193
+ "hasSecondTab": false,
194
+ "secondTabText": "Send Back",
195
+ "secondTabOffset": 80,
196
+ "secondTabWidth": 65
197
+ },
198
+ "widgets_values": [
199
+ "pixel_art_style_z_image_turbo.safetensors",
200
+ 1
201
+ ]
202
+ },
203
+ {
204
+ "id": 35,
205
+ "type": "MarkdownNote",
206
+ "pos": [
207
+ -390.00009654097465,
208
+ 239.99994184235885
209
+ ],
210
+ "size": [
211
+ 489.77864583333337,
212
+ 617.3828125
213
+ ],
214
+ "flags": {
215
+ "collapsed": false
216
+ },
217
+ "order": 2,
218
+ "mode": 0,
219
+ "inputs": [],
220
+ "outputs": [],
221
+ "title": "Model link",
222
+ "properties": {},
223
+ "widgets_values": [
224
+ "## Report workflow issue\n\nIf you found any issues when running this workflow, [report template issue here](https://github.com/Comfy-Org/workflow_templates/issues)\n\n\n## Model links\n\n**text_encoders**\n\n- [qwen_3_4b.safetensors](https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/text_encoders/qwen_3_4b.safetensors)\n\n**loras**\n\n- [pixel_art_style_z_image_turbo.safetensors](https://huggingface.co/tarn59/pixel_art_style_lora_z_image_turbo/resolve/main/pixel_art_style_z_image_turbo.safetensors)\n\n**diffusion_models**\n\n- [z_image_turbo_bf16.safetensors](https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/diffusion_models/z_image_turbo_bf16.safetensors)\n\n**vae**\n\n- [ae.safetensors](https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/vae/ae.safetensors)\n\n\nModel Storage Location\n\n```\n📂 ComfyUI/\n├── 📂 models/\n│ ├── 📂 text_encoders/\n│ │ └── qwen_3_4b.safetensors\n│ ├── 📂 loras/\n│ │ └── pixel_art_style_z_image_turbo.safetensors\n│ ├── 📂 diffusion_models/\n│ │ └── z_image_turbo_bf16.safetensors\n│ └── 📂 vae/\n│ └── ae.safetensors\n```\n"
225
+ ],
226
+ "color": "#432",
227
+ "bgcolor": "#653"
228
+ },
229
+ {
230
+ "id": 58,
231
+ "type": "VAEEncode",
232
+ "pos": [
233
+ 1416.1429111903612,
234
+ 1387.521796150247
235
+ ],
236
+ "size": [
237
+ 187.5,
238
+ 59.51822916666667
239
+ ],
240
+ "flags": {},
241
+ "order": 18,
242
+ "mode": 0,
243
+ "inputs": [
244
+ {
245
+ "name": "pixels",
246
+ "type": "IMAGE",
247
+ "link": 90
248
+ },
249
+ {
250
+ "name": "vae",
251
+ "type": "VAE",
252
+ "link": 70
253
+ }
254
+ ],
255
+ "outputs": [
256
+ {
257
+ "name": "LATENT",
258
+ "type": "LATENT",
259
+ "links": [
260
+ 67
261
+ ]
262
+ }
263
+ ],
264
+ "properties": {
265
+ "Node name for S&R": "VAEEncode",
266
+ "cnr_id": "comfy-core",
267
+ "ver": "0.3.59",
268
+ "ue_properties": {
269
+ "widget_ue_connectable": {},
270
+ "version": "7.1",
271
+ "input_ue_unconnectable": {}
272
+ }
273
+ },
274
+ "widgets_values": []
275
+ },
276
+ {
277
+ "id": 59,
278
+ "type": "SetLatentNoiseMask",
279
+ "pos": [
280
+ 1805.8745237820265,
281
+ 1362.6670257146513
282
+ ],
283
+ "size": [
284
+ 187.5,
285
+ 59.51822916666667
286
+ ],
287
+ "flags": {},
288
+ "order": 20,
289
+ "mode": 0,
290
+ "inputs": [
291
+ {
292
+ "name": "samples",
293
+ "type": "LATENT",
294
+ "link": 67
295
+ },
296
+ {
297
+ "name": "mask",
298
+ "type": "MASK",
299
+ "link": 91
300
+ }
301
+ ],
302
+ "outputs": [
303
+ {
304
+ "name": "LATENT",
305
+ "type": "LATENT",
306
+ "links": [
307
+ 103
308
+ ]
309
+ }
310
+ ],
311
+ "properties": {
312
+ "Node name for S&R": "SetLatentNoiseMask",
313
+ "cnr_id": "comfy-core",
314
+ "ver": "0.3.59",
315
+ "ue_properties": {
316
+ "widget_ue_connectable": {},
317
+ "version": "7.1",
318
+ "input_ue_unconnectable": {}
319
+ }
320
+ },
321
+ "widgets_values": []
322
+ },
323
+ {
324
+ "id": 60,
325
+ "type": "LanPaint_MaskBlend",
326
+ "pos": [
327
+ 2285.630742528444,
328
+ 1036.4610004736458
329
+ ],
330
+ "size": [
331
+ 210,
332
+ 107.83854166666667
333
+ ],
334
+ "flags": {},
335
+ "order": 23,
336
+ "mode": 0,
337
+ "inputs": [
338
+ {
339
+ "name": "image1",
340
+ "type": "IMAGE",
341
+ "link": 94
342
+ },
343
+ {
344
+ "name": "image2",
345
+ "type": "IMAGE",
346
+ "link": 73
347
+ },
348
+ {
349
+ "name": "mask",
350
+ "type": "MASK",
351
+ "link": 95
352
+ }
353
+ ],
354
+ "outputs": [
355
+ {
356
+ "name": "IMAGE",
357
+ "type": "IMAGE",
358
+ "links": [
359
+ 72
360
+ ]
361
+ }
362
+ ],
363
+ "properties": {
364
+ "Node name for S&R": "LanPaint_MaskBlend",
365
+ "cnr_id": "LanPaint",
366
+ "ver": "4d3d5d17f0105b673df92da5b084cce567c9c712"
367
+ },
368
+ "widgets_values": [
369
+ 9
370
+ ]
371
+ },
372
+ {
373
+ "id": 61,
374
+ "type": "SaveImage",
375
+ "pos": [
376
+ 2759.9685719809763,
377
+ 991.0132526957497
378
+ ],
379
+ "size": [
380
+ 1086.7317708333335,
381
+ 1170.0130208333335
382
+ ],
383
+ "flags": {},
384
+ "order": 25,
385
+ "mode": 0,
386
+ "inputs": [
387
+ {
388
+ "name": "images",
389
+ "type": "IMAGE",
390
+ "link": 72
391
+ }
392
+ ],
393
+ "outputs": [],
394
+ "properties": {
395
+ "cnr_id": "comfy-core",
396
+ "ver": "0.3.23"
397
+ },
398
+ "widgets_values": [
399
+ "ComfyUI"
400
+ ]
401
+ },
402
+ {
403
+ "id": 62,
404
+ "type": "VAEDecode",
405
+ "pos": [
406
+ 756.1992164021267,
407
+ 1691.7960954209382
408
+ ],
409
+ "size": [
410
+ 209.921875,
411
+ 59.51822916666667
412
+ ],
413
+ "flags": {},
414
+ "order": 14,
415
+ "mode": 0,
416
+ "inputs": [
417
+ {
418
+ "name": "samples",
419
+ "type": "LATENT",
420
+ "link": 76
421
+ },
422
+ {
423
+ "name": "vae",
424
+ "type": "VAE",
425
+ "link": 87
426
+ }
427
+ ],
428
+ "outputs": [
429
+ {
430
+ "name": "IMAGE",
431
+ "type": "IMAGE",
432
+ "slot_index": 0,
433
+ "links": [
434
+ 84
435
+ ]
436
+ }
437
+ ],
438
+ "properties": {
439
+ "Node name for S&R": "VAEDecode",
440
+ "cnr_id": "comfy-core",
441
+ "ver": "0.3.23"
442
+ },
443
+ "widgets_values": []
444
+ },
445
+ {
446
+ "id": 64,
447
+ "type": "MaskToImage",
448
+ "pos": [
449
+ 1065.0878525980884,
450
+ 1566.3928981929303
451
+ ],
452
+ "size": [
453
+ 187.5,
454
+ 39.51822916666667
455
+ ],
456
+ "flags": {},
457
+ "order": 10,
458
+ "mode": 0,
459
+ "inputs": [
460
+ {
461
+ "name": "mask",
462
+ "type": "MASK",
463
+ "link": 89
464
+ }
465
+ ],
466
+ "outputs": [
467
+ {
468
+ "name": "IMAGE",
469
+ "type": "IMAGE",
470
+ "links": [
471
+ 81
472
+ ]
473
+ }
474
+ ],
475
+ "properties": {
476
+ "Node name for S&R": "MaskToImage",
477
+ "cnr_id": "comfy-core",
478
+ "ver": "0.3.51"
479
+ },
480
+ "widgets_values": []
481
+ },
482
+ {
483
+ "id": 67,
484
+ "type": "VAEEncode",
485
+ "pos": [
486
+ 770.9260250187167,
487
+ 1599.2336900135522
488
+ ],
489
+ "size": [
490
+ 187.5,
491
+ 59.51822916666667
492
+ ],
493
+ "flags": {},
494
+ "order": 9,
495
+ "mode": 0,
496
+ "inputs": [
497
+ {
498
+ "name": "pixels",
499
+ "type": "IMAGE",
500
+ "link": 85
501
+ },
502
+ {
503
+ "name": "vae",
504
+ "type": "VAE",
505
+ "link": 86
506
+ }
507
+ ],
508
+ "outputs": [
509
+ {
510
+ "name": "LATENT",
511
+ "type": "LATENT",
512
+ "links": [
513
+ 76
514
+ ]
515
+ }
516
+ ],
517
+ "properties": {
518
+ "Node name for S&R": "VAEEncode",
519
+ "cnr_id": "comfy-core",
520
+ "ver": "0.3.50",
521
+ "enableTabs": false,
522
+ "tabWidth": 65,
523
+ "tabXOffset": 10,
524
+ "hasSecondTab": false,
525
+ "secondTabText": "Send Back",
526
+ "secondTabOffset": 80,
527
+ "secondTabWidth": 65,
528
+ "ue_properties": {
529
+ "widget_ue_connectable": {}
530
+ }
531
+ },
532
+ "widgets_values": []
533
+ },
534
+ {
535
+ "id": 68,
536
+ "type": "ImageScale",
537
+ "pos": [
538
+ 1059.1640261748782,
539
+ 1655.6404162754113
540
+ ],
541
+ "size": [
542
+ 269.921875,
543
+ 152.8125
544
+ ],
545
+ "flags": {},
546
+ "order": 17,
547
+ "mode": 0,
548
+ "inputs": [
549
+ {
550
+ "name": "image",
551
+ "type": "IMAGE",
552
+ "link": 81
553
+ },
554
+ {
555
+ "name": "width",
556
+ "type": "INT",
557
+ "widget": {
558
+ "name": "width"
559
+ },
560
+ "link": 82
561
+ },
562
+ {
563
+ "name": "height",
564
+ "type": "INT",
565
+ "widget": {
566
+ "name": "height"
567
+ },
568
+ "link": 83
569
+ }
570
+ ],
571
+ "outputs": [
572
+ {
573
+ "name": "IMAGE",
574
+ "type": "IMAGE",
575
+ "links": [
576
+ 79
577
+ ]
578
+ }
579
+ ],
580
+ "properties": {
581
+ "Node name for S&R": "ImageScale",
582
+ "cnr_id": "comfy-core",
583
+ "ver": "0.3.52"
584
+ },
585
+ "widgets_values": [
586
+ "nearest-exact",
587
+ 512,
588
+ 512,
589
+ "center"
590
+ ]
591
+ },
592
+ {
593
+ "id": 69,
594
+ "type": "GetImageSize",
595
+ "pos": [
596
+ 768.3583929275752,
597
+ 1791.1471927140292
598
+ ],
599
+ "size": [
600
+ 187.5,
601
+ 133.4765625
602
+ ],
603
+ "flags": {},
604
+ "order": 15,
605
+ "mode": 0,
606
+ "inputs": [
607
+ {
608
+ "name": "image",
609
+ "type": "IMAGE",
610
+ "link": 84
611
+ }
612
+ ],
613
+ "outputs": [
614
+ {
615
+ "name": "width",
616
+ "type": "INT",
617
+ "links": [
618
+ 77,
619
+ 82
620
+ ]
621
+ },
622
+ {
623
+ "name": "height",
624
+ "type": "INT",
625
+ "links": [
626
+ 78,
627
+ 83
628
+ ]
629
+ },
630
+ {
631
+ "name": "batch_size",
632
+ "type": "INT",
633
+ "links": null
634
+ }
635
+ ],
636
+ "properties": {
637
+ "Node name for S&R": "GetImageSize",
638
+ "cnr_id": "comfy-core",
639
+ "ver": "0.3.52"
640
+ },
641
+ "widgets_values": [
642
+ "width: 1024, height: 1024\n batch size: 1"
643
+ ]
644
+ },
645
+ {
646
+ "id": 63,
647
+ "type": "ImageScale",
648
+ "pos": [
649
+ 1068.1979260124726,
650
+ 1379.5306113893253
651
+ ],
652
+ "size": [
653
+ 269.921875,
654
+ 152.8125
655
+ ],
656
+ "flags": {},
657
+ "order": 16,
658
+ "mode": 0,
659
+ "inputs": [
660
+ {
661
+ "name": "image",
662
+ "type": "IMAGE",
663
+ "link": 88
664
+ },
665
+ {
666
+ "name": "width",
667
+ "type": "INT",
668
+ "widget": {
669
+ "name": "width"
670
+ },
671
+ "link": 77
672
+ },
673
+ {
674
+ "name": "height",
675
+ "type": "INT",
676
+ "widget": {
677
+ "name": "height"
678
+ },
679
+ "link": 78
680
+ }
681
+ ],
682
+ "outputs": [
683
+ {
684
+ "name": "IMAGE",
685
+ "type": "IMAGE",
686
+ "links": [
687
+ 90,
688
+ 94
689
+ ]
690
+ }
691
+ ],
692
+ "properties": {
693
+ "Node name for S&R": "ImageScale",
694
+ "cnr_id": "comfy-core",
695
+ "ver": "0.3.52"
696
+ },
697
+ "widgets_values": [
698
+ "area",
699
+ 512,
700
+ 512,
701
+ "center"
702
+ ]
703
+ },
704
+ {
705
+ "id": 65,
706
+ "type": "ImageToMask",
707
+ "pos": [
708
+ 1060.4634757752433,
709
+ 1829.122961862717
710
+ ],
711
+ "size": [
712
+ 269.921875,
713
+ 67.82552083333334
714
+ ],
715
+ "flags": {},
716
+ "order": 19,
717
+ "mode": 0,
718
+ "inputs": [
719
+ {
720
+ "name": "image",
721
+ "type": "IMAGE",
722
+ "link": 79
723
+ }
724
+ ],
725
+ "outputs": [
726
+ {
727
+ "name": "MASK",
728
+ "type": "MASK",
729
+ "links": [
730
+ 91,
731
+ 95
732
+ ]
733
+ }
734
+ ],
735
+ "properties": {
736
+ "Node name for S&R": "ImageToMask",
737
+ "cnr_id": "comfy-core",
738
+ "ver": "0.3.51"
739
+ },
740
+ "widgets_values": [
741
+ "red"
742
+ ]
743
+ },
744
+ {
745
+ "id": 72,
746
+ "type": "Note",
747
+ "pos": [
748
+ 1072.3258089884341,
749
+ 1251.3163769049763
750
+ ],
751
+ "size": [
752
+ 210,
753
+ 88
754
+ ],
755
+ "flags": {},
756
+ "order": 3,
757
+ "mode": 0,
758
+ "inputs": [],
759
+ "outputs": [],
760
+ "properties": {},
761
+ "widgets_values": [
762
+ "Reshape image to suit VAE "
763
+ ],
764
+ "color": "#432",
765
+ "bgcolor": "#653"
766
+ },
767
+ {
768
+ "id": 46,
769
+ "type": "UNETLoader",
770
+ "pos": [
771
+ 130.8803835176007,
772
+ 238.85087590367888
773
+ ],
774
+ "size": [
775
+ 269.77864583333337,
776
+ 96.15885416666667
777
+ ],
778
+ "flags": {},
779
+ "order": 4,
780
+ "mode": 0,
781
+ "inputs": [],
782
+ "outputs": [
783
+ {
784
+ "name": "MODEL",
785
+ "type": "MODEL",
786
+ "links": [
787
+ 54
788
+ ]
789
+ }
790
+ ],
791
+ "properties": {
792
+ "Node name for S&R": "UNETLoader",
793
+ "cnr_id": "comfy-core",
794
+ "ver": "0.3.73",
795
+ "models": [
796
+ {
797
+ "name": "z_image_turbo_bf16.safetensors",
798
+ "url": "https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/diffusion_models/z_image_turbo_bf16.safetensors",
799
+ "directory": "diffusion_models"
800
+ }
801
+ ],
802
+ "enableTabs": false,
803
+ "tabWidth": 65,
804
+ "tabXOffset": 10,
805
+ "hasSecondTab": false,
806
+ "secondTabText": "Send Back",
807
+ "secondTabOffset": 80,
808
+ "secondTabWidth": 65
809
+ },
810
+ "widgets_values": [
811
+ "z_image_bf16.safetensors",
812
+ "default"
813
+ ]
814
+ },
815
+ {
816
+ "id": 57,
817
+ "type": "LoadImage",
818
+ "pos": [
819
+ 6.077161599140862,
820
+ 923.8378757225194
821
+ ],
822
+ "size": [
823
+ 273.88020833333337,
824
+ 546.8098958333334
825
+ ],
826
+ "flags": {},
827
+ "order": 5,
828
+ "mode": 0,
829
+ "inputs": [],
830
+ "outputs": [
831
+ {
832
+ "name": "IMAGE",
833
+ "type": "IMAGE",
834
+ "links": [
835
+ 85,
836
+ 88
837
+ ]
838
+ },
839
+ {
840
+ "name": "MASK",
841
+ "type": "MASK",
842
+ "links": [
843
+ 89
844
+ ]
845
+ }
846
+ ],
847
+ "properties": {
848
+ "Node name for S&R": "LoadImage",
849
+ "cnr_id": "comfy-core",
850
+ "ver": "0.3.59",
851
+ "ue_properties": {
852
+ "widget_ue_connectable": {},
853
+ "version": "7.1",
854
+ "input_ue_unconnectable": {}
855
+ },
856
+ "image": "clipspace/clipspace-painted-masked-1769703696385.png [input]"
857
+ },
858
+ "widgets_values": [
859
+ "clipspace/clipspace-painted-masked-1769703696385.png [input]",
860
+ "image"
861
+ ]
862
+ },
863
+ {
864
+ "id": 39,
865
+ "type": "CLIPLoader",
866
+ "pos": [
867
+ 130.26337981400314,
868
+ 405.2542176588747
869
+ ],
870
+ "size": [
871
+ 269.77864583333337,
872
+ 124.4921875
873
+ ],
874
+ "flags": {},
875
+ "order": 6,
876
+ "mode": 0,
877
+ "inputs": [],
878
+ "outputs": [
879
+ {
880
+ "name": "CLIP",
881
+ "type": "CLIP",
882
+ "links": [
883
+ 44,
884
+ 98
885
+ ]
886
+ }
887
+ ],
888
+ "properties": {
889
+ "Node name for S&R": "CLIPLoader",
890
+ "cnr_id": "comfy-core",
891
+ "ver": "0.3.73",
892
+ "models": [
893
+ {
894
+ "name": "qwen_3_4b.safetensors",
895
+ "url": "https://huggingface.co/Comfy-Org/z_image_turbo/resolve/main/split_files/text_encoders/qwen_3_4b.safetensors",
896
+ "directory": "text_encoders"
897
+ }
898
+ ],
899
+ "enableTabs": false,
900
+ "tabWidth": 65,
901
+ "tabXOffset": 10,
902
+ "hasSecondTab": false,
903
+ "secondTabText": "Send Back",
904
+ "secondTabOffset": 80,
905
+ "secondTabWidth": 65
906
+ },
907
+ "widgets_values": [
908
+ "qwen_3_4b.safetensors",
909
+ "lumina2",
910
+ "default"
911
+ ]
912
+ },
913
+ {
914
+ "id": 75,
915
+ "type": "CLIPTextEncode",
916
+ "pos": [
917
+ 448.7872367553159,
918
+ 690.9253024127064
919
+ ],
920
+ "size": [
921
+ 390,
922
+ 125
923
+ ],
924
+ "flags": {},
925
+ "order": 12,
926
+ "mode": 0,
927
+ "inputs": [
928
+ {
929
+ "name": "clip",
930
+ "type": "CLIP",
931
+ "link": 98
932
+ }
933
+ ],
934
+ "outputs": [
935
+ {
936
+ "name": "CONDITIONING",
937
+ "type": "CONDITIONING",
938
+ "links": [
939
+ 102
940
+ ]
941
+ }
942
+ ],
943
+ "title": "CLIP Text Encode (Negative Prompt)",
944
+ "properties": {
945
+ "Node name for S&R": "CLIPTextEncode",
946
+ "cnr_id": "comfy-core",
947
+ "ver": "0.3.73",
948
+ "enableTabs": false,
949
+ "tabWidth": 65,
950
+ "tabXOffset": 10,
951
+ "hasSecondTab": false,
952
+ "secondTabText": "Send Back",
953
+ "secondTabOffset": 80,
954
+ "secondTabWidth": 65
955
+ },
956
+ "widgets_values": [
957
+ ""
958
+ ],
959
+ "color": "#323",
960
+ "bgcolor": "#535"
961
+ },
962
+ {
963
+ "id": 73,
964
+ "type": "PreviewImage",
965
+ "pos": [
966
+ 1828.9318713728562,
967
+ 114.5680075231259
968
+ ],
969
+ "size": [
970
+ 187.5,
971
+ 246
972
+ ],
973
+ "flags": {},
974
+ "order": 24,
975
+ "mode": 0,
976
+ "inputs": [
977
+ {
978
+ "name": "images",
979
+ "type": "IMAGE",
980
+ "link": 93
981
+ }
982
+ ],
983
+ "outputs": [],
984
+ "properties": {
985
+ "Node name for S&R": "PreviewImage",
986
+ "cnr_id": "comfy-core",
987
+ "ver": "0.3.76"
988
+ },
989
+ "widgets_values": []
990
+ },
991
+ {
992
+ "id": 47,
993
+ "type": "ModelSamplingAuraFlow",
994
+ "pos": [
995
+ 920.7037987240392,
996
+ 248.48064332359456
997
+ ],
998
+ "size": [
999
+ 309.89583333333337,
1000
+ 67.82552083333334
1001
+ ],
1002
+ "flags": {},
1003
+ "order": 13,
1004
+ "mode": 0,
1005
+ "inputs": [
1006
+ {
1007
+ "name": "model",
1008
+ "type": "MODEL",
1009
+ "link": 60
1010
+ }
1011
+ ],
1012
+ "outputs": [
1013
+ {
1014
+ "name": "MODEL",
1015
+ "type": "MODEL",
1016
+ "slot_index": 0,
1017
+ "links": [
1018
+ 100
1019
+ ]
1020
+ }
1021
+ ],
1022
+ "properties": {
1023
+ "Node name for S&R": "ModelSamplingAuraFlow",
1024
+ "cnr_id": "comfy-core",
1025
+ "ver": "0.3.64",
1026
+ "enableTabs": false,
1027
+ "tabWidth": 65,
1028
+ "tabXOffset": 10,
1029
+ "hasSecondTab": false,
1030
+ "secondTabText": "Send Back",
1031
+ "secondTabOffset": 80,
1032
+ "secondTabWidth": 65
1033
+ },
1034
+ "widgets_values": [
1035
+ 3
1036
+ ]
1037
+ },
1038
+ {
1039
+ "id": 56,
1040
+ "type": "LanPaint_KSampler",
1041
+ "pos": [
1042
+ 1869.2934574860883,
1043
+ 468.13621723594605
1044
+ ],
1045
+ "size": [
1046
+ 372.64694675564056,
1047
+ 406.22742984745275
1048
+ ],
1049
+ "flags": {},
1050
+ "order": 7,
1051
+ "mode": 0,
1052
+ "inputs": [
1053
+ {
1054
+ "name": "model",
1055
+ "type": "MODEL",
1056
+ "link": null
1057
+ },
1058
+ {
1059
+ "name": "positive",
1060
+ "type": "CONDITIONING",
1061
+ "link": null
1062
+ },
1063
+ {
1064
+ "name": "negative",
1065
+ "type": "CONDITIONING",
1066
+ "link": null
1067
+ },
1068
+ {
1069
+ "name": "latent_image",
1070
+ "type": "LATENT",
1071
+ "link": null
1072
+ }
1073
+ ],
1074
+ "outputs": [
1075
+ {
1076
+ "name": "LATENT",
1077
+ "type": "LATENT",
1078
+ "links": []
1079
+ }
1080
+ ],
1081
+ "properties": {
1082
+ "Node name for S&R": "LanPaint_KSampler",
1083
+ "cnr_id": "LanPaint",
1084
+ "ver": "6109df6591a4cf2bc9d3b113d03f7297fa9248e9"
1085
+ },
1086
+ "widgets_values": [
1087
+ 1011254864048366,
1088
+ "randomize",
1089
+ 20,
1090
+ 4,
1091
+ "euler",
1092
+ "simple",
1093
+ 1,
1094
+ 5,
1095
+ "Prompt First",
1096
+ "LanPaint KSampler. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!",
1097
+ "🖼️ Image Inpainting"
1098
+ ]
1099
+ },
1100
+ {
1101
+ "id": 45,
1102
+ "type": "CLIPTextEncode",
1103
+ "pos": [
1104
+ 450.2633140828448,
1105
+ 275.25446846701436
1106
+ ],
1107
+ "size": [
1108
+ 409.77864583333337,
1109
+ 374.77864583333337
1110
+ ],
1111
+ "flags": {},
1112
+ "order": 11,
1113
+ "mode": 0,
1114
+ "inputs": [
1115
+ {
1116
+ "name": "clip",
1117
+ "type": "CLIP",
1118
+ "link": 44
1119
+ }
1120
+ ],
1121
+ "outputs": [
1122
+ {
1123
+ "name": "CONDITIONING",
1124
+ "type": "CONDITIONING",
1125
+ "links": [
1126
+ 101
1127
+ ]
1128
+ }
1129
+ ],
1130
+ "properties": {
1131
+ "Node name for S&R": "CLIPTextEncode",
1132
+ "cnr_id": "comfy-core",
1133
+ "ver": "0.3.73",
1134
+ "enableTabs": false,
1135
+ "tabWidth": 65,
1136
+ "tabXOffset": 10,
1137
+ "hasSecondTab": false,
1138
+ "secondTabText": "Send Back",
1139
+ "secondTabOffset": 80,
1140
+ "secondTabWidth": 65
1141
+ },
1142
+ "widgets_values": [
1143
+ "A fashion photography work full of surreal romanticism, using a low-angle upward shooting composition, with a clear light blue sky as the background, and the visual focus concentrated on the fantasy blue vegetation and the cute gaint panda walking through it.\n\nThe vegetation in the picture is processed into varying shades of blue, from light ice blue to deep cobalt blue. The textures of the leaves and branches are delicate and realistic. The warm brown tree trunks form a sharp contrast with the cool blue leaves, resembling a dreamy forest from another world. A cute gaint panda walks slowly on the sand. The warm tones of the dress echo with the surrounding cool blue vegetation. The noon sun casts clear shadows on the sand, enhancing the sense of space and reality in the picture.\n\nThe entire scene, with its clean and transparent colors and fantasy settings, not only exudes the vastness of the natural wilderness but also presents a quiet and poetic high-fashion sense due to the surreal vegetation."
1144
+ ],
1145
+ "color": "#232",
1146
+ "bgcolor": "#353"
1147
+ },
1148
+ {
1149
+ "id": 76,
1150
+ "type": "LanPaint_KSamplerAdvanced",
1151
+ "pos": [
1152
+ 1234.9129727307572,
1153
+ 465.17562131822933
1154
+ ],
1155
+ "size": [
1156
+ 400,
1157
+ 580
1158
+ ],
1159
+ "flags": {},
1160
+ "order": 21,
1161
+ "mode": 0,
1162
+ "inputs": [
1163
+ {
1164
+ "name": "model",
1165
+ "type": "MODEL",
1166
+ "link": 100
1167
+ },
1168
+ {
1169
+ "name": "positive",
1170
+ "type": "CONDITIONING",
1171
+ "link": 101
1172
+ },
1173
+ {
1174
+ "name": "negative",
1175
+ "type": "CONDITIONING",
1176
+ "link": 102
1177
+ },
1178
+ {
1179
+ "name": "latent_image",
1180
+ "type": "LATENT",
1181
+ "link": 103
1182
+ }
1183
+ ],
1184
+ "outputs": [
1185
+ {
1186
+ "name": "LATENT",
1187
+ "type": "LATENT",
1188
+ "links": [
1189
+ 104
1190
+ ]
1191
+ }
1192
+ ],
1193
+ "properties": {
1194
+ "Node name for S&R": "LanPaint_KSamplerAdvanced"
1195
+ },
1196
+ "widgets_values": [
1197
+ "enable",
1198
+ 0,
1199
+ "fixed",
1200
+ 20,
1201
+ 4,
1202
+ "euler",
1203
+ "simple",
1204
+ 0,
1205
+ 10000,
1206
+ "disable",
1207
+ 3,
1208
+ 8,
1209
+ 0.05,
1210
+ 1,
1211
+ 25,
1212
+ "Image First",
1213
+ 1,
1214
+ "LanPaint KSampler Adv. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!",
1215
+ "🖼️ Image Inpainting"
1216
+ ]
1217
+ }
1218
+ ],
1219
+ "links": [
1220
+ [
1221
+ 39,
1222
+ 40,
1223
+ 0,
1224
+ 43,
1225
+ 1,
1226
+ "VAE"
1227
+ ],
1228
+ [
1229
+ 44,
1230
+ 39,
1231
+ 0,
1232
+ 45,
1233
+ 0,
1234
+ "CLIP"
1235
+ ],
1236
+ [
1237
+ 54,
1238
+ 46,
1239
+ 0,
1240
+ 48,
1241
+ 0,
1242
+ "MODEL"
1243
+ ],
1244
+ [
1245
+ 60,
1246
+ 48,
1247
+ 0,
1248
+ 47,
1249
+ 0,
1250
+ "MODEL"
1251
+ ],
1252
+ [
1253
+ 67,
1254
+ 58,
1255
+ 0,
1256
+ 59,
1257
+ 0,
1258
+ "LATENT"
1259
+ ],
1260
+ [
1261
+ 70,
1262
+ 40,
1263
+ 0,
1264
+ 58,
1265
+ 1,
1266
+ "VAE"
1267
+ ],
1268
+ [
1269
+ 72,
1270
+ 60,
1271
+ 0,
1272
+ 61,
1273
+ 0,
1274
+ "IMAGE"
1275
+ ],
1276
+ [
1277
+ 73,
1278
+ 43,
1279
+ 0,
1280
+ 60,
1281
+ 1,
1282
+ "IMAGE"
1283
+ ],
1284
+ [
1285
+ 76,
1286
+ 67,
1287
+ 0,
1288
+ 62,
1289
+ 0,
1290
+ "LATENT"
1291
+ ],
1292
+ [
1293
+ 77,
1294
+ 69,
1295
+ 0,
1296
+ 63,
1297
+ 1,
1298
+ "INT"
1299
+ ],
1300
+ [
1301
+ 78,
1302
+ 69,
1303
+ 1,
1304
+ 63,
1305
+ 2,
1306
+ "INT"
1307
+ ],
1308
+ [
1309
+ 79,
1310
+ 68,
1311
+ 0,
1312
+ 65,
1313
+ 0,
1314
+ "IMAGE"
1315
+ ],
1316
+ [
1317
+ 81,
1318
+ 64,
1319
+ 0,
1320
+ 68,
1321
+ 0,
1322
+ "IMAGE"
1323
+ ],
1324
+ [
1325
+ 82,
1326
+ 69,
1327
+ 0,
1328
+ 68,
1329
+ 1,
1330
+ "INT"
1331
+ ],
1332
+ [
1333
+ 83,
1334
+ 69,
1335
+ 1,
1336
+ 68,
1337
+ 2,
1338
+ "INT"
1339
+ ],
1340
+ [
1341
+ 84,
1342
+ 62,
1343
+ 0,
1344
+ 69,
1345
+ 0,
1346
+ "IMAGE"
1347
+ ],
1348
+ [
1349
+ 85,
1350
+ 57,
1351
+ 0,
1352
+ 67,
1353
+ 0,
1354
+ "IMAGE"
1355
+ ],
1356
+ [
1357
+ 86,
1358
+ 40,
1359
+ 0,
1360
+ 67,
1361
+ 1,
1362
+ "VAE"
1363
+ ],
1364
+ [
1365
+ 87,
1366
+ 40,
1367
+ 0,
1368
+ 62,
1369
+ 1,
1370
+ "VAE"
1371
+ ],
1372
+ [
1373
+ 88,
1374
+ 57,
1375
+ 0,
1376
+ 63,
1377
+ 0,
1378
+ "IMAGE"
1379
+ ],
1380
+ [
1381
+ 89,
1382
+ 57,
1383
+ 1,
1384
+ 64,
1385
+ 0,
1386
+ "MASK"
1387
+ ],
1388
+ [
1389
+ 90,
1390
+ 63,
1391
+ 0,
1392
+ 58,
1393
+ 0,
1394
+ "IMAGE"
1395
+ ],
1396
+ [
1397
+ 91,
1398
+ 65,
1399
+ 0,
1400
+ 59,
1401
+ 1,
1402
+ "MASK"
1403
+ ],
1404
+ [
1405
+ 93,
1406
+ 43,
1407
+ 0,
1408
+ 73,
1409
+ 0,
1410
+ "IMAGE"
1411
+ ],
1412
+ [
1413
+ 94,
1414
+ 63,
1415
+ 0,
1416
+ 60,
1417
+ 0,
1418
+ "IMAGE"
1419
+ ],
1420
+ [
1421
+ 95,
1422
+ 65,
1423
+ 0,
1424
+ 60,
1425
+ 2,
1426
+ "MASK"
1427
+ ],
1428
+ [
1429
+ 98,
1430
+ 39,
1431
+ 0,
1432
+ 75,
1433
+ 0,
1434
+ "CLIP"
1435
+ ],
1436
+ [
1437
+ 100,
1438
+ 47,
1439
+ 0,
1440
+ 76,
1441
+ 0,
1442
+ "MODEL"
1443
+ ],
1444
+ [
1445
+ 101,
1446
+ 45,
1447
+ 0,
1448
+ 76,
1449
+ 1,
1450
+ "CONDITIONING"
1451
+ ],
1452
+ [
1453
+ 102,
1454
+ 75,
1455
+ 0,
1456
+ 76,
1457
+ 2,
1458
+ "CONDITIONING"
1459
+ ],
1460
+ [
1461
+ 103,
1462
+ 59,
1463
+ 0,
1464
+ 76,
1465
+ 3,
1466
+ "LATENT"
1467
+ ],
1468
+ [
1469
+ 104,
1470
+ 76,
1471
+ 0,
1472
+ 43,
1473
+ 0,
1474
+ "LATENT"
1475
+ ]
1476
+ ],
1477
+ "groups": [
1478
+ {
1479
+ "id": 2,
1480
+ "title": "Step2 - Image size",
1481
+ "bounding": [
1482
+ 120,
1483
+ 640,
1484
+ 290,
1485
+ 200
1486
+ ],
1487
+ "color": "#3f789e",
1488
+ "font_size": 24,
1489
+ "flags": {}
1490
+ },
1491
+ {
1492
+ "id": 3,
1493
+ "title": "Step3 - Prompt",
1494
+ "bounding": [
1495
+ 430,
1496
+ 210,
1497
+ 450,
1498
+ 540
1499
+ ],
1500
+ "color": "#3f789e",
1501
+ "font_size": 24,
1502
+ "flags": {}
1503
+ },
1504
+ {
1505
+ "id": 4,
1506
+ "title": "Step1 - Load models",
1507
+ "bounding": [
1508
+ 120,
1509
+ 210,
1510
+ 290,
1511
+ 413.6
1512
+ ],
1513
+ "color": "#3f789e",
1514
+ "font_size": 24,
1515
+ "flags": {}
1516
+ },
1517
+ {
1518
+ "id": 5,
1519
+ "title": "Ctrl-B to enable LoRA input",
1520
+ "bounding": [
1521
+ 430,
1522
+ 40,
1523
+ 440,
1524
+ 160
1525
+ ],
1526
+ "color": "#3f789e",
1527
+ "font_size": 24,
1528
+ "flags": {}
1529
+ }
1530
+ ],
1531
+ "config": {},
1532
+ "extra": {
1533
+ "ds": {
1534
+ "scale": 0.2673486306413776,
1535
+ "offset": [
1536
+ 853.4341376683553,
1537
+ 289.09247282952845
1538
+ ]
1539
+ },
1540
+ "frontendVersion": "1.37.11",
1541
+ "VHS_latentpreview": false,
1542
+ "VHS_latentpreviewrate": 0,
1543
+ "VHS_MetadataImage": true,
1544
+ "VHS_KeepIntermediate": true,
1545
+ "workflowRendererVersion": "LG"
1546
+ },
1547
+ "version": 0.4
1548
+ }
LanPaint/example_workflows/wan2_2_T2I_Inpaint.jpg ADDED

Git LFS Details

  • SHA256: d09ce42506d6ebdbbd43a3105f050091f93c439a4e10c76b22c8e391c18a7b35
  • Pointer size: 131 Bytes
  • Size of remote file: 699 kB
LanPaint/example_workflows/wan2_2_T2I_Inpaint.json ADDED
@@ -0,0 +1,1330 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "26bf2769-956f-4cee-b5f6-a57a366c9101",
3
+ "revision": 0,
4
+ "last_node_id": 83,
5
+ "last_link_id": 180,
6
+ "nodes": [
7
+ {
8
+ "id": 56,
9
+ "type": "UNETLoader",
10
+ "pos": [
11
+ 34.70310592651367,
12
+ 57.175601959228516
13
+ ],
14
+ "size": [
15
+ 346.7470703125,
16
+ 82
17
+ ],
18
+ "flags": {},
19
+ "order": 0,
20
+ "mode": 0,
21
+ "inputs": [],
22
+ "outputs": [
23
+ {
24
+ "name": "MODEL",
25
+ "type": "MODEL",
26
+ "slot_index": 0,
27
+ "links": [
28
+ 112
29
+ ]
30
+ }
31
+ ],
32
+ "properties": {
33
+ "cnr_id": "comfy-core",
34
+ "ver": "0.3.45",
35
+ "Node name for S&R": "UNETLoader",
36
+ "models": [
37
+ {
38
+ "name": "wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors",
39
+ "url": "https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/diffusion_models/wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors",
40
+ "directory": "diffusion_models"
41
+ }
42
+ ],
43
+ "widget_ue_connectable": {}
44
+ },
45
+ "widgets_values": [
46
+ "wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors",
47
+ "default"
48
+ ]
49
+ },
50
+ {
51
+ "id": 54,
52
+ "type": "ModelSamplingSD3",
53
+ "pos": [
54
+ 640,
55
+ -70
56
+ ],
57
+ "size": [
58
+ 210,
59
+ 60
60
+ ],
61
+ "flags": {},
62
+ "order": 15,
63
+ "mode": 0,
64
+ "inputs": [
65
+ {
66
+ "name": "model",
67
+ "type": "MODEL",
68
+ "link": 110
69
+ }
70
+ ],
71
+ "outputs": [
72
+ {
73
+ "name": "MODEL",
74
+ "type": "MODEL",
75
+ "slot_index": 0,
76
+ "links": [
77
+ 150
78
+ ]
79
+ }
80
+ ],
81
+ "properties": {
82
+ "cnr_id": "comfy-core",
83
+ "ver": "0.3.45",
84
+ "Node name for S&R": "ModelSamplingSD3",
85
+ "widget_ue_connectable": {}
86
+ },
87
+ "widgets_values": [
88
+ 1
89
+ ]
90
+ },
91
+ {
92
+ "id": 55,
93
+ "type": "ModelSamplingSD3",
94
+ "pos": [
95
+ 640,
96
+ 60
97
+ ],
98
+ "size": [
99
+ 210,
100
+ 58
101
+ ],
102
+ "flags": {},
103
+ "order": 14,
104
+ "mode": 0,
105
+ "inputs": [
106
+ {
107
+ "name": "model",
108
+ "type": "MODEL",
109
+ "link": 112
110
+ }
111
+ ],
112
+ "outputs": [
113
+ {
114
+ "name": "MODEL",
115
+ "type": "MODEL",
116
+ "slot_index": 0,
117
+ "links": [
118
+ 159
119
+ ]
120
+ }
121
+ ],
122
+ "properties": {
123
+ "cnr_id": "comfy-core",
124
+ "ver": "0.3.45",
125
+ "Node name for S&R": "ModelSamplingSD3",
126
+ "widget_ue_connectable": {}
127
+ },
128
+ "widgets_values": [
129
+ 1
130
+ ]
131
+ },
132
+ {
133
+ "id": 62,
134
+ "type": "MarkdownNote",
135
+ "pos": [
136
+ -480,
137
+ -120
138
+ ],
139
+ "size": [
140
+ 480,
141
+ 350
142
+ ],
143
+ "flags": {},
144
+ "order": 1,
145
+ "mode": 0,
146
+ "inputs": [],
147
+ "outputs": [],
148
+ "title": "Model Links",
149
+ "properties": {
150
+ "widget_ue_connectable": {}
151
+ },
152
+ "widgets_values": [
153
+ "[Tutorial](https://docs.comfy.org/tutorials/video/wan/wan2_2\n) | [教程](https://docs.comfy.org/zh-CN/tutorials/video/wan/wan2_2\n)\n\n**Diffusion Model**\n- [wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors](https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/diffusion_models/wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors)\n- [wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors](https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/diffusion_models/wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors)\n\n**VAE**\n- [wan_2.1_vae.safetensors](https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/vae/wan_2.1_vae.safetensors)\n\n**Text Encoder** \n- [umt5_xxl_fp8_e4m3fn_scaled.safetensors](https://huggingface.co/Comfy-Org/Wan_2.1_ComfyUI_repackaged/resolve/main/split_files/text_encoders/umt5_xxl_fp8_e4m3fn_scaled.safetensors)\n\n\nFile save location\n\n```\nComfyUI/\n├───📂 models/\n│ ├───📂 diffusion_models/\n│ │ ├─── wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors\n│ │ └─── wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors\n│ ├───📂 text_encoders/\n│ │ └─── umt5_xxl_fp8_e4m3fn_scaled.safetensors \n│ └───📂 vae/\n│ └── wan_2.1_vae.safetensors\n```\n"
154
+ ],
155
+ "color": "#432",
156
+ "bgcolor": "#653"
157
+ },
158
+ {
159
+ "id": 7,
160
+ "type": "CLIPTextEncode",
161
+ "pos": [
162
+ 415.27801513671875,
163
+ 562.8309936523438
164
+ ],
165
+ "size": [
166
+ 425.27801513671875,
167
+ 180.6060791015625
168
+ ],
169
+ "flags": {},
170
+ "order": 17,
171
+ "mode": 0,
172
+ "inputs": [
173
+ {
174
+ "name": "clip",
175
+ "type": "CLIP",
176
+ "link": 75
177
+ }
178
+ ],
179
+ "outputs": [
180
+ {
181
+ "name": "CONDITIONING",
182
+ "type": "CONDITIONING",
183
+ "slot_index": 0,
184
+ "links": [
185
+ 152,
186
+ 161
187
+ ]
188
+ }
189
+ ],
190
+ "title": "CLIP Text Encode (Negative Prompt)",
191
+ "properties": {
192
+ "cnr_id": "comfy-core",
193
+ "ver": "0.3.45",
194
+ "Node name for S&R": "CLIPTextEncode",
195
+ "widget_ue_connectable": {}
196
+ },
197
+ "widgets_values": [
198
+ "色调艳丽,过曝,静态,细节模糊不清,字幕,风格,作品,画作,画面,静止,整体发灰,最差质量,低质量,JPEG压缩残留,丑陋的,残缺的,多余的手指,画得不好的手部,画得不好的脸部,畸形的,毁容的,形态畸形的肢体,手指融合,静止不动的画面,杂乱的背景,三条腿,背景人很多,倒着走"
199
+ ],
200
+ "color": "#322",
201
+ "bgcolor": "#533"
202
+ },
203
+ {
204
+ "id": 59,
205
+ "type": "EmptyHunyuanLatentVideo",
206
+ "pos": [
207
+ 50,
208
+ 530
209
+ ],
210
+ "size": [
211
+ 315,
212
+ 130
213
+ ],
214
+ "flags": {},
215
+ "order": 2,
216
+ "mode": 0,
217
+ "inputs": [],
218
+ "outputs": [
219
+ {
220
+ "name": "LATENT",
221
+ "type": "LATENT",
222
+ "slot_index": 0,
223
+ "links": []
224
+ }
225
+ ],
226
+ "properties": {
227
+ "cnr_id": "comfy-core",
228
+ "ver": "0.3.45",
229
+ "Node name for S&R": "EmptyHunyuanLatentVideo",
230
+ "widget_ue_connectable": {}
231
+ },
232
+ "widgets_values": [
233
+ 768,
234
+ 1344,
235
+ 1,
236
+ 1
237
+ ]
238
+ },
239
+ {
240
+ "id": 37,
241
+ "type": "UNETLoader",
242
+ "pos": [
243
+ 34.225364685058594,
244
+ -71.77911376953125
245
+ ],
246
+ "size": [
247
+ 346.7470703125,
248
+ 82
249
+ ],
250
+ "flags": {},
251
+ "order": 3,
252
+ "mode": 0,
253
+ "inputs": [],
254
+ "outputs": [
255
+ {
256
+ "name": "MODEL",
257
+ "type": "MODEL",
258
+ "slot_index": 0,
259
+ "links": [
260
+ 110
261
+ ]
262
+ }
263
+ ],
264
+ "properties": {
265
+ "cnr_id": "comfy-core",
266
+ "ver": "0.3.45",
267
+ "Node name for S&R": "UNETLoader",
268
+ "models": [
269
+ {
270
+ "name": "wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors",
271
+ "url": "https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/diffusion_models/wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors",
272
+ "directory": "diffusion_models"
273
+ }
274
+ ],
275
+ "widget_ue_connectable": {}
276
+ },
277
+ "widgets_values": [
278
+ "wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors",
279
+ "default"
280
+ ]
281
+ },
282
+ {
283
+ "id": 38,
284
+ "type": "CLIPLoader",
285
+ "pos": [
286
+ 38.86457061767578,
287
+ 189.26513671875
288
+ ],
289
+ "size": [
290
+ 346.391845703125,
291
+ 106
292
+ ],
293
+ "flags": {},
294
+ "order": 4,
295
+ "mode": 0,
296
+ "inputs": [],
297
+ "outputs": [
298
+ {
299
+ "name": "CLIP",
300
+ "type": "CLIP",
301
+ "slot_index": 0,
302
+ "links": [
303
+ 74,
304
+ 75
305
+ ]
306
+ }
307
+ ],
308
+ "properties": {
309
+ "cnr_id": "comfy-core",
310
+ "ver": "0.3.45",
311
+ "Node name for S&R": "CLIPLoader",
312
+ "models": [
313
+ {
314
+ "name": "umt5_xxl_fp8_e4m3fn_scaled.safetensors",
315
+ "url": "https://huggingface.co/Comfy-Org/Wan_2.1_ComfyUI_repackaged/resolve/main/split_files/text_encoders/umt5_xxl_fp8_e4m3fn_scaled.safetensors",
316
+ "directory": "text_encoders"
317
+ }
318
+ ],
319
+ "widget_ue_connectable": {}
320
+ },
321
+ "widgets_values": [
322
+ "umt5_xxl_fp8_e4m3fn_scaled.safetensors",
323
+ "wan",
324
+ "default"
325
+ ]
326
+ },
327
+ {
328
+ "id": 67,
329
+ "type": "PrimitiveNode",
330
+ "pos": [
331
+ 874.0289916992188,
332
+ 28.25248908996582
333
+ ],
334
+ "size": [
335
+ 312.7867736816406,
336
+ 88.04627990722656
337
+ ],
338
+ "flags": {},
339
+ "order": 5,
340
+ "mode": 0,
341
+ "inputs": [],
342
+ "outputs": [
343
+ {
344
+ "name": "INT",
345
+ "type": "INT",
346
+ "widget": {
347
+ "name": "steps"
348
+ },
349
+ "links": [
350
+ 154,
351
+ 163
352
+ ]
353
+ }
354
+ ],
355
+ "title": "Steps",
356
+ "properties": {
357
+ "Run widget replace on values": false,
358
+ "widget_ue_connectable": {}
359
+ },
360
+ "widgets_values": [
361
+ 20,
362
+ "fixed"
363
+ ]
364
+ },
365
+ {
366
+ "id": 68,
367
+ "type": "PrimitiveNode",
368
+ "pos": [
369
+ 881.3255615234375,
370
+ 167.12957763671875
371
+ ],
372
+ "size": [
373
+ 299.6272277832031,
374
+ 82
375
+ ],
376
+ "flags": {},
377
+ "order": 6,
378
+ "mode": 0,
379
+ "inputs": [],
380
+ "outputs": [
381
+ {
382
+ "name": "INT",
383
+ "type": "INT",
384
+ "widget": {
385
+ "name": "end_at_step"
386
+ },
387
+ "links": [
388
+ 157,
389
+ 166
390
+ ]
391
+ }
392
+ ],
393
+ "title": "Switch_step",
394
+ "properties": {
395
+ "Run widget replace on values": false,
396
+ "widget_ue_connectable": {}
397
+ },
398
+ "widgets_values": [
399
+ 3,
400
+ "fixed"
401
+ ]
402
+ },
403
+ {
404
+ "id": 66,
405
+ "type": "PrimitiveNode",
406
+ "pos": [
407
+ 869.0523071289062,
408
+ 458.133544921875
409
+ ],
410
+ "size": [
411
+ 302.1168212890625,
412
+ 106
413
+ ],
414
+ "flags": {},
415
+ "order": 7,
416
+ "mode": 0,
417
+ "inputs": [],
418
+ "outputs": [
419
+ {
420
+ "name": "COMBO",
421
+ "type": "COMBO",
422
+ "widget": {
423
+ "name": "scheduler"
424
+ },
425
+ "links": [
426
+ 156,
427
+ 165
428
+ ]
429
+ }
430
+ ],
431
+ "title": "Scheduler",
432
+ "properties": {
433
+ "Run widget replace on values": false,
434
+ "widget_ue_connectable": {}
435
+ },
436
+ "widgets_values": [
437
+ "sgm_uniform",
438
+ "fixed",
439
+ ""
440
+ ]
441
+ },
442
+ {
443
+ "id": 71,
444
+ "type": "VAEEncode",
445
+ "pos": [
446
+ 386.7767333984375,
447
+ 924.7274780273438
448
+ ],
449
+ "size": [
450
+ 140,
451
+ 46
452
+ ],
453
+ "flags": {},
454
+ "order": 18,
455
+ "mode": 0,
456
+ "inputs": [
457
+ {
458
+ "name": "pixels",
459
+ "type": "IMAGE",
460
+ "link": 143
461
+ },
462
+ {
463
+ "name": "vae",
464
+ "type": "VAE",
465
+ "link": 146
466
+ }
467
+ ],
468
+ "outputs": [
469
+ {
470
+ "name": "LATENT",
471
+ "type": "LATENT",
472
+ "links": [
473
+ 148
474
+ ]
475
+ }
476
+ ],
477
+ "properties": {
478
+ "cnr_id": "comfy-core",
479
+ "ver": "0.3.59",
480
+ "Node name for S&R": "VAEEncode"
481
+ },
482
+ "widgets_values": []
483
+ },
484
+ {
485
+ "id": 65,
486
+ "type": "PrimitiveNode",
487
+ "pos": [
488
+ 871.877197265625,
489
+ 301.2847595214844
490
+ ],
491
+ "size": [
492
+ 304.6064453125,
493
+ 106
494
+ ],
495
+ "flags": {},
496
+ "order": 8,
497
+ "mode": 0,
498
+ "inputs": [],
499
+ "outputs": [
500
+ {
501
+ "name": "COMBO",
502
+ "type": "COMBO",
503
+ "widget": {
504
+ "name": "sampler_name"
505
+ },
506
+ "links": [
507
+ 155,
508
+ 164
509
+ ]
510
+ }
511
+ ],
512
+ "title": "Sampler",
513
+ "properties": {
514
+ "Run widget replace on values": false,
515
+ "widget_ue_connectable": {}
516
+ },
517
+ "widgets_values": [
518
+ "euler",
519
+ "fixed",
520
+ ""
521
+ ]
522
+ },
523
+ {
524
+ "id": 39,
525
+ "type": "VAELoader",
526
+ "pos": [
527
+ 40,
528
+ 350
529
+ ],
530
+ "size": [
531
+ 344.731689453125,
532
+ 59.98149108886719
533
+ ],
534
+ "flags": {},
535
+ "order": 9,
536
+ "mode": 0,
537
+ "inputs": [],
538
+ "outputs": [
539
+ {
540
+ "name": "VAE",
541
+ "type": "VAE",
542
+ "slot_index": 0,
543
+ "links": [
544
+ 76,
545
+ 146
546
+ ]
547
+ }
548
+ ],
549
+ "properties": {
550
+ "cnr_id": "comfy-core",
551
+ "ver": "0.3.45",
552
+ "Node name for S&R": "VAELoader",
553
+ "models": [
554
+ {
555
+ "name": "wan_2.1_vae.safetensors",
556
+ "url": "https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/vae/wan_2.1_vae.safetensors",
557
+ "directory": "vae"
558
+ }
559
+ ],
560
+ "widget_ue_connectable": {}
561
+ },
562
+ "widgets_values": [
563
+ "wan_2.1_vae.safetensors"
564
+ ]
565
+ },
566
+ {
567
+ "id": 70,
568
+ "type": "SaveImage",
569
+ "pos": [
570
+ 1818.5047607421875,
571
+ -71.57525634765625
572
+ ],
573
+ "size": [
574
+ 270,
575
+ 270
576
+ ],
577
+ "flags": {},
578
+ "order": 23,
579
+ "mode": 0,
580
+ "inputs": [
581
+ {
582
+ "name": "images",
583
+ "type": "IMAGE",
584
+ "link": 142
585
+ }
586
+ ],
587
+ "outputs": [],
588
+ "properties": {
589
+ "cnr_id": "comfy-core",
590
+ "ver": "0.3.59"
591
+ },
592
+ "widgets_values": [
593
+ "ComfyUI"
594
+ ]
595
+ },
596
+ {
597
+ "id": 74,
598
+ "type": "SetLatentNoiseMask",
599
+ "pos": [
600
+ 469.00274658203125,
601
+ 822.289306640625
602
+ ],
603
+ "size": [
604
+ 180.74765014648438,
605
+ 46
606
+ ],
607
+ "flags": {},
608
+ "order": 19,
609
+ "mode": 0,
610
+ "inputs": [
611
+ {
612
+ "name": "samples",
613
+ "type": "LATENT",
614
+ "link": 148
615
+ },
616
+ {
617
+ "name": "mask",
618
+ "type": "MASK",
619
+ "link": 149
620
+ }
621
+ ],
622
+ "outputs": [
623
+ {
624
+ "name": "LATENT",
625
+ "type": "LATENT",
626
+ "links": [
627
+ 167
628
+ ]
629
+ }
630
+ ],
631
+ "properties": {
632
+ "cnr_id": "comfy-core",
633
+ "ver": "0.3.59",
634
+ "Node name for S&R": "SetLatentNoiseMask"
635
+ },
636
+ "widgets_values": []
637
+ },
638
+ {
639
+ "id": 75,
640
+ "type": "LanPaint_KSamplerAdvanced",
641
+ "pos": [
642
+ 1271.481201171875,
643
+ -503.987548828125
644
+ ],
645
+ "size": [
646
+ 400,
647
+ 764
648
+ ],
649
+ "flags": {},
650
+ "order": 20,
651
+ "mode": 0,
652
+ "inputs": [
653
+ {
654
+ "name": "model",
655
+ "type": "MODEL",
656
+ "link": 150
657
+ },
658
+ {
659
+ "name": "positive",
660
+ "type": "CONDITIONING",
661
+ "link": 151
662
+ },
663
+ {
664
+ "name": "negative",
665
+ "type": "CONDITIONING",
666
+ "link": 152
667
+ },
668
+ {
669
+ "name": "latent_image",
670
+ "type": "LATENT",
671
+ "link": 167
672
+ },
673
+ {
674
+ "name": "steps",
675
+ "type": "INT",
676
+ "widget": {
677
+ "name": "steps"
678
+ },
679
+ "link": 154
680
+ },
681
+ {
682
+ "name": "sampler_name",
683
+ "type": "COMBO",
684
+ "widget": {
685
+ "name": "sampler_name"
686
+ },
687
+ "link": 155
688
+ },
689
+ {
690
+ "name": "scheduler",
691
+ "type": "COMBO",
692
+ "widget": {
693
+ "name": "scheduler"
694
+ },
695
+ "link": 156
696
+ },
697
+ {
698
+ "name": "end_at_step",
699
+ "type": "INT",
700
+ "widget": {
701
+ "name": "end_at_step"
702
+ },
703
+ "link": 157
704
+ }
705
+ ],
706
+ "outputs": [
707
+ {
708
+ "name": "LATENT",
709
+ "type": "LATENT",
710
+ "links": [
711
+ 172
712
+ ]
713
+ }
714
+ ],
715
+ "properties": {
716
+ "cnr_id": "LanPaint",
717
+ "ver": "1b50a90424318a457ff32a1fd5ee8a441b768b45",
718
+ "Node name for S&R": "LanPaint_KSamplerAdvanced"
719
+ },
720
+ "widgets_values": [
721
+ "enable",
722
+ 310185466124726,
723
+ "randomize",
724
+ 20,
725
+ 2,
726
+ "euler",
727
+ "sgm_uniform",
728
+ 0,
729
+ 3,
730
+ "disable",
731
+ 5,
732
+ 16,
733
+ 0.15,
734
+ 1,
735
+ 15,
736
+ "Image First",
737
+ 1,
738
+ "LanPaint KSampler Adv. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!"
739
+ ]
740
+ },
741
+ {
742
+ "id": 8,
743
+ "type": "VAEDecode",
744
+ "pos": [
745
+ 1836.6907958984375,
746
+ -249.27249145507812
747
+ ],
748
+ "size": [
749
+ 210,
750
+ 46
751
+ ],
752
+ "flags": {},
753
+ "order": 22,
754
+ "mode": 0,
755
+ "inputs": [
756
+ {
757
+ "name": "samples",
758
+ "type": "LATENT",
759
+ "link": 162
760
+ },
761
+ {
762
+ "name": "vae",
763
+ "type": "VAE",
764
+ "link": 76
765
+ }
766
+ ],
767
+ "outputs": [
768
+ {
769
+ "name": "IMAGE",
770
+ "type": "IMAGE",
771
+ "slot_index": 0,
772
+ "links": [
773
+ 142
774
+ ]
775
+ }
776
+ ],
777
+ "properties": {
778
+ "cnr_id": "comfy-core",
779
+ "ver": "0.3.45",
780
+ "Node name for S&R": "VAEDecode",
781
+ "widget_ue_connectable": {}
782
+ },
783
+ "widgets_values": []
784
+ },
785
+ {
786
+ "id": 63,
787
+ "type": "Note",
788
+ "pos": [
789
+ 20,
790
+ 720
791
+ ],
792
+ "size": [
793
+ 370,
794
+ 120
795
+ ],
796
+ "flags": {},
797
+ "order": 10,
798
+ "mode": 0,
799
+ "inputs": [],
800
+ "outputs": [],
801
+ "title": "Video Size",
802
+ "properties": {
803
+ "widget_ue_connectable": {}
804
+ },
805
+ "widgets_values": [
806
+ "By default, we set the video to a smaller size for users with low VRAM. If you have enough VRAM, you can change the size"
807
+ ],
808
+ "color": "#432",
809
+ "bgcolor": "#653"
810
+ },
811
+ {
812
+ "id": 76,
813
+ "type": "LanPaint_KSamplerAdvanced",
814
+ "pos": [
815
+ 1276.2220458984375,
816
+ 325.4043884277344
817
+ ],
818
+ "size": [
819
+ 400,
820
+ 764
821
+ ],
822
+ "flags": {},
823
+ "order": 21,
824
+ "mode": 0,
825
+ "inputs": [
826
+ {
827
+ "name": "model",
828
+ "type": "MODEL",
829
+ "link": 159
830
+ },
831
+ {
832
+ "name": "positive",
833
+ "type": "CONDITIONING",
834
+ "link": 160
835
+ },
836
+ {
837
+ "name": "negative",
838
+ "type": "CONDITIONING",
839
+ "link": 161
840
+ },
841
+ {
842
+ "name": "latent_image",
843
+ "type": "LATENT",
844
+ "link": 172
845
+ },
846
+ {
847
+ "name": "steps",
848
+ "type": "INT",
849
+ "widget": {
850
+ "name": "steps"
851
+ },
852
+ "link": 163
853
+ },
854
+ {
855
+ "name": "sampler_name",
856
+ "type": "COMBO",
857
+ "widget": {
858
+ "name": "sampler_name"
859
+ },
860
+ "link": 164
861
+ },
862
+ {
863
+ "name": "scheduler",
864
+ "type": "COMBO",
865
+ "widget": {
866
+ "name": "scheduler"
867
+ },
868
+ "link": 165
869
+ },
870
+ {
871
+ "name": "start_at_step",
872
+ "type": "INT",
873
+ "widget": {
874
+ "name": "start_at_step"
875
+ },
876
+ "link": 166
877
+ }
878
+ ],
879
+ "outputs": [
880
+ {
881
+ "name": "LATENT",
882
+ "type": "LATENT",
883
+ "links": [
884
+ 162
885
+ ]
886
+ }
887
+ ],
888
+ "properties": {
889
+ "cnr_id": "LanPaint",
890
+ "ver": "1b50a90424318a457ff32a1fd5ee8a441b768b45",
891
+ "Node name for S&R": "LanPaint_KSamplerAdvanced"
892
+ },
893
+ "widgets_values": [
894
+ "enable",
895
+ 542259685031634,
896
+ "randomize",
897
+ 20,
898
+ 2,
899
+ "euler",
900
+ "sgm_uniform",
901
+ 3,
902
+ 10000,
903
+ "disable",
904
+ 5,
905
+ 16,
906
+ 0.15,
907
+ 1,
908
+ 15,
909
+ "Image First",
910
+ 1,
911
+ "LanPaint KSampler Adv. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!"
912
+ ]
913
+ },
914
+ {
915
+ "id": 82,
916
+ "type": "Note",
917
+ "pos": [
918
+ 1722.8084716796875,
919
+ -428.4427185058594
920
+ ],
921
+ "size": [
922
+ 370,
923
+ 120
924
+ ],
925
+ "flags": {},
926
+ "order": 11,
927
+ "mode": 0,
928
+ "inputs": [],
929
+ "outputs": [],
930
+ "title": "Acceleration tip",
931
+ "properties": {
932
+ "widget_ue_connectable": {}
933
+ },
934
+ "widgets_values": [
935
+ "Reduce LanPaint NumSteps for faster generation!"
936
+ ],
937
+ "color": "#432",
938
+ "bgcolor": "#653"
939
+ },
940
+ {
941
+ "id": 83,
942
+ "type": "Note",
943
+ "pos": [
944
+ 1736.30029296875,
945
+ 592.1900024414062
946
+ ],
947
+ "size": [
948
+ 370,
949
+ 120
950
+ ],
951
+ "flags": {},
952
+ "order": 12,
953
+ "mode": 0,
954
+ "inputs": [],
955
+ "outputs": [],
956
+ "title": "Acceleration tip",
957
+ "properties": {
958
+ "widget_ue_connectable": {}
959
+ },
960
+ "widgets_values": [
961
+ "Increase LanPaint Early Stop for faster generation!"
962
+ ],
963
+ "color": "#432",
964
+ "bgcolor": "#653"
965
+ },
966
+ {
967
+ "id": 6,
968
+ "type": "CLIPTextEncode",
969
+ "pos": [
970
+ 420,
971
+ 280
972
+ ],
973
+ "size": [
974
+ 425.4649963378906,
975
+ 225.1785888671875
976
+ ],
977
+ "flags": {},
978
+ "order": 16,
979
+ "mode": 0,
980
+ "inputs": [
981
+ {
982
+ "name": "clip",
983
+ "type": "CLIP",
984
+ "link": 74
985
+ }
986
+ ],
987
+ "outputs": [
988
+ {
989
+ "name": "CONDITIONING",
990
+ "type": "CONDITIONING",
991
+ "slot_index": 0,
992
+ "links": [
993
+ 151,
994
+ 160
995
+ ]
996
+ }
997
+ ],
998
+ "title": "CLIP Text Encode (Positive Prompt)",
999
+ "properties": {
1000
+ "cnr_id": "comfy-core",
1001
+ "ver": "0.3.45",
1002
+ "Node name for S&R": "CLIPTextEncode",
1003
+ "widget_ue_connectable": {}
1004
+ },
1005
+ "widgets_values": [
1006
+ "Close up Portrait of a futuristic cowgirl wearing jeans rides a mechanical horse across a vast cyberpunk desert. The dunes shimmer with holographic projections, glowing in blues and purples. cacti and two massive moons hang low on the horizon, illuminating the dusty air. Cyberpunk western fusion, cinematic, 8K, highly detailed, atmospheric perspective, Blade Runner style."
1007
+ ],
1008
+ "color": "#232",
1009
+ "bgcolor": "#353"
1010
+ },
1011
+ {
1012
+ "id": 69,
1013
+ "type": "LoadImage",
1014
+ "pos": [
1015
+ 38.325469970703125,
1016
+ 964.1947021484375
1017
+ ],
1018
+ "size": [
1019
+ 274.080078125,
1020
+ 314
1021
+ ],
1022
+ "flags": {},
1023
+ "order": 13,
1024
+ "mode": 0,
1025
+ "inputs": [],
1026
+ "outputs": [
1027
+ {
1028
+ "name": "IMAGE",
1029
+ "type": "IMAGE",
1030
+ "links": [
1031
+ 143
1032
+ ]
1033
+ },
1034
+ {
1035
+ "name": "MASK",
1036
+ "type": "MASK",
1037
+ "links": [
1038
+ 149
1039
+ ]
1040
+ }
1041
+ ],
1042
+ "properties": {
1043
+ "cnr_id": "comfy-core",
1044
+ "ver": "0.3.59",
1045
+ "Node name for S&R": "LoadImage"
1046
+ },
1047
+ "widgets_values": [
1048
+ "Masked_Load_Me_in_Loader (8).png",
1049
+ "image"
1050
+ ]
1051
+ }
1052
+ ],
1053
+ "links": [
1054
+ [
1055
+ 74,
1056
+ 38,
1057
+ 0,
1058
+ 6,
1059
+ 0,
1060
+ "CLIP"
1061
+ ],
1062
+ [
1063
+ 75,
1064
+ 38,
1065
+ 0,
1066
+ 7,
1067
+ 0,
1068
+ "CLIP"
1069
+ ],
1070
+ [
1071
+ 76,
1072
+ 39,
1073
+ 0,
1074
+ 8,
1075
+ 1,
1076
+ "VAE"
1077
+ ],
1078
+ [
1079
+ 110,
1080
+ 37,
1081
+ 0,
1082
+ 54,
1083
+ 0,
1084
+ "MODEL"
1085
+ ],
1086
+ [
1087
+ 112,
1088
+ 56,
1089
+ 0,
1090
+ 55,
1091
+ 0,
1092
+ "MODEL"
1093
+ ],
1094
+ [
1095
+ 142,
1096
+ 8,
1097
+ 0,
1098
+ 70,
1099
+ 0,
1100
+ "IMAGE"
1101
+ ],
1102
+ [
1103
+ 143,
1104
+ 69,
1105
+ 0,
1106
+ 71,
1107
+ 0,
1108
+ "IMAGE"
1109
+ ],
1110
+ [
1111
+ 146,
1112
+ 39,
1113
+ 0,
1114
+ 71,
1115
+ 1,
1116
+ "VAE"
1117
+ ],
1118
+ [
1119
+ 148,
1120
+ 71,
1121
+ 0,
1122
+ 74,
1123
+ 0,
1124
+ "LATENT"
1125
+ ],
1126
+ [
1127
+ 149,
1128
+ 69,
1129
+ 1,
1130
+ 74,
1131
+ 1,
1132
+ "MASK"
1133
+ ],
1134
+ [
1135
+ 150,
1136
+ 54,
1137
+ 0,
1138
+ 75,
1139
+ 0,
1140
+ "MODEL"
1141
+ ],
1142
+ [
1143
+ 151,
1144
+ 6,
1145
+ 0,
1146
+ 75,
1147
+ 1,
1148
+ "CONDITIONING"
1149
+ ],
1150
+ [
1151
+ 152,
1152
+ 7,
1153
+ 0,
1154
+ 75,
1155
+ 2,
1156
+ "CONDITIONING"
1157
+ ],
1158
+ [
1159
+ 154,
1160
+ 67,
1161
+ 0,
1162
+ 75,
1163
+ 4,
1164
+ "INT"
1165
+ ],
1166
+ [
1167
+ 155,
1168
+ 65,
1169
+ 0,
1170
+ 75,
1171
+ 5,
1172
+ "COMBO"
1173
+ ],
1174
+ [
1175
+ 156,
1176
+ 66,
1177
+ 0,
1178
+ 75,
1179
+ 6,
1180
+ "COMBO"
1181
+ ],
1182
+ [
1183
+ 157,
1184
+ 68,
1185
+ 0,
1186
+ 75,
1187
+ 7,
1188
+ "INT"
1189
+ ],
1190
+ [
1191
+ 159,
1192
+ 55,
1193
+ 0,
1194
+ 76,
1195
+ 0,
1196
+ "MODEL"
1197
+ ],
1198
+ [
1199
+ 160,
1200
+ 6,
1201
+ 0,
1202
+ 76,
1203
+ 1,
1204
+ "CONDITIONING"
1205
+ ],
1206
+ [
1207
+ 161,
1208
+ 7,
1209
+ 0,
1210
+ 76,
1211
+ 2,
1212
+ "CONDITIONING"
1213
+ ],
1214
+ [
1215
+ 162,
1216
+ 76,
1217
+ 0,
1218
+ 8,
1219
+ 0,
1220
+ "LATENT"
1221
+ ],
1222
+ [
1223
+ 163,
1224
+ 67,
1225
+ 0,
1226
+ 76,
1227
+ 4,
1228
+ "INT"
1229
+ ],
1230
+ [
1231
+ 164,
1232
+ 65,
1233
+ 0,
1234
+ 76,
1235
+ 5,
1236
+ "COMBO"
1237
+ ],
1238
+ [
1239
+ 165,
1240
+ 66,
1241
+ 0,
1242
+ 76,
1243
+ 6,
1244
+ "COMBO"
1245
+ ],
1246
+ [
1247
+ 166,
1248
+ 68,
1249
+ 0,
1250
+ 76,
1251
+ 7,
1252
+ "INT"
1253
+ ],
1254
+ [
1255
+ 167,
1256
+ 74,
1257
+ 0,
1258
+ 75,
1259
+ 3,
1260
+ "LATENT"
1261
+ ],
1262
+ [
1263
+ 172,
1264
+ 75,
1265
+ 0,
1266
+ 76,
1267
+ 3,
1268
+ "LATENT"
1269
+ ]
1270
+ ],
1271
+ "groups": [
1272
+ {
1273
+ "id": 1,
1274
+ "title": "Step1 - Load models",
1275
+ "bounding": [
1276
+ 20,
1277
+ -150,
1278
+ 371.0310363769531,
1279
+ 571.3974609375
1280
+ ],
1281
+ "color": "#3f789e",
1282
+ "font_size": 24,
1283
+ "flags": {}
1284
+ },
1285
+ {
1286
+ "id": 2,
1287
+ "title": "Step 1: Image size",
1288
+ "bounding": [
1289
+ 20,
1290
+ 450,
1291
+ 367.5572814941406,
1292
+ 222.82713317871094
1293
+ ],
1294
+ "color": "#3f789e",
1295
+ "font_size": 24,
1296
+ "flags": {}
1297
+ },
1298
+ {
1299
+ "id": 3,
1300
+ "title": "Step3 Prompt",
1301
+ "bounding": [
1302
+ 410,
1303
+ 210,
1304
+ 445.27801513671875,
1305
+ 464.2060852050781
1306
+ ],
1307
+ "color": "#3f789e",
1308
+ "font_size": 24,
1309
+ "flags": {}
1310
+ }
1311
+ ],
1312
+ "config": {},
1313
+ "extra": {
1314
+ "ds": {
1315
+ "scale": 0.4241196229884343,
1316
+ "offset": [
1317
+ 228.44262760495175,
1318
+ 461.85293161095177
1319
+ ]
1320
+ },
1321
+ "frontendVersion": "1.25.11",
1322
+ "VHS_latentpreview": false,
1323
+ "VHS_latentpreviewrate": 0,
1324
+ "VHS_MetadataImage": true,
1325
+ "VHS_KeepIntermediate": true,
1326
+ "ue_links": [],
1327
+ "links_added_by_ue": []
1328
+ },
1329
+ "version": 0.4
1330
+ }
LanPaint/example_workflows/wan2_2_T2I_Partial_Inpaint.jpg ADDED

Git LFS Details

  • SHA256: 4a3305c24fa1e2d426f36103c4a8be9581944910c651f3d6bbcadf36419d9310
  • Pointer size: 131 Bytes
  • Size of remote file: 704 kB
LanPaint/example_workflows/wan2_2_T2I_Partial_Inpaint.json ADDED
@@ -0,0 +1,1128 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": "26bf2769-956f-4cee-b5f6-a57a366c9101",
3
+ "revision": 0,
4
+ "last_node_id": 84,
5
+ "last_link_id": 181,
6
+ "nodes": [
7
+ {
8
+ "id": 56,
9
+ "type": "UNETLoader",
10
+ "pos": [
11
+ 34.70310592651367,
12
+ 57.175601959228516
13
+ ],
14
+ "size": [
15
+ 346.7470703125,
16
+ 82
17
+ ],
18
+ "flags": {},
19
+ "order": 0,
20
+ "mode": 0,
21
+ "inputs": [],
22
+ "outputs": [
23
+ {
24
+ "name": "MODEL",
25
+ "type": "MODEL",
26
+ "slot_index": 0,
27
+ "links": [
28
+ 112
29
+ ]
30
+ }
31
+ ],
32
+ "properties": {
33
+ "cnr_id": "comfy-core",
34
+ "ver": "0.3.45",
35
+ "Node name for S&R": "UNETLoader",
36
+ "models": [
37
+ {
38
+ "name": "wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors",
39
+ "url": "https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/diffusion_models/wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors",
40
+ "directory": "diffusion_models"
41
+ }
42
+ ],
43
+ "widget_ue_connectable": {}
44
+ },
45
+ "widgets_values": [
46
+ "wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors",
47
+ "default"
48
+ ]
49
+ },
50
+ {
51
+ "id": 54,
52
+ "type": "ModelSamplingSD3",
53
+ "pos": [
54
+ 640,
55
+ -70
56
+ ],
57
+ "size": [
58
+ 210,
59
+ 60
60
+ ],
61
+ "flags": {},
62
+ "order": 15,
63
+ "mode": 0,
64
+ "inputs": [
65
+ {
66
+ "name": "model",
67
+ "type": "MODEL",
68
+ "link": 110
69
+ }
70
+ ],
71
+ "outputs": [
72
+ {
73
+ "name": "MODEL",
74
+ "type": "MODEL",
75
+ "slot_index": 0,
76
+ "links": []
77
+ }
78
+ ],
79
+ "properties": {
80
+ "cnr_id": "comfy-core",
81
+ "ver": "0.3.45",
82
+ "Node name for S&R": "ModelSamplingSD3",
83
+ "widget_ue_connectable": {}
84
+ },
85
+ "widgets_values": [
86
+ 1
87
+ ]
88
+ },
89
+ {
90
+ "id": 55,
91
+ "type": "ModelSamplingSD3",
92
+ "pos": [
93
+ 640,
94
+ 60
95
+ ],
96
+ "size": [
97
+ 210,
98
+ 58
99
+ ],
100
+ "flags": {},
101
+ "order": 14,
102
+ "mode": 0,
103
+ "inputs": [
104
+ {
105
+ "name": "model",
106
+ "type": "MODEL",
107
+ "link": 112
108
+ }
109
+ ],
110
+ "outputs": [
111
+ {
112
+ "name": "MODEL",
113
+ "type": "MODEL",
114
+ "slot_index": 0,
115
+ "links": [
116
+ 159
117
+ ]
118
+ }
119
+ ],
120
+ "properties": {
121
+ "cnr_id": "comfy-core",
122
+ "ver": "0.3.45",
123
+ "Node name for S&R": "ModelSamplingSD3",
124
+ "widget_ue_connectable": {}
125
+ },
126
+ "widgets_values": [
127
+ 1
128
+ ]
129
+ },
130
+ {
131
+ "id": 62,
132
+ "type": "MarkdownNote",
133
+ "pos": [
134
+ -480,
135
+ -120
136
+ ],
137
+ "size": [
138
+ 480,
139
+ 350
140
+ ],
141
+ "flags": {},
142
+ "order": 1,
143
+ "mode": 0,
144
+ "inputs": [],
145
+ "outputs": [],
146
+ "title": "Model Links",
147
+ "properties": {
148
+ "widget_ue_connectable": {}
149
+ },
150
+ "widgets_values": [
151
+ "[Tutorial](https://docs.comfy.org/tutorials/video/wan/wan2_2\n) | [教程](https://docs.comfy.org/zh-CN/tutorials/video/wan/wan2_2\n)\n\n**Diffusion Model**\n- [wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors](https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/diffusion_models/wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors)\n- [wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors](https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/diffusion_models/wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors)\n\n**VAE**\n- [wan_2.1_vae.safetensors](https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/vae/wan_2.1_vae.safetensors)\n\n**Text Encoder** \n- [umt5_xxl_fp8_e4m3fn_scaled.safetensors](https://huggingface.co/Comfy-Org/Wan_2.1_ComfyUI_repackaged/resolve/main/split_files/text_encoders/umt5_xxl_fp8_e4m3fn_scaled.safetensors)\n\n\nFile save location\n\n```\nComfyUI/\n├───📂 models/\n│ ├───📂 diffusion_models/\n│ │ ├─── wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors\n│ │ └─── wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors\n│ ├───📂 text_encoders/\n│ │ └─── umt5_xxl_fp8_e4m3fn_scaled.safetensors \n│ └───📂 vae/\n│ └── wan_2.1_vae.safetensors\n```\n"
152
+ ],
153
+ "color": "#432",
154
+ "bgcolor": "#653"
155
+ },
156
+ {
157
+ "id": 7,
158
+ "type": "CLIPTextEncode",
159
+ "pos": [
160
+ 415.27801513671875,
161
+ 562.8309936523438
162
+ ],
163
+ "size": [
164
+ 425.27801513671875,
165
+ 180.6060791015625
166
+ ],
167
+ "flags": {},
168
+ "order": 17,
169
+ "mode": 0,
170
+ "inputs": [
171
+ {
172
+ "name": "clip",
173
+ "type": "CLIP",
174
+ "link": 75
175
+ }
176
+ ],
177
+ "outputs": [
178
+ {
179
+ "name": "CONDITIONING",
180
+ "type": "CONDITIONING",
181
+ "slot_index": 0,
182
+ "links": [
183
+ 161
184
+ ]
185
+ }
186
+ ],
187
+ "title": "CLIP Text Encode (Negative Prompt)",
188
+ "properties": {
189
+ "cnr_id": "comfy-core",
190
+ "ver": "0.3.45",
191
+ "Node name for S&R": "CLIPTextEncode",
192
+ "widget_ue_connectable": {}
193
+ },
194
+ "widgets_values": [
195
+ "色调艳丽,过曝,静态,细节模糊不清,字幕,风格,作品,画作,画面,静止,整体发灰,最差质量,低质量,JPEG压缩残留,丑陋的,残缺的,多余的手指,画得不好的手部,画得不好的脸部,畸形的,毁容的,形态畸形的肢体,手指融合,静止不动的画面,杂乱的背景,三条腿,背景人很多,倒着走"
196
+ ],
197
+ "color": "#322",
198
+ "bgcolor": "#533"
199
+ },
200
+ {
201
+ "id": 59,
202
+ "type": "EmptyHunyuanLatentVideo",
203
+ "pos": [
204
+ 50,
205
+ 530
206
+ ],
207
+ "size": [
208
+ 315,
209
+ 130
210
+ ],
211
+ "flags": {},
212
+ "order": 2,
213
+ "mode": 0,
214
+ "inputs": [],
215
+ "outputs": [
216
+ {
217
+ "name": "LATENT",
218
+ "type": "LATENT",
219
+ "slot_index": 0,
220
+ "links": []
221
+ }
222
+ ],
223
+ "properties": {
224
+ "cnr_id": "comfy-core",
225
+ "ver": "0.3.45",
226
+ "Node name for S&R": "EmptyHunyuanLatentVideo",
227
+ "widget_ue_connectable": {}
228
+ },
229
+ "widgets_values": [
230
+ 768,
231
+ 1344,
232
+ 1,
233
+ 1
234
+ ]
235
+ },
236
+ {
237
+ "id": 37,
238
+ "type": "UNETLoader",
239
+ "pos": [
240
+ 34.225364685058594,
241
+ -71.77911376953125
242
+ ],
243
+ "size": [
244
+ 346.7470703125,
245
+ 82
246
+ ],
247
+ "flags": {},
248
+ "order": 3,
249
+ "mode": 0,
250
+ "inputs": [],
251
+ "outputs": [
252
+ {
253
+ "name": "MODEL",
254
+ "type": "MODEL",
255
+ "slot_index": 0,
256
+ "links": [
257
+ 110
258
+ ]
259
+ }
260
+ ],
261
+ "properties": {
262
+ "cnr_id": "comfy-core",
263
+ "ver": "0.3.45",
264
+ "Node name for S&R": "UNETLoader",
265
+ "models": [
266
+ {
267
+ "name": "wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors",
268
+ "url": "https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/diffusion_models/wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors",
269
+ "directory": "diffusion_models"
270
+ }
271
+ ],
272
+ "widget_ue_connectable": {}
273
+ },
274
+ "widgets_values": [
275
+ "wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors",
276
+ "default"
277
+ ]
278
+ },
279
+ {
280
+ "id": 38,
281
+ "type": "CLIPLoader",
282
+ "pos": [
283
+ 38.86457061767578,
284
+ 189.26513671875
285
+ ],
286
+ "size": [
287
+ 346.391845703125,
288
+ 106
289
+ ],
290
+ "flags": {},
291
+ "order": 4,
292
+ "mode": 0,
293
+ "inputs": [],
294
+ "outputs": [
295
+ {
296
+ "name": "CLIP",
297
+ "type": "CLIP",
298
+ "slot_index": 0,
299
+ "links": [
300
+ 74,
301
+ 75
302
+ ]
303
+ }
304
+ ],
305
+ "properties": {
306
+ "cnr_id": "comfy-core",
307
+ "ver": "0.3.45",
308
+ "Node name for S&R": "CLIPLoader",
309
+ "models": [
310
+ {
311
+ "name": "umt5_xxl_fp8_e4m3fn_scaled.safetensors",
312
+ "url": "https://huggingface.co/Comfy-Org/Wan_2.1_ComfyUI_repackaged/resolve/main/split_files/text_encoders/umt5_xxl_fp8_e4m3fn_scaled.safetensors",
313
+ "directory": "text_encoders"
314
+ }
315
+ ],
316
+ "widget_ue_connectable": {}
317
+ },
318
+ "widgets_values": [
319
+ "umt5_xxl_fp8_e4m3fn_scaled.safetensors",
320
+ "wan",
321
+ "default"
322
+ ]
323
+ },
324
+ {
325
+ "id": 66,
326
+ "type": "PrimitiveNode",
327
+ "pos": [
328
+ 869.0523071289062,
329
+ 458.133544921875
330
+ ],
331
+ "size": [
332
+ 302.1168212890625,
333
+ 106
334
+ ],
335
+ "flags": {},
336
+ "order": 5,
337
+ "mode": 0,
338
+ "inputs": [],
339
+ "outputs": [
340
+ {
341
+ "name": "COMBO",
342
+ "type": "COMBO",
343
+ "widget": {
344
+ "name": "scheduler"
345
+ },
346
+ "links": [
347
+ 165
348
+ ]
349
+ }
350
+ ],
351
+ "title": "Scheduler",
352
+ "properties": {
353
+ "Run widget replace on values": false,
354
+ "widget_ue_connectable": {}
355
+ },
356
+ "widgets_values": [
357
+ "sgm_uniform",
358
+ "fixed",
359
+ ""
360
+ ]
361
+ },
362
+ {
363
+ "id": 71,
364
+ "type": "VAEEncode",
365
+ "pos": [
366
+ 386.7767333984375,
367
+ 924.7274780273438
368
+ ],
369
+ "size": [
370
+ 140,
371
+ 46
372
+ ],
373
+ "flags": {},
374
+ "order": 18,
375
+ "mode": 0,
376
+ "inputs": [
377
+ {
378
+ "name": "pixels",
379
+ "type": "IMAGE",
380
+ "link": 143
381
+ },
382
+ {
383
+ "name": "vae",
384
+ "type": "VAE",
385
+ "link": 146
386
+ }
387
+ ],
388
+ "outputs": [
389
+ {
390
+ "name": "LATENT",
391
+ "type": "LATENT",
392
+ "links": [
393
+ 148
394
+ ]
395
+ }
396
+ ],
397
+ "properties": {
398
+ "cnr_id": "comfy-core",
399
+ "ver": "0.3.59",
400
+ "Node name for S&R": "VAEEncode"
401
+ },
402
+ "widgets_values": []
403
+ },
404
+ {
405
+ "id": 39,
406
+ "type": "VAELoader",
407
+ "pos": [
408
+ 40,
409
+ 350
410
+ ],
411
+ "size": [
412
+ 344.731689453125,
413
+ 59.98149108886719
414
+ ],
415
+ "flags": {},
416
+ "order": 6,
417
+ "mode": 0,
418
+ "inputs": [],
419
+ "outputs": [
420
+ {
421
+ "name": "VAE",
422
+ "type": "VAE",
423
+ "slot_index": 0,
424
+ "links": [
425
+ 76,
426
+ 146
427
+ ]
428
+ }
429
+ ],
430
+ "properties": {
431
+ "cnr_id": "comfy-core",
432
+ "ver": "0.3.45",
433
+ "Node name for S&R": "VAELoader",
434
+ "models": [
435
+ {
436
+ "name": "wan_2.1_vae.safetensors",
437
+ "url": "https://huggingface.co/Comfy-Org/Wan_2.2_ComfyUI_Repackaged/resolve/main/split_files/vae/wan_2.1_vae.safetensors",
438
+ "directory": "vae"
439
+ }
440
+ ],
441
+ "widget_ue_connectable": {}
442
+ },
443
+ "widgets_values": [
444
+ "wan_2.1_vae.safetensors"
445
+ ]
446
+ },
447
+ {
448
+ "id": 70,
449
+ "type": "SaveImage",
450
+ "pos": [
451
+ 1818.5047607421875,
452
+ -71.57525634765625
453
+ ],
454
+ "size": [
455
+ 270,
456
+ 270
457
+ ],
458
+ "flags": {},
459
+ "order": 22,
460
+ "mode": 0,
461
+ "inputs": [
462
+ {
463
+ "name": "images",
464
+ "type": "IMAGE",
465
+ "link": 142
466
+ }
467
+ ],
468
+ "outputs": [],
469
+ "properties": {
470
+ "cnr_id": "comfy-core",
471
+ "ver": "0.3.59"
472
+ },
473
+ "widgets_values": [
474
+ "ComfyUI"
475
+ ]
476
+ },
477
+ {
478
+ "id": 74,
479
+ "type": "SetLatentNoiseMask",
480
+ "pos": [
481
+ 469.00274658203125,
482
+ 822.289306640625
483
+ ],
484
+ "size": [
485
+ 180.74765014648438,
486
+ 46
487
+ ],
488
+ "flags": {},
489
+ "order": 19,
490
+ "mode": 0,
491
+ "inputs": [
492
+ {
493
+ "name": "samples",
494
+ "type": "LATENT",
495
+ "link": 148
496
+ },
497
+ {
498
+ "name": "mask",
499
+ "type": "MASK",
500
+ "link": 149
501
+ }
502
+ ],
503
+ "outputs": [
504
+ {
505
+ "name": "LATENT",
506
+ "type": "LATENT",
507
+ "links": [
508
+ 181
509
+ ]
510
+ }
511
+ ],
512
+ "properties": {
513
+ "cnr_id": "comfy-core",
514
+ "ver": "0.3.59",
515
+ "Node name for S&R": "SetLatentNoiseMask"
516
+ },
517
+ "widgets_values": []
518
+ },
519
+ {
520
+ "id": 8,
521
+ "type": "VAEDecode",
522
+ "pos": [
523
+ 1836.6907958984375,
524
+ -249.27249145507812
525
+ ],
526
+ "size": [
527
+ 210,
528
+ 46
529
+ ],
530
+ "flags": {},
531
+ "order": 21,
532
+ "mode": 0,
533
+ "inputs": [
534
+ {
535
+ "name": "samples",
536
+ "type": "LATENT",
537
+ "link": 162
538
+ },
539
+ {
540
+ "name": "vae",
541
+ "type": "VAE",
542
+ "link": 76
543
+ }
544
+ ],
545
+ "outputs": [
546
+ {
547
+ "name": "IMAGE",
548
+ "type": "IMAGE",
549
+ "slot_index": 0,
550
+ "links": [
551
+ 142
552
+ ]
553
+ }
554
+ ],
555
+ "properties": {
556
+ "cnr_id": "comfy-core",
557
+ "ver": "0.3.45",
558
+ "Node name for S&R": "VAEDecode",
559
+ "widget_ue_connectable": {}
560
+ },
561
+ "widgets_values": []
562
+ },
563
+ {
564
+ "id": 63,
565
+ "type": "Note",
566
+ "pos": [
567
+ 20,
568
+ 720
569
+ ],
570
+ "size": [
571
+ 370,
572
+ 120
573
+ ],
574
+ "flags": {},
575
+ "order": 7,
576
+ "mode": 0,
577
+ "inputs": [],
578
+ "outputs": [],
579
+ "title": "Video Size",
580
+ "properties": {
581
+ "widget_ue_connectable": {}
582
+ },
583
+ "widgets_values": [
584
+ "By default, we set the video to a smaller size for users with low VRAM. If you have enough VRAM, you can change the size"
585
+ ],
586
+ "color": "#432",
587
+ "bgcolor": "#653"
588
+ },
589
+ {
590
+ "id": 82,
591
+ "type": "Note",
592
+ "pos": [
593
+ 1722.8084716796875,
594
+ -428.4427185058594
595
+ ],
596
+ "size": [
597
+ 370,
598
+ 120
599
+ ],
600
+ "flags": {},
601
+ "order": 8,
602
+ "mode": 0,
603
+ "inputs": [],
604
+ "outputs": [],
605
+ "title": "Acceleration tip",
606
+ "properties": {
607
+ "widget_ue_connectable": {}
608
+ },
609
+ "widgets_values": [
610
+ "Reduce LanPaint NumSteps for faster generation!"
611
+ ],
612
+ "color": "#432",
613
+ "bgcolor": "#653"
614
+ },
615
+ {
616
+ "id": 6,
617
+ "type": "CLIPTextEncode",
618
+ "pos": [
619
+ 420,
620
+ 280
621
+ ],
622
+ "size": [
623
+ 425.4649963378906,
624
+ 225.1785888671875
625
+ ],
626
+ "flags": {},
627
+ "order": 16,
628
+ "mode": 0,
629
+ "inputs": [
630
+ {
631
+ "name": "clip",
632
+ "type": "CLIP",
633
+ "link": 74
634
+ }
635
+ ],
636
+ "outputs": [
637
+ {
638
+ "name": "CONDITIONING",
639
+ "type": "CONDITIONING",
640
+ "slot_index": 0,
641
+ "links": [
642
+ 160
643
+ ]
644
+ }
645
+ ],
646
+ "title": "CLIP Text Encode (Positive Prompt)",
647
+ "properties": {
648
+ "cnr_id": "comfy-core",
649
+ "ver": "0.3.45",
650
+ "Node name for S&R": "CLIPTextEncode",
651
+ "widget_ue_connectable": {}
652
+ },
653
+ "widgets_values": [
654
+ "Close up Portrait of a futuristic cowgirl wearing jeans rides a mechanical horse across a vast cyberpunk desert. The dunes shimmer with holographic projections, glowing in blues and purples. cacti and two massive moons hang low on the horizon, illuminating the dusty air. Cyberpunk western fusion, cinematic, 8K, highly detailed, atmospheric perspective, Blade Runner style."
655
+ ],
656
+ "color": "#232",
657
+ "bgcolor": "#353"
658
+ },
659
+ {
660
+ "id": 69,
661
+ "type": "LoadImage",
662
+ "pos": [
663
+ 38.325469970703125,
664
+ 964.1947021484375
665
+ ],
666
+ "size": [
667
+ 274.080078125,
668
+ 314
669
+ ],
670
+ "flags": {},
671
+ "order": 9,
672
+ "mode": 0,
673
+ "inputs": [],
674
+ "outputs": [
675
+ {
676
+ "name": "IMAGE",
677
+ "type": "IMAGE",
678
+ "links": [
679
+ 143
680
+ ]
681
+ },
682
+ {
683
+ "name": "MASK",
684
+ "type": "MASK",
685
+ "links": [
686
+ 149
687
+ ]
688
+ }
689
+ ],
690
+ "properties": {
691
+ "cnr_id": "comfy-core",
692
+ "ver": "0.3.59",
693
+ "Node name for S&R": "LoadImage"
694
+ },
695
+ "widgets_values": [
696
+ "Masked_Load_Me_in_Loader (8).png",
697
+ "image"
698
+ ]
699
+ },
700
+ {
701
+ "id": 65,
702
+ "type": "PrimitiveNode",
703
+ "pos": [
704
+ 871.877197265625,
705
+ 301.2847595214844
706
+ ],
707
+ "size": [
708
+ 304.6064453125,
709
+ 106
710
+ ],
711
+ "flags": {},
712
+ "order": 10,
713
+ "mode": 0,
714
+ "inputs": [],
715
+ "outputs": [
716
+ {
717
+ "name": "COMBO",
718
+ "type": "COMBO",
719
+ "widget": {
720
+ "name": "sampler_name"
721
+ },
722
+ "links": [
723
+ 164
724
+ ]
725
+ }
726
+ ],
727
+ "title": "Sampler",
728
+ "properties": {
729
+ "Run widget replace on values": false,
730
+ "widget_ue_connectable": {}
731
+ },
732
+ "widgets_values": [
733
+ "euler",
734
+ "fixed",
735
+ ""
736
+ ]
737
+ },
738
+ {
739
+ "id": 67,
740
+ "type": "PrimitiveNode",
741
+ "pos": [
742
+ 874.0289916992188,
743
+ 28.25248908996582
744
+ ],
745
+ "size": [
746
+ 312.7867736816406,
747
+ 88.04627990722656
748
+ ],
749
+ "flags": {},
750
+ "order": 11,
751
+ "mode": 0,
752
+ "inputs": [],
753
+ "outputs": [
754
+ {
755
+ "name": "INT",
756
+ "type": "INT",
757
+ "widget": {
758
+ "name": "steps"
759
+ },
760
+ "links": [
761
+ 163
762
+ ]
763
+ }
764
+ ],
765
+ "title": "Steps",
766
+ "properties": {
767
+ "Run widget replace on values": false,
768
+ "widget_ue_connectable": {}
769
+ },
770
+ "widgets_values": [
771
+ 20,
772
+ "fixed"
773
+ ]
774
+ },
775
+ {
776
+ "id": 83,
777
+ "type": "Note",
778
+ "pos": [
779
+ 1736.30029296875,
780
+ 592.1900024414062
781
+ ],
782
+ "size": [
783
+ 370,
784
+ 120
785
+ ],
786
+ "flags": {},
787
+ "order": 12,
788
+ "mode": 0,
789
+ "inputs": [],
790
+ "outputs": [],
791
+ "title": "Acceleration tip",
792
+ "properties": {
793
+ "widget_ue_connectable": {}
794
+ },
795
+ "widgets_values": [
796
+ "Increase LanPaint Early Stop for faster generation!"
797
+ ],
798
+ "color": "#432",
799
+ "bgcolor": "#653"
800
+ },
801
+ {
802
+ "id": 84,
803
+ "type": "Note",
804
+ "pos": [
805
+ 1742.7166748046875,
806
+ 415.5233459472656
807
+ ],
808
+ "size": [
809
+ 370,
810
+ 120
811
+ ],
812
+ "flags": {},
813
+ "order": 13,
814
+ "mode": 0,
815
+ "inputs": [],
816
+ "outputs": [],
817
+ "title": "Partial Inpaint Strength",
818
+ "properties": {
819
+ "widget_ue_connectable": {}
820
+ },
821
+ "widgets_values": [
822
+ "Change Start_at_step to control how much you want inpainting to keep original picture's content"
823
+ ],
824
+ "color": "#432",
825
+ "bgcolor": "#653"
826
+ },
827
+ {
828
+ "id": 76,
829
+ "type": "LanPaint_KSamplerAdvanced",
830
+ "pos": [
831
+ 1276.2220458984375,
832
+ 325.4043884277344
833
+ ],
834
+ "size": [
835
+ 400,
836
+ 764
837
+ ],
838
+ "flags": {},
839
+ "order": 20,
840
+ "mode": 0,
841
+ "inputs": [
842
+ {
843
+ "name": "model",
844
+ "type": "MODEL",
845
+ "link": 159
846
+ },
847
+ {
848
+ "name": "positive",
849
+ "type": "CONDITIONING",
850
+ "link": 160
851
+ },
852
+ {
853
+ "name": "negative",
854
+ "type": "CONDITIONING",
855
+ "link": 161
856
+ },
857
+ {
858
+ "name": "latent_image",
859
+ "type": "LATENT",
860
+ "link": 181
861
+ },
862
+ {
863
+ "name": "steps",
864
+ "type": "INT",
865
+ "widget": {
866
+ "name": "steps"
867
+ },
868
+ "link": 163
869
+ },
870
+ {
871
+ "name": "sampler_name",
872
+ "type": "COMBO",
873
+ "widget": {
874
+ "name": "sampler_name"
875
+ },
876
+ "link": 164
877
+ },
878
+ {
879
+ "name": "scheduler",
880
+ "type": "COMBO",
881
+ "widget": {
882
+ "name": "scheduler"
883
+ },
884
+ "link": 165
885
+ }
886
+ ],
887
+ "outputs": [
888
+ {
889
+ "name": "LATENT",
890
+ "type": "LATENT",
891
+ "links": [
892
+ 162
893
+ ]
894
+ }
895
+ ],
896
+ "properties": {
897
+ "cnr_id": "LanPaint",
898
+ "ver": "1b50a90424318a457ff32a1fd5ee8a441b768b45",
899
+ "Node name for S&R": "LanPaint_KSamplerAdvanced"
900
+ },
901
+ "widgets_values": [
902
+ "enable",
903
+ 542259685031634,
904
+ "fixed",
905
+ 20,
906
+ 2,
907
+ "euler",
908
+ "sgm_uniform",
909
+ 7,
910
+ 10000,
911
+ "disable",
912
+ 5,
913
+ 16,
914
+ 0.15,
915
+ 1,
916
+ 15,
917
+ "Image First",
918
+ 1,
919
+ "LanPaint KSampler Adv. For more info, visit https://github.com/scraed/LanPaint. If you find it useful, please give a star ⭐️!"
920
+ ]
921
+ }
922
+ ],
923
+ "links": [
924
+ [
925
+ 74,
926
+ 38,
927
+ 0,
928
+ 6,
929
+ 0,
930
+ "CLIP"
931
+ ],
932
+ [
933
+ 75,
934
+ 38,
935
+ 0,
936
+ 7,
937
+ 0,
938
+ "CLIP"
939
+ ],
940
+ [
941
+ 76,
942
+ 39,
943
+ 0,
944
+ 8,
945
+ 1,
946
+ "VAE"
947
+ ],
948
+ [
949
+ 110,
950
+ 37,
951
+ 0,
952
+ 54,
953
+ 0,
954
+ "MODEL"
955
+ ],
956
+ [
957
+ 112,
958
+ 56,
959
+ 0,
960
+ 55,
961
+ 0,
962
+ "MODEL"
963
+ ],
964
+ [
965
+ 142,
966
+ 8,
967
+ 0,
968
+ 70,
969
+ 0,
970
+ "IMAGE"
971
+ ],
972
+ [
973
+ 143,
974
+ 69,
975
+ 0,
976
+ 71,
977
+ 0,
978
+ "IMAGE"
979
+ ],
980
+ [
981
+ 146,
982
+ 39,
983
+ 0,
984
+ 71,
985
+ 1,
986
+ "VAE"
987
+ ],
988
+ [
989
+ 148,
990
+ 71,
991
+ 0,
992
+ 74,
993
+ 0,
994
+ "LATENT"
995
+ ],
996
+ [
997
+ 149,
998
+ 69,
999
+ 1,
1000
+ 74,
1001
+ 1,
1002
+ "MASK"
1003
+ ],
1004
+ [
1005
+ 159,
1006
+ 55,
1007
+ 0,
1008
+ 76,
1009
+ 0,
1010
+ "MODEL"
1011
+ ],
1012
+ [
1013
+ 160,
1014
+ 6,
1015
+ 0,
1016
+ 76,
1017
+ 1,
1018
+ "CONDITIONING"
1019
+ ],
1020
+ [
1021
+ 161,
1022
+ 7,
1023
+ 0,
1024
+ 76,
1025
+ 2,
1026
+ "CONDITIONING"
1027
+ ],
1028
+ [
1029
+ 162,
1030
+ 76,
1031
+ 0,
1032
+ 8,
1033
+ 0,
1034
+ "LATENT"
1035
+ ],
1036
+ [
1037
+ 163,
1038
+ 67,
1039
+ 0,
1040
+ 76,
1041
+ 4,
1042
+ "INT"
1043
+ ],
1044
+ [
1045
+ 164,
1046
+ 65,
1047
+ 0,
1048
+ 76,
1049
+ 5,
1050
+ "COMBO"
1051
+ ],
1052
+ [
1053
+ 165,
1054
+ 66,
1055
+ 0,
1056
+ 76,
1057
+ 6,
1058
+ "COMBO"
1059
+ ],
1060
+ [
1061
+ 181,
1062
+ 74,
1063
+ 0,
1064
+ 76,
1065
+ 3,
1066
+ "LATENT"
1067
+ ]
1068
+ ],
1069
+ "groups": [
1070
+ {
1071
+ "id": 1,
1072
+ "title": "Step1 - Load models",
1073
+ "bounding": [
1074
+ 20,
1075
+ -150,
1076
+ 371.0310363769531,
1077
+ 571.3974609375
1078
+ ],
1079
+ "color": "#3f789e",
1080
+ "font_size": 24,
1081
+ "flags": {}
1082
+ },
1083
+ {
1084
+ "id": 2,
1085
+ "title": "Step 1: Image size",
1086
+ "bounding": [
1087
+ 20,
1088
+ 450,
1089
+ 367.5572814941406,
1090
+ 222.82713317871094
1091
+ ],
1092
+ "color": "#3f789e",
1093
+ "font_size": 24,
1094
+ "flags": {}
1095
+ },
1096
+ {
1097
+ "id": 3,
1098
+ "title": "Step3 Prompt",
1099
+ "bounding": [
1100
+ 410,
1101
+ 210,
1102
+ 445.27801513671875,
1103
+ 464.2060852050781
1104
+ ],
1105
+ "color": "#3f789e",
1106
+ "font_size": 24,
1107
+ "flags": {}
1108
+ }
1109
+ ],
1110
+ "config": {},
1111
+ "extra": {
1112
+ "ds": {
1113
+ "scale": 0.48236739945295026,
1114
+ "offset": [
1115
+ 442.47629449189617,
1116
+ -54.01599879799346
1117
+ ]
1118
+ },
1119
+ "frontendVersion": "1.25.11",
1120
+ "VHS_latentpreview": false,
1121
+ "VHS_latentpreviewrate": 0,
1122
+ "VHS_MetadataImage": true,
1123
+ "VHS_KeepIntermediate": true,
1124
+ "ue_links": [],
1125
+ "links_added_by_ue": []
1126
+ },
1127
+ "version": 0.4
1128
+ }