Automatic1111 Web UI Google Colab NoteBook With All ControlNet Models And More
Added 2023-09-14 23:28:53 +0000 UTCJoin discord and tell me your discord username to get a special rank : SECourses Discord
24 October 2023 Update:
- Fixed xFormers issue
- After Detailer (adetailer) extension install cell added
- Download Google_Colab_Automatic1111_v3.ipynb
- Still only paid tier is supported
- Free users can use our free Kaggle Notebook : https://www.patreon.com/posts/88714330
Currently looks like free tier is getting session terminate but paid tier should work perfectly. The notebook is compatible with free tier too but Google seems like not allowing at least for today (15 September 2023)
Open Google Colab : https://colab.research.google.com/
Click new notebook as in this image : new notebook.png
Download Google_Colab_Automatic1111_v3.ipynb from attachments
Click file > upload notebook > select downloaded notebook file : upload notebook.png
It will ask you leave and click yes
Select T4 GPU and start session and execute cells : connect.png
Make sure that you are connected to the GPU : connected gpu.png
It will give you Gradio Link as below click and start using
The notebook has download options for the following models
- All SD 1.5 based ControlNet models
- All SDXL ControlNet models
- SDXL 1.0
- SDXL 1.0 best VAE
- SD 1.5 best VAE
- SD 1.5 based model Realistic Vision 5.1
- 4x_NMKD-Superscale-SP_178000_G.pth
- All SD 1.5 based ControlNet models
- All SDXL based ControlNet models
- Pixel_Art_XL_1_1.safetensors - LoRA
- Patreon requested models as below
- CyberRealistic_v3_3 from CivitAI
- AbsoluteReality_v181 from CivitAI
- AlbedoBase_XL from CivitAI
So with above logic you can also add any model you want or I can help you to add them
Comments
yes. i think google colab terminates once your browser closed. if you don't want that you need to have like runpod or massed compute. i suggest massed compute
Furkan Gözükara
2024-06-02 21:03:30 +0000 UTCV4 works but I encountered a few issues: If I close the browser, I need to run through all the steps from the beginning every time, right? The model needs to be downloaded each time, correct? I was unable to use textual inversion, hypernetworks, or Lora.
Ton Nattapong
2024-06-02 15:06:13 +0000 UTCupdated v4 let me know if works. also you need a paid colab for this to work
Furkan Gözükara
2024-05-29 17:21:47 +0000 UTCi found error *** Error completing request *** Arguments: ('task(p6oygjro71zaodx)', , 'Over-the-shoulder view of a Thai woman using an iPad, with the iPad screen displaying a solid blue color. The woman has black hair tied in a ponytail, and she is sitting in a modern, well-lit room. The focus is on the iPad, with the woman slightly blurred in the foreground to emphasize the screen.', 'Low resolution, blurry screen, poor lighting, cluttered background, distracting elements, text on screen, black and white', [], 1, 1, 7, 512, 512, False, 0.7, 2, 'Latent', 0, 0, 0, 'Use same checkpoint', 'Use same sampler', 'Use same scheduler', '', '', [], 0, 20, 'DPM++ 2M', 'Automatic', False, '', 0.8, -1, False, -1, 0, 0, 0, False, False, {'ad_model': 'face_yolov8n.pt', 'ad_model_classes': '', 'ad_tap_enable': True, 'ad_prompt': '', 'ad_negative_prompt': '', 'ad_confidence': 0.3, 'ad_mask_k_largest': 0, 'ad_mask_min_ratio': 0, 'ad_mask_max_ratio': 1, 'ad_x_offset': 0, 'ad_y_offset': 0, 'ad_dilate_erode': 4, 'ad_mask_merge_invert': 'None', 'ad_mask_blur': 4, 'ad_denoising_strength': 0.4, 'ad_inpaint_only_masked': True, 'ad_inpaint_only_masked_padding': 32, 'ad_use_inpaint_width_height': False, 'ad_inpaint_width': 512, 'ad_inpaint_height': 512, 'ad_use_steps': False, 'ad_steps': 28, 'ad_use_cfg_scale': False, 'ad_cfg_scale': 7, 'ad_use_checkpoint': False, 'ad_checkpoint': 'Use same checkpoint', 'ad_use_vae': False, 'ad_vae': 'Use same VAE', 'ad_use_sampler': False, 'ad_sampler': 'DPM++ 2M', 'ad_scheduler': 'Use same scheduler', 'ad_use_noise_multiplier': False, 'ad_noise_multiplier': 1, 'ad_use_clip_skip': False, 'ad_clip_skip': 1, 'ad_restore_face': False, 'ad_controlnet_model': 'None', 'ad_controlnet_module': 'None', 'ad_controlnet_weight': 1, 'ad_controlnet_guidance_start': 0, 'ad_controlnet_guidance_end': 1, 'is_api': ()}, {'ad_model': 'None', 'ad_model_classes': '', 'ad_tap_enable': True, 'ad_prompt': '', 'ad_negative_prompt': '', 'ad_confidence': 0.3, 'ad_mask_k_largest': 0, 'ad_mask_min_ratio': 0, 'ad_mask_max_ratio': 1, 'ad_x_offset': 0, 'ad_y_offset': 0, 'ad_dilate_erode': 4, 'ad_mask_merge_invert': 'None', 'ad_mask_blur': 4, 'ad_denoising_strength': 0.4, 'ad_inpaint_only_masked': True, 'ad_inpaint_only_masked_padding': 32, 'ad_use_inpaint_width_height': False, 'ad_inpaint_width': 512, 'ad_inpaint_height': 512, 'ad_use_steps': False, 'ad_steps': 28, 'ad_use_cfg_scale': False, 'ad_cfg_scale': 7, 'ad_use_checkpoint': False, 'ad_checkpoint': 'Use same checkpoint', 'ad_use_vae': False, 'ad_vae': 'Use same VAE', 'ad_use_sampler': False, 'ad_sampler': 'DPM++ 2M', 'ad_scheduler': 'Use same scheduler', 'ad_use_noise_multiplier': False, 'ad_noise_multiplier': 1, 'ad_use_clip_skip': False, 'ad_clip_skip': 1, 'ad_restore_face': False, 'ad_controlnet_model': 'None', 'ad_controlnet_module': 'None', 'ad_controlnet_weight': 1, 'ad_controlnet_guidance_start': 0, 'ad_controlnet_guidance_end': 1, 'is_api': ()}, {'ad_model': 'None', 'ad_model_classes': '', 'ad_tap_enable': True, 'ad_prompt': '', 'ad_negative_prompt': '', 'ad_confidence': 0.3, 'ad_mask_k_largest': 0, 'ad_mask_min_ratio': 0, 'ad_mask_max_ratio': 1, 'ad_x_offset': 0, 'ad_y_offset': 0, 'ad_dilate_erode': 4, 'ad_mask_merge_invert': 'None', 'ad_mask_blur': 4, 'ad_denoising_strength': 0.4, 'ad_inpaint_only_masked': True, 'ad_inpaint_only_masked_padding': 32, 'ad_use_inpaint_width_height': False, 'ad_inpaint_width': 512, 'ad_inpaint_height': 512, 'ad_use_steps': False, 'ad_steps': 28, 'ad_use_cfg_scale': False, 'ad_cfg_scale': 7, 'ad_use_checkpoint': False, 'ad_checkpoint': 'Use same checkpoint', 'ad_use_vae': False, 'ad_vae': 'Use same VAE', 'ad_use_sampler': False, 'ad_sampler': 'DPM++ 2M', 'ad_scheduler': 'Use same scheduler', 'ad_use_noise_multiplier': False, 'ad_noise_multiplier': 1, 'ad_use_clip_skip': False, 'ad_clip_skip': 1, 'ad_restore_face': False, 'ad_controlnet_model': 'None', 'ad_controlnet_module': 'None', 'ad_controlnet_weight': 1, 'ad_controlnet_guidance_start': 0, 'ad_controlnet_guidance_end': 1, 'is_api': ()}, {'ad_model': 'None', 'ad_model_classes': '', 'ad_tap_enable': True, 'ad_prompt': '', 'ad_negative_prompt': '', 'ad_confidence': 0.3, 'ad_mask_k_largest': 0, 'ad_mask_min_ratio': 0, 'ad_mask_max_ratio': 1, 'ad_x_offset': 0, 'ad_y_offset': 0, 'ad_dilate_erode': 4, 'ad_mask_merge_invert': 'None', 'ad_mask_blur': 4, 'ad_denoising_strength': 0.4, 'ad_inpaint_only_masked': True, 'ad_inpaint_only_masked_padding': 32, 'ad_use_inpaint_width_height': False, 'ad_inpaint_width': 512, 'ad_inpaint_height': 512, 'ad_use_steps': False, 'ad_steps': 28, 'ad_use_cfg_scale': False, 'ad_cfg_scale': 7, 'ad_use_checkpoint': False, 'ad_checkpoint': 'Use same checkpoint', 'ad_use_vae': False, 'ad_vae': 'Use same VAE', 'ad_use_sampler': False, 'ad_sampler': 'DPM++ 2M', 'ad_scheduler': 'Use same scheduler', 'ad_use_noise_multiplier': False, 'ad_noise_multiplier': 1, 'ad_use_clip_skip': False, 'ad_clip_skip': 1, 'ad_restore_face': False, 'ad_controlnet_model': 'None', 'ad_controlnet_module': 'None', 'ad_controlnet_weight': 1, 'ad_controlnet_guidance_start': 0, 'ad_controlnet_guidance_end': 1, 'is_api': ()}, ControlNetUnit(is_ui=True, input_mode=, batch_images='', output_dir='', loopback=False, enabled=False, module='none', model='None', weight=1.0, image=None, resize_mode=, low_vram=False, processor_res=-1, threshold_a=-1.0, threshold_b=-1.0, guidance_start=0.0, guidance_end=1.0, pixel_perfect=False, control_mode=, inpaint_crop_input_image=False, hr_option=, save_detected_map=True, advanced_weighting=None, effective_region_mask=None, pulid_mode=, ipadapter_input=None, mask=None, batch_mask_dir=None, animatediff_batch=False, batch_modifiers=[], batch_image_files=[], batch_keyframe_idx=None), ControlNetUnit(is_ui=True, input_mode=, batch_images='', output_dir='', loopback=False, enabled=False, module='none', model='None', weight=1.0, image=None, resize_mode=, low_vram=False, processor_res=-1, threshold_a=-1.0, threshold_b=-1.0, guidance_start=0.0, guidance_end=1.0, pixel_perfect=False, control_mode=, inpaint_crop_input_image=False, hr_option=, save_detected_map=True, advanced_weighting=None, effective_region_mask=None, pulid_mode=, ipadapter_input=None, mask=None, batch_mask_dir=None, animatediff_batch=False, batch_modifiers=[], batch_image_files=[], batch_keyframe_idx=None), ControlNetUnit(is_ui=True, input_mode=, batch_images='', output_dir='', loopback=False, enabled=False, module='none', model='None', weight=1.0, image=None, resize_mode=, low_vram=False, processor_res=-1, threshold_a=-1.0, threshold_b=-1.0, guidance_start=0.0, guidance_end=1.0, pixel_perfect=False, control_mode=, inpaint_crop_input_image=False, hr_option=, save_detected_map=True, advanced_weighting=None, effective_region_mask=None, pulid_mode=, ipadapter_input=None, mask=None, batch_mask_dir=None, animatediff_batch=False, batch_modifiers=[], batch_image_files=[], batch_keyframe_idx=None), False, False, 'positive', 'comma', 0, False, False, 'start', '', 1, '', [], 0, '', [], 0, '', [], True, False, False, False, False, False, False, 0, False, None, None, False, None, None, False, None, None, False, 50) {} Traceback (most recent call last): File "/content/stable-diffusion-webui/modules/call_queue.py", line 57, in f res = list(func(*args, **kwargs)) File "/content/stable-diffusion-webui/modules/call_queue.py", line 36, in f res = func(*args, **kwargs) File "/content/stable-diffusion-webui/modules/txt2img.py", line 109, in txt2img processed = processing.process_images(p) File "/content/stable-diffusion-webui/modules/processing.py", line 845, in process_images res = process_images_inner(p) File "/content/stable-diffusion-webui/extensions/sd-webui-controlnet/scripts/batch_hijack.py", line 59, in processing_process_images_hijack return getattr(processing, '__controlnet_original_process_images_inner')(p, *args, **kwargs) File "/content/stable-diffusion-webui/modules/processing.py", line 981, in process_images_inner samples_ddim = p.sample(conditioning=p.c, unconditional_conditioning=p.uc, seeds=p.seeds, subseeds=p.subseeds, subseed_strength=p.subseed_strength, prompts=p.prompts) File "/content/stable-diffusion-webui/modules/processing.py", line 1328, in sample samples = self.sampler.sample(self, x, conditioning, unconditional_conditioning, image_conditioning=self.txt2img_image_conditioning(x)) File "/content/stable-diffusion-webui/modules/sd_samplers_kdiffusion.py", line 218, in sample samples = self.launch_sampling(steps, lambda: self.func(self.model_wrap_cfg, x, extra_args=self.sampler_extra_args, disable=False, callback=self.callback_state, **extra_params_kwargs)) File "/content/stable-diffusion-webui/modules/sd_samplers_common.py", line 272, in launch_sampling return func() File "/content/stable-diffusion-webui/modules/sd_samplers_kdiffusion.py", line 218, in samples = self.launch_sampling(steps, lambda: self.func(self.model_wrap_cfg, x, extra_args=self.sampler_extra_args, disable=False, callback=self.callback_state, **extra_params_kwargs)) File "/usr/local/lib/python3.10/dist-packages/torch/utils/_contextlib.py", line 115, in decorate_context return func(*args, **kwargs) File "/content/stable-diffusion-webui/repositories/k-diffusion/k_diffusion/sampling.py", line 594, in sample_dpmpp_2m denoised = model(x, sigmas[i] * s_in, **extra_args) File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1501, in _call_impl return forward_call(*args, **kwargs) File "/content/stable-diffusion-webui/modules/sd_samplers_cfg_denoiser.py", line 237, in forward x_out = self.inner_model(x_in, sigma_in, cond=make_condition_dict(cond_in, image_cond_in)) File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1501, in _call_impl return forward_call(*args, **kwargs) File "/content/stable-diffusion-webui/repositories/k-diffusion/k_diffusion/external.py", line 112, in forward eps = self.get_eps(input * c_in, self.sigma_to_t(sigma), **kwargs) File "/content/stable-diffusion-webui/repositories/k-diffusion/k_diffusion/external.py", line 138, in get_eps return self.inner_model.apply_model(*args, **kwargs) File "/content/stable-diffusion-webui/modules/sd_models_xl.py", line 44, in apply_model return self.model(x, t, cond) File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1501, in _call_impl return forward_call(*args, **kwargs) File "/content/stable-diffusion-webui/modules/sd_hijack_utils.py", line 18, in setattr(resolved_obj, func_path[-1], lambda *args, **kwargs: self(*args, **kwargs)) File "/content/stable-diffusion-webui/modules/sd_hijack_utils.py", line 32, in __call__ return self.__orig_func(*args, **kwargs) File "/content/stable-diffusion-webui/repositories/generative-models/sgm/modules/diffusionmodules/wrappers.py", line 28, in forward return self.diffusion_model( File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1501, in _call_impl return forward_call(*args, **kwargs) File "/content/stable-diffusion-webui/modules/sd_unet.py", line 91, in UNetModel_forward return original_forward(self, x, timesteps, context, *args, **kwargs) File "/content/stable-diffusion-webui/repositories/generative-models/sgm/modules/diffusionmodules/openaimodel.py", line 993, in forward h = module(h, emb, context) File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1501, in _call_impl return forward_call(*args, **kwargs) File "/content/stable-diffusion-webui/repositories/generative-models/sgm/modules/diffusionmodules/openaimodel.py", line 100, in forward x = layer(x, context) File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1501, in _call_impl return forward_call(*args, **kwargs) File "/content/stable-diffusion-webui/repositories/generative-models/sgm/modules/attention.py", line 627, in forward x = block(x, context=context[i]) File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1501, in _call_impl return forward_call(*args, **kwargs) File "/content/stable-diffusion-webui/repositories/generative-models/sgm/modules/attention.py", line 459, in forward return checkpoint( File "/content/stable-diffusion-webui/repositories/generative-models/sgm/modules/diffusionmodules/util.py", line 165, in checkpoint return CheckpointFunction.apply(func, len(inputs), *args) File "/usr/local/lib/python3.10/dist-packages/torch/autograd/function.py", line 506, in apply return super().apply(*args, **kwargs) # type: ignore[misc] File "/content/stable-diffusion-webui/repositories/generative-models/sgm/modules/diffusionmodules/util.py", line 182, in forward output_tensors = ctx.run_function(*ctx.input_tensors) File "/content/stable-diffusion-webui/repositories/generative-models/sgm/modules/attention.py", line 467, in _forward self.attn1( File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1501, in _call_impl return forward_call(*args, **kwargs) File "/content/stable-diffusion-webui/modules/sd_hijack_optimizations.py", line 496, in xformers_attention_forward out = xformers.ops.memory_efficient_attention(q, k, v, attn_bias=None, op=get_xformers_flash_attention_op(q, k, v)) File "/usr/local/lib/python3.10/dist-packages/xformers/ops/fmha/__init__.py", line 223, in memory_efficient_attention return _memory_efficient_attention( File "/usr/local/lib/python3.10/dist-packages/xformers/ops/fmha/__init__.py", line 321, in _memory_efficient_attention return _memory_efficient_attention_forward( File "/usr/local/lib/python3.10/dist-packages/xformers/ops/fmha/__init__.py", line 337, in _memory_efficient_attention_forward op = _dispatch_fw(inp, False) File "/usr/local/lib/python3.10/dist-packages/xformers/ops/fmha/dispatch.py", line 120, in _dispatch_fw return _run_priority_list( File "/usr/local/lib/python3.10/dist-packages/xformers/ops/fmha/dispatch.py", line 63, in _run_priority_list raise NotImplementedError(msg) NotImplementedError: No operator found for `memory_efficient_attention_forward` with inputs: query : shape=(2, 1024, 10, 64) (torch.float16) key : shape=(2, 1024, 10, 64) (torch.float16) value : shape=(2, 1024, 10, 64) (torch.float16) attn_bias : p : 0.0 `decoderF` is not supported because: xFormers wasn't build with CUDA support attn_bias type is operator wasn't built - see `python -m xformers.info` for more info `flshattF@0.0.0` is not supported because: xFormers wasn't build with CUDA support requires device with capability > (8, 0) but your GPU has capability (7, 5) (too old) operator wasn't built - see `python -m xformers.info` for more info `tritonflashattF` is not supported because: xFormers wasn't build with CUDA support requires device with capability > (8, 0) but your GPU has capability (7, 5) (too old) operator wasn't built - see `python -m xformers.info` for more info triton is not available requires GPU with sm80 minimum compute capacity, e.g., A100/H100/L4 `cutlassF` is not supported because: xFormers wasn't build with CUDA support operator wasn't built - see `python -m xformers.info` for more info `smallkF` is not supported because: max(query.shape[-1] != value.shape[-1]) > 32 xFormers wasn't build with CUDA support dtype=torch.float16 (supported: {torch.float32}) operator wasn't built - see `python -m xformers.info` for more info unsupported embed per head: 64
Ton Nattapong
2024-05-29 05:30:03 +0000 UTCyou can look our kaggle code and try it : https://www.patreon.com/posts/kohya-sdxl-lora-88397937
Furkan Gözükara
2024-01-31 11:51:51 +0000 UTCHi Furkan... how to use ngrok (more stable) instead of gradio session?
Art
2024-01-31 10:03:32 +0000 UTCyes you need to have a paid colab. use our Kaggle notebook : https://www.patreon.com/posts/run-on-free-like-88714330
Furkan Gözükara
2023-12-05 13:35:36 +0000 UTCRuntime disconnected Your runtime has been disconnected due to executing code that is disallowed in our free of charge tier. Colab subsidizes millions of users and prioritizes interactive programming sessions while disallowing some types of usage as outlined in the FAQ. If you believe this message is in error, file an appeal. Please include any relevant context about your usage. Your compute unit balance is 0. Purchase more To connect to a new runtime, click the connect button below.
Quentin Guittard
2023-12-05 04:44:04 +0000 UTCthey should work. it is great news
Furkan Gözükara
2023-10-24 10:55:32 +0000 UTCHello, I have only been able to check a basic generation with AlbedoBase_XL using text2img and it seems to work, I have not been able to check yet ControlNet etc...
Salvador Robles
2023-10-24 10:36:24 +0000 UTChello fixed. please run and let me know. i don't have paid tier so can't test
Furkan Gözükara
2023-10-24 09:34:10 +0000 UTCHi I was delighted with this colab which was working very well... Yesterday I tried to get in and I got a mistake that I put later. I downloaded it again in case the problem was with my version of the drive version but it wasn't. It would be great to update this colab to avoid the error, thanks.NotImplementedError: No operator found for `memory_efficient_attention_forward` with inputs: query : shape=(2, 4096, 10, 64) (torch.float16) key : shape=(2, 4096, 10, 64) (torch.float16) value : shape=(2, 4096, 10, 64) (torch.float16) attn_bias : p : 0.0 `flshattF` is not supported because: xFormers wasn't build with CUDA support Operator wasn't built - see `python -m xformers.info` for more info `tritonflashattF` is not supported because: xFormers wasn't build with CUDA support requires A100 GPU Only work on pre-MLIR triton for now `cutlassF` is not supported because: xFormers wasn't build with CUDA support Operator wasn't built - see `python -m xformers.info` for more info `smallkF` is not supported because: xFormers wasn't build with CUDA support dtype=torch.float16 (supported: {torch.float32}) max(query.shape[-1] != value.shape[-1]) > 32 Operator wasn't built - see `python -m xformers.info` for more info unsupported embed per head: 64
Salvador Robles
2023-10-24 08:10:42 +0000 UTCwhat you mean by that? you can import this notebook and use it on google colab
Furkan Gözükara
2023-10-16 14:30:16 +0000 UTCHello, thanks for the script, is there a google drive version?
OctonionPrime
2023-10-16 10:24:08 +0000 UTC