VAE Encode (For Inpaint) 'VAE' object has no attribute 'vae_dtype'
Expected Behavior
VAEEncodeForInpaint should not Fail
Actual Behavior
VAEEncodeForInpaint does fail and this error message is displayed :
Steps to Reproduce
Add a node "VAE Encode for Inpainting"
Debug Logs
I got this error
2024-09-10 18:46:41,889 - root - ERROR - Traceback (most recent call last):
File "XXXX\ComfyUI_windows_portable\ComfyUI\execution.py", line 323, in execute
output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "XXXX\ComfyUI_windows_portable\ComfyUI\execution.py", line 198, in get_output_data
return_values = _map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "XXXX\ComfyUI_windows_portable\ComfyUI\execution.py", line 169, in _map_node_over_list
process_inputs(input_dict, i)
File "XXXX\ComfyUI_windows_portable\ComfyUI\execution.py", line 158, in process_inputs
results.append(getattr(obj, func)(**inputs))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "XXXX\ComfyUI_windows_portable\ComfyUI\nodes.py", line 363, in encode
t = vae.encode(pixels)
^^^^^^^^^^^^^^^^^^
File "XXXX\ComfyUI_windows_portable\ComfyUI\comfy\sd.py", line 348, in encode
memory_used = self.memory_used_encode(pixel_samples.shape, self.vae_dtype)
^^^^^^^^^^^^^^
AttributeError: 'VAE' object has no attribute 'vae_dtype'
Other
No response
Sorry I didn't saw the warning message here : WARNING - WARNING: No VAE weights detected, VAE not initalized.
Sorry I didn't saw the warning message here : WARNING - WARNING: No VAE weights detected, VAE not initalized.
hey how did you resolved this issue
同样的问题 请问怎么解决的
The VAE Loader should be used to load VAE Models, not to attempt loading checkpoint models.
Hi, can you explain how to add the safetensors file as a VAE? I’m having trouble following the instructions because I can't download the image—my browser says it’s blocked or missing.
@IL3DCR To add only-VAE safetensors files, you need to place them inside ComfyUI/models/vae folder.
Then you can load them through VAE Loader node.
But if you mean "only a VAE from a Checkpoint", you need to load the entire model through Load Checkpoint and just connect the VAE. Or you can use VAESave node to extract the VAE from the Checkpoint, and then use VAE Loader.
Hi, can you explain how to add the safetensors file as a VAE? I’m having trouble following the instructions because I can't download the image—my browser says it’s blocked or missing.
Talk to ChatGPT, he can help you