Skip to content

TrainLoraNode: cannot access local variable 'multi_res' where it is not associated with a value #11124

@rodrigoandrigo

Description

@rodrigoandrigo

Custom Node Testing

Expected Behavior

train the lora

Actual Behavior

Image

Steps to Reproduce

run

Image

Debug Logs

loaded completely; 95367431640625005117571072.00 MB usable, 5913.57 MB loaded, full load: True
!!! Exception during processing !!! cannot access local variable 'multi_res' where it is not associated with a value
Traceback (most recent call last):
  File "/home/rodrigoandrigo/Notebooks/ComfyUI/execution.py", line 510, 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 "/home/rodrigoandrigo/Notebooks/ComfyUI/execution.py", line 324, 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 "/home/rodrigoandrigo/Notebooks/ComfyUI/execution.py", line 292, in _async_map_node_over_list
    await process_inputs(input_data_all, 0, input_is_list=input_is_list)
  File "/home/rodrigoandrigo/Notebooks/ComfyUI/execution.py", line 286, in process_inputs
    result = f(**inputs)
             ^^^^^^^^^^^
  File "/home/rodrigoandrigo/Notebooks/ComfyUI/comfy_api/internal/__init__.py", line 149, in wrapped_func
    return method(locked_class, **inputs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/rodrigoandrigo/Notebooks/ComfyUI/comfy_api/latest/_io.py", line 1275, in EXECUTE_NORMALIZED
    to_return = cls.execute(*args, **kwargs)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/rodrigoandrigo/Notebooks/ComfyUI/comfy_extras/nodes_train.py", line 614, in execute
    real_dataset=latents if multi_res else None,
                            ^^^^^^^^^
UnboundLocalError: cannot access local variable 'multi_res' where it is not associated with a value

Other

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Potential BugUser is reporting a bug. This should be tested.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions