-
Notifications
You must be signed in to change notification settings - Fork 11.5k
Closed
Description
I have a issue where if PIL RGB images are converted to numpy, and then tensor, that SaveImage cannot handle them. The reason is because it's not squeezing the input so it gets an extra shape, it seems.
https://github.com/comfyanonymous/ComfyUI/blob/master/nodes.py#L760
A fix, which still works for all other instances of Save Image that I've been using it for is
i = 255. * image.cpu().numpy().squeeze()Additionally, as a suggestion, it probably would be prudent to make "IMAGE" nodes actually be "TENSOR" nodes, and then have a Tensor to Numpy and Numpy to Tensor node where you then do any image operations on, to cut out all the back and forth conversion constantly. Maybe different colors to differentiate Tensor based nodes and Image based nodes.
Metadata
Metadata
Assignees
Labels
No labels