Replies: 1 comment 3 replies
-
not an expert but i'm going to guess that is because the def save_images(self, images, directory, seed, iteration):
i = 255. * images[0].cpu().numpy()
img = Image.fromarray(np.clip(i, 0, 255).astype(np.uint8))
# logic to save it here code untested, but i believe that should get you a lot closer to the existing |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi everyone,
I am trying to build a custom Save-to-Image node. The aim is for the node to additionally take as input:
Here is my code:
I copied most from ComfyUI's own
SaveImage
node.You will easily spot the line
i = 255. * ima...
. The.reshape...
part was added, as I was getting this error otherwise:However, now I produce an output png, that cannot be displayed due to format errors using Windows' Photo app. Using Firefox, the file appears to be 1px wide. ComfyUI's own
SaveImage
andPreviewImage
work fine, leaving me wondering what's going on.Beta Was this translation helpful? Give feedback.
All reactions