My Comfyui setup and patches

For others with a DGX Spark thought I would share what works for me and how I got here.

Love your feedback and suggestions for improvements.

After reading a lot of forums, trying settings other posted I kept bumping into one issue or another depending if I was doing video gen, image, switching workflows.

From double memory usage, to not seeing all the free vram and aborting (Wan 2.2 and Flux1 at full quant would randomly do this).
Not unloading models from vram when switching model/workflow
Opposite unloading after every run (so every run was cold).
Huge memory spikes when loading.
OOMS that brick it and force a hard reboot.
These are just a few I encountered trying to get it to run right.

Here is a install script that compiles and updates what is needed, script to start comfyui with the settings I use, and patches I use. https://github.com/Triplany/comfyui-dgx-spark

Cold times are a little slower than other setups but this is stable and bullet proof for me. whether I am doing a whole bunch of pictures or jumping to ltx or wan.

Memory usage stays low and consistent, can easily run flux2 at full quants
For each benchmark I restarted comfyui did cold, warm. stop/start whole thing

Stock Comfyui Templates:
zimage t2i (bf16) Memory use: 43.5gb. Speed: res 1024x1024 cold: 96.17s warm: 43.73s
Flux2.dev t2i (fp8mixed) Memory use: 68gb res 1024x1024 cold: 300.38s warm: 50.14s

LTX 2.3 t2v (fp8) Memory use: 44.73gb. Speed: res 1280x720, duration 5. cold: 179.55s warm 81.83s
Wan2.2 14b t2i (fp8) Memory use: 18gb. Speed: res 640x640, duration 5. cold: 644.75s warn: 565.24

Full Quants:
Flux2-dev (full) w mistal3_small at bf16 Memory Use: 93.80gb Speed: 1024x1024 cold: 407.52s warm: 80.25s
Flux1-dev (full) w t5xxl at fp16 Memory Use: 32.16gb Speed: 1024x1024 image cold: 113.17s warm: 32.61s

There is no crazy spikes on memory use. what I posted above stays constant. rerunning workflow (warm) shows it stays loaded and each additional run is much fast.

Switching Workflow (say flux2 to Wan2.2) properly evicts the old models freeing up memory

Hope this helps another spark user not waste as much time as I did lol.

thanks ! do you have a complete LTX 2.3 workflow - that is working ?

thanks

I just use the built in comfyui templates and they work great for me. make sure you have an image selected for the t2v one lol this actually caught me off guard first time I was like what image it’s text2video. now I just created a default example image so I don’t forget and get the nag.

Are you having specific issues with one of the templates?

a lot ! the nvidia spark is shutting down with no reasons… always…

Looks like most of the problems related to loading models have been fixed in comfy-aimdo 0.3.0 which does compile on ARM.

with my WF i can generate image 1024x1024 pix in 7/8 sec

@deeduckme I am doing a lot more steps 20 vs your only doing 2. I should have added that in my numbers it also makes a big difference.

Anyone not on newest Comfyui

I just downloaded the latest nightly ( I had been running older versions) a lot of work has been done it’s actually really good now out of the box!

Good information here. I have an optimized setup not unlike this one. I updated to the latest comfy-aimdo and it made a huge difference in memory usage. So thanks for that.

I am using ltx-2.3-22b-dev-nvfp4.safetensors and doing about 12 mins for a 20 sec video, not bad, the quality is not too bad