WASasquatch / was-node-suite-comfyui

An extensive node suite for ComfyUI with over 210 new nodes
MIT License
1.19k stars 178 forks source link

Image Crop Location resizes the image. #103

Closed Puddz closed 1 year ago

Puddz commented 1 year ago

Maybe that's suppose to happen? but it seems like it adds some pixels when going through the process.

image going in is 1024x2048 and it comes out as 1088x2112

https://files.catbox.moe/1wp5ce.json - simple workflow.

WASasquatch commented 1 year ago

It resizes the crop to a multiple of 64 in case it isn't multiple of 64. But that could probably be 8 instead of 64. Multiples of 8 does have issues with some upscale models though we found out last night.

Puddz commented 1 year ago

But the input of 1024x2048 is a multiple of 64 lol. I'm also cropping in multiples of 64. like 512x512

WASasquatch commented 1 year ago

But the input of 1024x2048 is a multiple of 64 lol. I'm also cropping in multiples of 64. like 512x512

It's cause your crop could be smaller than needed so it adds 64. But I have removed that and people will just crash instead.

Puddz commented 1 year ago

Lol. If youre worred about people crashing and spamming you with errors or whatever, then change it back. Can easily be fixed with just adding a resize node after the crop. Just a bit annoying to have to do that. But maybe it's only a me problem since I'm doing something stupid that requires a lot of cropping.

But thank you for changing it. It works fine now.

WASasquatch commented 1 year ago

Lol. If youre worred about people crashing and spamming you with errors or whatever, then change it back. Can easily be fixed with just adding a resize node after the crop. Just a bit annoying to have to do that. But maybe it's only a me problem since I'm doing something stupid that requires a lot of cropping.

But thank you for changing it. It works fine now.

I should just map the areas pixels when someone selects a location and just be sure it's not too small. Though hopefully multiple of 8 doesn't have a issue. I think it may need to be 32 cause of HAT upscalers and some others that errored out on me. Changing it to 32 allowed HAT to work at odd scales (like 1.5 rather then just 2.0)