Instructions to use Comfy-Org/PixelDiT with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusion Single File
How to use Comfy-Org/PixelDiT with Diffusion Single File:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Notebooks
- Google Colab
- Kaggle
Teal cast on Flux 2 Klein 9B upscales
Howdy!
Been playing with this this morning. Just copy/pasting the subgraph into my various workflows. Works perfectly on Z Image Base and Turbo.
Tried it on Flux 2 Klein 9B (on my slightly tweaked distilled workflow and the stock base comfy template) and I'm getting a teal/green cast to the upscaled image. I've tried the linked pid model and a community member's version of the 2606 model. The 2606 is a little better, but still does it.
Here's what the linked original pid model (flux 2, 1024 -> 4096) looks like.
Any ideas what's going on? The upscale seems to work just fine, it's just the tint that's the issue.
Yeah, ditto. Was looking forward to a fixed Flux.2 version but it's still pretty dire.
It's nothing to do with Klein, by the way; it happens when I encode an image directly too. PiD doesn't really much care what the diffuser before it did, as it's replacing the autoencoder on the output side.
This is a 1:1 image that was generated at 1488^2, that I downscale to 1024^2. So it should be perfectly happy.
Happens as well with the 512->2048 version too:
Compare with the Flux.1 1024->4096 version:
(The Flux.1 512->2048 also looked like crap, but I think that was just because I was downscaling a LOT so the source image was heavily degraded. Flux.1's autoencoder is 64 channels, versus Flux.2's 128, so there's just less room to infer from such a blurry input. At any rate, I don't hold that against PiD.)
I guess the obvious workaround is to decode and re-encode with Flux.1's VAE! 😅 From a technical standpoint it feels kinda cheaty but on a practical one... like, might as well, right?
Two things that can alleviate the color drift, when it's not extreme:
The bias was pretty predictable for the brightness/contrast so I made a node to automatically adjust it back, this was for the initial flux2 version so I'm not sure how well it works with the new one though.
And once close enough, simple color transfer should help as well, we have a node for that in ComfyUI core as well.
Using unsupported aspect ratio definitely makes it worse though (the model only goes up to 9:16 ), as well as using sigmas that deviate from their initial hardcoded schedule (the manual sigmas node that should be in at least my workflows).
Two things that can alleviate the color drift, when it's not extreme:
The bias was pretty predictable for the brightness/contrast so I made a node to automatically adjust it back, this was for the initial flux2 version so I'm not sure how well it works with the new one though.
And once close enough, simple color transfer should help as well, we have a node for that in ComfyUI core as well.Using unsupported aspect ratio definitely makes it worse though (the model only goes up to 9:16 ), as well as using sigmas that deviate from their initial hardcoded schedule (the manual sigmas node that should be in at least my workflows).
Manual sigmas did help, I should say; my results were the result of a bunch of fiddling and trying to get as close to best practices as possible (so 1:1, manual sigmas, fiddling with the prompt content and whatnot to get it consistent.) I'll try these nodes out though, thanks!



