automatic icon indicating copy to clipboard operation
automatic copied to clipboard

[Issue]: Control - "Init image same as control" crashes with ControlNet

Open solsol360 opened this issue 2 years ago • 2 comments

Issue Description

"Init image same as control" crashes with ControlNet. Tested with Canny.

TypeError: image must be passed and be one of PIL image, numpy array, torch tensor, list of PIL images, list of numpy arrays or list of torch tensors, but is <class 'NoneType'>

Replicate: Set Input -> Init image same as control Upload Control Input image Set ControlNet and Processor to Canny Generate

Log: Init_image_sdnext.log

Version Platform Description

2024-02-03 10:01:39,291 | sd | INFO | launch | Starting SD.Next 2024-02-03 10:01:39,293 | sd | INFO | installer | Logger: file="F:\automaticdev\sdnext.log" level=DEBUG size=65 mode=create 2024-02-03 10:01:39,294 | sd | INFO | installer | Python 3.10.11 on Windows 2024-02-03 10:01:39,396 | sd | INFO | installer | Version: app=sd.next updated=2024-02-02 hash=5463768 url=https://github.com/vladmandic/automatic.git/tree/dev 2024-02-03 10:01:39,889 | sd | INFO | installer | Latest published version: 9bf08c5493925b6ddb3451f6a6e00460ca92aedd 2024-01-30T14:29:51Z 2024-02-03 10:01:39,896 | sd | INFO | launch | Platform: arch=AMD64 cpu=AMD64 Family 25 Model 97 Stepping 2, AuthenticAMD system=Windows release=Windows-10-10.0.22631-SP0 python=3.10.11

Relevant log output

2024-02-03 10:02:42,354 | sd | ERROR | run | Control pipeline failed: type=controlnet units=1 error=image must be passed and be one of PIL image, numpy array, torch tensor, list of PIL images, list of numpy arrays or list of torch tensors, but is <class 'NoneType'>
2024-02-03 10:02:42,355 | sd | ERROR | errors | Control: TypeError
2024-02-03 10:02:42,585 | sd | TRACE | run | Control restored pipeline: class=StableDiffusionPipeline
2024-02-03 10:02:42,586 | sd | TRACE | run | Control ready: images=None | Control model: Canny | Control conditioning: 1.0 | Control mode: ControlNet | Control process: ['Canny'] | FreeU: b1=1.2 b2=1.4 s1=0.9 s2=0.2 | Hypertile UNet: 256 | Pipeline: StableDiffusionControlNetImg2ImgPipeline
2024-02-03 10:02:42,587 | sd | TRACE | ui_control | Control received: type=<class 'tuple'> (None, <PIL.Image.Image image mode=RGB size=512x512 at 0x2188BFFDA50>, "Control ready images=None | Control model: Canny | Control conditioning: 1.0 | Control mode: ControlNet | Control process: ['Canny'] | FreeU: b1=1.2 b2=1.4 s1=0.9 s2=0.2 | Hypertile UNet: 256 | Pipeline: StableDiffusionControlNetImg2ImgPipeline", None)

Backend

Diffusers

Branch

Dev

Model

SD 1.5

Acknowledgements

  • [X] I have read the above and searched for existing issues
  • [X] I confirm that this is classified correctly and its not an extension issue

solsol360 avatar Feb 03 '24 08:02 solsol360

This issue also happens when using 'Separate init image'

solsol360 avatar Feb 03 '24 13:02 solsol360

fixed

vladmandic avatar Feb 03 '24 16:02 vladmandic