ComfyUI-to-Python-Extension icon indicating copy to clipboard operation
ComfyUI-to-Python-Extension copied to clipboard

Problem with loading models and vae

Open sanuzu opened this issue 2 years ago • 3 comments

image Global Models Cache: Ckpt: [1] taureal (ids: None) Vae: [1] vae-ft-mse-840000-ema-pruned.vae (ids: None) Traceback (most recent call last): File "E:\ComfyUI\workflow_api.py", line 166, in main() File "E:\ComfyUI\workflow_api.py", line 137, in main ksampler_efficient_48 = ksampler_efficient.sample( File "E:\ComfyUI\custom_nodes\efficiency-nodes-comfyui\efficiency_nodes.py", line 693, in sample globals_cleanup(prompt) File "E:\ComfyUI\custom_nodes\efficiency-nodes-comfyui\tsc_utils.py", line 209, in globals_cleanup id_array = [id for id in tup[-1] if str(id) in prompt.keys()] File "E:\ComfyUI\custom_nodes\efficiency-nodes-comfyui\tsc_utils.py", line 209, in id_array = [id for id in tup[-1] if str(id) in prompt.keys()] AttributeError: 'NoneType' object has no attribute 'keys'

OS: Windows

sanuzu avatar Nov 27 '23 03:11 sanuzu

This is hard to troubleshoot without the workflow_api.py file and knowledge of the custom node

pydn avatar Nov 27 '23 23:11 pydn

I discovered the problem being that the generate model name doesnt correct parse ''. Check if your model name (path) contains backlash. For example if you see

 checkpointloadersimple_1 = checkpointloadersimple.load_checkpoint(
            ckpt_name="SDXL\something.safetensors"
        )

change it to

 checkpointloadersimple_1 = checkpointloadersimple.load_checkpoint(
            ckpt_name="SDXL\\something.safetensors"
        )

see if such solves your problem

clifftsung avatar Mar 06 '24 19:03 clifftsung

If that's the issue, I did fix that bug on my fork.

atmaranto avatar Mar 21 '24 19:03 atmaranto