[Python] ComfyUI error: Expected all tensors to be on the same device, but found at least two...

Discussão em 'Python' iniciado por Stack, Julho 10, 2025.

  1. Stack

    Stack Membro Participativo

    I am trying to train a LoRA in ComfyUI using the modified version of the example workflow for ComfyUI-FluxTrainer (https://github.com/kijai/ComfyUI-FluxTrainer/issues) I found on reddit here (https://www.reddit.com/r/StableDiff...x/tutorial_setup_train_flux1_dev_loras_using/). This is the first version where CUDA has not run out of memory (VRAM 8gb) but I am getting this error:

    Expected all tensors to be on the same device, but found at least two
    devices, cpu and cuda:0!


    There are lots of posts around the web with this error but none that seem to trace back to training a LoRA and all seem to have different solution. Anyone know what the issue might be in this instance?

    Full error log here: https://pastebin.com/rFkQaX5A

    Continue reading...

Compartilhe esta Página