LayeredDiffusionDecodeRGBA 'JoinImageWithAlpha' object has no attribute 'join_image_with_alpha'
- Dominant language
- Python
- Stars
- 133k
- Forks
- 15.7k
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 158
Description
### Custom Node Testing
- [x] I have tried disabling custom nodes and the issue persists (see [how to disable custom nodes](https://docs.comfy.org/troubleshooting/custom-node-issues#step-1%3A-test-with-all-custom-nodes-disabled) if you need help)
### Expected Behavior
Generate an image without a background.
### Actual Behavior
No result, error.
### Steps to Reproduce
I used the example workflow.
[layer_diffusion_fg_example_rgba.json](https://github.com/user-attachments/files/23567785/layer_diffusion_fg_example_rgba.json)
### Debug Logs
```powershell
# ComfyUI Error Report
## Error Details
- **Node ID:** 36
- **Node Type:** LayeredDiffusionDecodeRGBA
- **Exception Type:** AttributeError
- **Exception Message:** 'JoinImageWithAlpha' object has no attribute 'join_image_with_alpha'
## Stack Trace
File "C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 496, in execute
output_data, output_ui, has_subgraph, has_pending_tasks = await get_output_data(prompt_id, unique_id, obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb, hidden_inputs=hidden_inputs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 315, in get_output_data
return_values = await _async_map_node_over_list(prompt_id, unique_id, obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb, hidden_inputs=hidden_inputs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 289, in _async_map_node_over_list
await process_inputs(input_dict, i)
File "C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 277, in process_inputs
result = f(**inputs)
^^^^^^^^^^^
File "C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-layerdiffuse\layered_diffusion.py", line 132, in decode
return JoinImageWithAlpha().join_image_with_alpha(image, alpha)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
## System Information
- **ComfyUI Version:** 0.3.66
- **Arguments:** ComfyUI\main.py --fast fp16_accumulation
- **OS:** nt
- **Python Version:** 3.12.10 (tags/v3.12.10:0cc8128, Apr 8 2025, 12:21:36) [MSC v.1943 64 bit (AMD64)]
- **Embedded Python:** true
- **PyTorch Version:** 2.8.0+cu128
## Devices
- **Name:** cuda:0 NVIDIA GeForce GTX 1050 : cudaMallocAsync
- **Type:** cuda
- **VRAM Total:** 4294836224
- **VRAM Free:** 3527357236
- **Torch VRAM Total:** 0
- **Torch VRAM Free:** 0
## Logs
2025-11-16T08:03:08.036923 - [START] Security scan2025-11-16T08:03:08.036923 -
2025-11-16T08:03:10.070653 - [DONE] Security scan2025-11-16T08:03:10.070653 -
2025-11-16T08:03:10.336941 - ## ComfyUI-Manager: installing dependencies done.2025-11-16T08:03:10.336941 -
2025-11-16T08:03:10.337938 - ** ComfyUI startup time:2025-11-16T08:03:10.337938 - 2025-11-16T08:03:10.337938 - 2025-11-16 08:03:10.3362025-11-16T08:03:10.337938 -
2025-11-16T08:03:10.337938 - ** Platform:2025-11-16T08:03:10.340930 - 2025-11-16T08:03:10.340930 - Windows2025-11-16T08:03:10.340930 -
2025-11-16T08:03:10.340930 - ** Python version:2025-11-16T08:03:10.341929 - 2025-11-16T08:03:10.341929 - 3.12.10 (tags/v3.12.10:0cc8128, Apr 8 2025, 12:21:36) [MSC v.1943 64 bit (AMD64)]2025-11-16T08:03:10.341929 -
2025-11-16T08:03:10.341929 - ** Python executable:2025-11-16T08:03:10.342924 - 2025-11-16T08:03:10.342924 - C:\Dev\AI\ComfyUI_windows_portable\python_embeded\python.exe2025-11-16T08:03:10.342924 -
2025-11-16T08:03:10.343922 - ** ComfyUI Path:2025-11-16T08:03:10.343922 - 2025-11-16T08:03:10.343922 - C:\Dev\AI\ComfyUI_windows_portable\ComfyUI2025-11-16T08:03:10.343922 -
2025-11-16T08:03:10.343922 - ** ComfyUI Base Folder Path:2025-11-16T08:03:10.344919 - 2025-11-16T08:03:10.344919 - C:\Dev\AI\ComfyUI_windows_portable\ComfyUI2025-11-16T08:03:10.344919 -
2025-11-16T08:03:10.344919 - ** User directory:2025-11-16T08:03:10.345919 - 2025-11-16T08:03:10.345919 - C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\user2025-11-16T08:03:10.345919 -
2025-11-16T08:03:10.346916 - ** ComfyUI-Manager config path:2025-11-16T08:03:10.346916 - 2025-11-16T08:03:10.346916 - C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\user\default\ComfyUI-Manager\config.ini2025-11-16T08:03:10.346916 -
2025-11-16T08:03:10.347912 - ** Log path:2025-11-16T08:03:10.347912 - 2025-11-16T08:03:10.347912 - C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\user\comfyui.log2025-11-16T08:03:10.347912 -
2025-11-16T08:03:12.423060 -
Prestartup times for custom nodes:
2025-11-16T08:03:12.423060 - 5.1 seconds: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-manager
2025-11-16T08:03:12.424095 -
2025-11-16T08:03:18.105815 - Checkpoint files will always be loaded safely.
2025-11-16T08:03:18.682681 - Total VRAM 4096 MB, total RAM 16252 MB
2025-11-16T08:03:18.682681 - pytorch version: 2.8.0+cu128
2025-11-16T08:03:18.684706 - Enabled fp16 accumulation.
2025-11-16T08:03:18.685675 - Set vram state to: NORMAL_VRAM
2025-11-16T08:03:18.685675 - Device: cuda:0 NVIDIA GeForce GTX 1050 : cudaMallocAsync
2025-11-16T08:03:21.739161 - Using pytorch attention
2025-11-16T08:03:27.307750 - Python version: 3.12.10 (tags/v3.12.10:0cc8128, Apr 8 2025, 12:21:36) [MSC v.1943 64 bit (AMD64)]
2025-11-16T08:03:27.308748 - ComfyUI version: 0.3.66
2025-11-16T08:03:27.375793 - ComfyUI frontend version: 1.28.7
2025-11-16T08:03:27.378772 - [Prompt Server] web root: C:\Dev\AI\ComfyUI_windows_portable\python_embeded\Lib\site-packages\comfyui_frontend_package\static
2025-11-16T08:03:29.572736 - ### Loading: ComfyUI-Impact-Pack (V8.25.1)
2025-11-16T08:03:30.222898 - [Impact Pack] Wildcards loading done.
2025-11-16T08:03:30.235866 - ### Loading: ComfyUI-Impact-Subpack (V1.3.5)
2025-11-16T08:03:30.239852 - [Impact Pack/Subpack] Using folder_paths to determine whitelist path: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\user\default\ComfyUI-Impact-Subpack\model-whitelist.txt
2025-11-16T08:03:30.240850 - [Impact Pack/Subpack] Ensured whitelist directory exists: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\user\default\ComfyUI-Impact-Subpack
2025-11-16T08:03:30.241847 - [Impact Pack/Subpack] Loaded 0 model(s) from whitelist: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\user\default\ComfyUI-Impact-Subpack\model-whitelist.txt
2025-11-16T08:03:30.444931 - [Impact Subpack] ultralytics_bbox: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\models\ultralytics\bbox
2025-11-16T08:03:30.445709 - [Impact Subpack] ultralytics_segm: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\models\ultralytics\segm
2025-11-16T08:03:34.875777 - ### Loading: ComfyUI-Manager (V3.37)
2025-11-16T08:03:34.876774 - [ComfyUI-Manager] network_mode: public
2025-11-16T08:03:35.065030 - ### ComfyUI Revision: 150 [560b1bdf] *DETACHED | Released on '2025-10-21'
2025-11-16T08:03:35.104838 - [36;20m[C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui_controlnet_aux] | INFO -> Using ckpts path: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui_controlnet_aux\ckpts[0m
2025-11-16T08:03:35.105834 - [36;20m[C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui_controlnet_aux] | INFO -> Using symlinks: False[0m
2025-11-16T08:03:35.107860 - [36;20m[C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui_controlnet_aux] | INFO -> Using ort providers: ['CUDAExecutionProvider', 'DirectMLExecutionProvider', 'OpenVINOExecutionProvider', 'ROCMExecutionProvider', 'CPUExecutionProvider', 'CoreMLExecutionProvider'][0m
2025-11-16T08:03:35.202925 - [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/alter-list.json
2025-11-16T08:03:35.220842 - [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/model-list.json
2025-11-16T08:03:35.312639 - [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/github-stats.json
2025-11-16T08:03:35.429958 - [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/extension-node-map.json
2025-11-16T08:03:35.838488 - [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/custom-node-list.json
2025-11-16T08:03:38.221282 - [34mWAS Node Suite: [0mOpenCV Python FFMPEG support is enabled[0m2025-11-16T08:03:38.221282 -
2025-11-16T08:03:38.222164 - [34mWAS Node Suite [93mWarning: [0m`ffmpeg_bin_path` is not set in `C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\was-ns\was_suite_config.json` config file. Will attempt to use system ffmpeg binaries if available.[0m2025-11-16T08:03:38.222164 -
2025-11-16T08:03:39.174252 - [34mWAS Node Suite: [0mFinished.[0m [32mLoaded[0m [0m220[0m [32mnodes successfully.[0m2025-11-16T08:03:39.175250 -
2025-11-16T08:03:39.175250 -
[3m[93m"The purpose of art is washing the dust of daily life off our souls."[0m[3m - Pablo Picasso[0m
2025-11-16T08:03:39.176246 -
2025-11-16T08:03:39.190811 -
Import times for custom nodes:
2025-11-16T08:03:39.191809 - 0.0 seconds: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\websocket_image_save.py
2025-11-16T08:03:39.191809 - 0.0 seconds: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui_ipadapter_plus
2025-11-16T08:03:39.192805 - 0.0 seconds: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui_ultimatesdupscale
2025-11-16T08:03:39.193803 - 0.2 seconds: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-impact-subpack
2025-11-16T08:03:39.193803 - 0.2 seconds: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-manager
2025-11-16T08:03:39.194800 - 0.7 seconds: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-impact-pack
2025-11-16T08:03:39.195797 - 1.5 seconds: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui_controlnet_aux
2025-11-16T08:03:39.196795 - 2.6 seconds: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\was-ns
2025-11-16T08:03:39.196795 - 4.4 seconds: C:\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-layerdiffuse
2025-11-16T08:03:39.197800 -
2025-11-16T08:03:39.853606 - Context impl SQLiteImpl.
2025-11-16T08:03:39.853606 - Will assume non-transactional DDL.
2025-11-16T08:03:39.860589 - No target revision found.
2025-11-16T08:03:39.894556 - Starting server
2025-11-16T08:03:39.895454 - To see the GUI go to: http://127.0.0.1:8188
2025-11-16T08:03:40.030089 - FETCH ComfyRegistry Data: 5/1062025-11-16T08:03:40.031057 -
2025-11-16T08:03:44.580848 - FETCH ComfyRegistry Data: 10/1062025-11-16T08:03:44.580848 -
2025-11-16T08:03:48.224701 - [DEPRECATION WARNING] Detected import of deprecated legacy API: /scripts/ui.js. This is likely caused by a custom node extension using outdated APIs. Please update your extensions or contact the extension author for an updated version.
2025-11-16T08:03:48.229688 - [DEPRECATION WARNING] Detected import of deprecated legacy API: /extensions/core/clipspace.js. This is likely caused by a custom node extension using outdated APIs. Please update your extensions or contact the extension author for an updated version.
2025-11-16T08:03:48.233678 - [DEPRECATION WARNING] Detected import of deprecated legacy API: /extensions/core/groupNode.js. This is likely caused by a custom node extension using outdated APIs. Please update your extensions or contact the extension author for an updated version.
2025-11-16T08:03:48.990682 - FETCH ComfyRegistry Data: 15/1062025-11-16T08:03:48.994666 -
2025-11-16T08:03:49.131058 - [DEPRECATION WARNING] Detected import of deprecated legacy API: /scripts/ui/components/buttonGroup.js. This is likely caused by a custom node extension using outdated APIs. Please update your extensions or contact the extension author for an updated version.
2025-11-16T08:03:49.148012 - [DEPRECATION WARNING] Detected import of deprecated legacy API: /scripts/ui/components/button.js. This is likely caused by a custom node extension using outdated APIs. Please update your extensions or contact the extension author for an updated version.
2025-11-16T08:03:52.988156 - got prompt
2025-11-16T08:03:53.377911 - FETCH ComfyRegistry Data: 20/1062025-11-16T08:03:53.378917 -
2025-11-16T08:03:53.693160 - model weight dtype torch.float16, manual cast: None
2025-11-16T08:03:53.708683 - model_type EPS
2025-11-16T08:03:57.581861 - FETCH ComfyRegistry Data: 25/1062025-11-16T08:03:57.581861 -
2025-11-16T08:04:01.886100 - FETCH ComfyRegistry Data: 30/1062025-11-16T08:04:01.886100 -
2025-11-16T08:04:06.846901 - FETCH ComfyRegistry Data: 35/1062025-11-16T08:04:06.846901 -
2025-11-16T08:04:10.038990 - Using pytorch attention in VAE
2025-11-16T08:04:10.116820 - Using pytorch attention in VAE
2025-11-16T08:04:12.423123 - FETCH ComfyRegistry Data: 40/1062025-11-16T08:04:12.423123 -
2025-11-16T08:04:12.654557 - VAE load device: cuda:0, offload device: cpu, dtype: torch.float32
2025-11-16T08:04:13.156678 - Requested to load SDXLClipModel
2025-11-16T08:04:13.186598 - loaded completely 9.5367431640625e+25 1560.802734375 True
2025-11-16T08:04:13.198129 - CLIP/text encoder model load device: cuda:0, offload device: cpu, current: cuda:0, dtype: torch.float16
2025-11-16T08:04:16.793886 - FETCH ComfyRegistry Data: 45/1062025-11-16T08:04:16.800865 -
2025-11-16T08:04:21.101544 - FETCH ComfyRegistry Data: 50/1062025-11-16T08:04:21.101544 -
2025-11-16T08:04:21.116954 - Requested to load SDXLClipModel
2025-11-16T08:04:24.491724 - loaded completely 1932.7500007629394 1560.802734375 True
2025-11-16T08:04:25.238086 - FETCH ComfyRegistry Data: 55/1062025-11-16T08:04:25.238086 -
2025-11-16T08:04:26.138764 - Requested to load SDXL
2025-11-16T08:04:29.770131 - FETCH ComfyRegistry Data: 60/1062025-11-16T08:04:29.770131 -
2025-11-16T08:04:31.390128 - loaded partially 1908.6248901367187 1908.624885559082 1520
2025-11-16T08:04:31.664904 -
0%| | 0/28 [00:00
Contributor guide
Assessment
This issue has not been assessed yet.