Instructions to use Alissonerdx/EditAnything with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use Alissonerdx/EditAnything with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("Lightricks/LTX-2.3", dtype=torch.bfloat16, device_map="cuda") pipe.load_lora_weights("Alissonerdx/EditAnything") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- Draw Things
RuntimeError: cannot reshape tensor of 0 elements into shape [1, 0, 32, -1] in LTXVEditAnythingLoopingSampler
Hi! First of all, thank you for this amazing workflow.
I'm consistently getting the following error when running the workflow:
RuntimeError: cannot reshape tensor of 0 elements into shape [1, 0, 32, -1] because the unspecified dimension size -1 can be any value and is ambiguous
The exception is raised from the LTXVEditAnythingLoopingSampler node.
I've already ruled out several common causes:
Latest BFSNodes (1.21.1)
Latest KJNodes (1.4.8)
Latest RES4LYF nightly
Latest ComfyUI Manager
Tested with both:
ltx-2.3-22b-dev-Q6_K.gguf
ltx-2-3-22b-dev_transformer_only_fp8_input_scaled.safetensors
Using the recommended Distilled LoRA.
Using the matching Edit Anything .standard and .module files from the same Reference V2 build.
Disabling visual_crossattn produces exactly the same error.
The workflow starts correctly, loads all models and LoRAs, generates the guide and reference latents, and then crashes immediately at the very first diffusion step (0%).
Before the crash, I always see the following warning:
Could not force-load model before ref_attn install (out of memory). Falling back to random init.
ref_attn modules: created=False
Applied 192 ref_attn LoRA deltas
I'm not sure whether this warning is related to the crash or not.
I also found a recent ComfyUI issue describing a very similar error:
https://github.com/Comfy-Org/ComfyUI/issues/15233
The reported error is almost identical (cannot reshape tensor of 0 elements into shape [2, 0, 32, -1]) and seems to be related to LTXAVModel after ComfyUI v0.29.0. I don't know if this workflow is affected by the same underlying issue, but the similarity caught my attention.
Has anyone experienced this, or is there anything else I should check?
Thank you!
Latest BFSNodes is the problem. The flow is based on older.