ComfyUI icon indicating copy to clipboard operation
ComfyUI copied to clipboard

Error occurred when executing KSampler:

Open xueqing0622 opened this issue 2 years ago • 8 comments

Error occurred when executing KSampler:

Expected all tensors to be on the same device, but found at least two devices, cpu and cuda:0! (when checking argument for argument mat1 in method wrapper_CUDA_addmm)

File "F:\ComfyUI\ComfyUI\execution.py", line 153, in recursive_execute output_data, output_ui = get_output_data(obj, input_data_all) File "F:\ComfyUI\ComfyUI\execution.py", line 83, in get_output_data return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True) File "F:\ComfyUI\ComfyUI\execution.py", line 76, in map_node_over_list results.append(getattr(obj, func)(**slice_dict(input_data_all, i))) File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI-Inspire-Pack\inspire\a1111_compat.py", line 74, in sample return common_ksampler(model, seed, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, denoise, noise_mode, incremental_seed_mode=batch_seed_mode, variation_seed=variation_seed, variation_strength=variation_strength) File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI-Inspire-Pack\inspire\a1111_compat.py", line 39, in common_ksampler samples = comfy.sample.sample(model, noise, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI-Impact-Pack\modules\impact\sample_error_enhancer.py", line 22, in informative_sample raise e File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI-Impact-Pack\modules\impact\sample_error_enhancer.py", line 9, in informative_sample return original_sample(*args, **kwargs) # This code helps interpret error messages that occur within exceptions but does not have any impact on other operations. File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 284, in motion_sample return wrap_function_to_inject_xformers_bug_info(orig_comfy_sample)(model, noise, *args, **kwargs) File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\model_utils.py", line 204, in wrapped_function return function_to_wrap(*args, **kwargs) File "F:\ComfyUI\ComfyUI\comfy\sample.py", line 100, in sample samples = sampler.sample(noise, positive_copy, negative_copy, cfg=cfg, latent_image=latent_image, start_step=start_step, last_step=last_step, force_full_denoise=force_full_denoise, denoise_mask=noise_mask, sigmas=sigmas, callback=callback, disable_pbar=disable_pbar, seed=seed) File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI_smZNodes_init_.py", line 129, in KSampler_sample return KSampler_sample(*args, **kwargs) File "F:\ComfyUI\ComfyUI\comfy\samplers.py", line 708, in sample return sample(self.model, noise, positive, negative, cfg, self.device, sampler, sigmas, self.model_options, latent_image=latent_image, denoise_mask=denoise_mask, callback=callback, disable_pbar=disable_pbar, seed=seed) File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI_smZNodes_init.py", line 138, in sample return _sample(*args, **kwargs) File "F:\ComfyUI\ComfyUI\comfy\samplers.py", line 614, in sample samples = sampler.sample(model_wrap, sigmas, extra_args, callback, noise, latent_image, denoise_mask, disable_pbar) File "F:\ComfyUI\ComfyUI\comfy\samplers.py", line 553, in sample samples = self.sampler_function(model_k, noise, sigmas, extra_args=extra_args, callback=k_callback, disable=disable_pbar, **self.extra_options) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\utils_contextlib.py", line 115, in decorate_context return func(*args, **kwargs) File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI_smZNodes\smZNodes.py", line 1013, in sample_dpmpp_2m_alt denoised = model(x, sigmas[i] * s_in, **extra_args) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "F:\ComfyUI\ComfyUI\comfy\samplers.py", line 277, in forward out = self.inner_model(x, sigma, cond=cond, uncond=uncond, cond_scale=cond_scale, model_options=model_options, seed=seed) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in call_impl return forward_call(*args, **kwargs) File "F:\ComfyUI\ComfyUI\comfy\samplers.py", line 267, in forward return self.apply_model(*args, **kwargs) File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI_smZNodes\smZNodes.py", line 876, in apply_model out = super().apply_model(*args, **kwargs) File "F:\ComfyUI\ComfyUI\comfy\samplers.py", line 264, in apply_model out = sampling_function(self.inner_model, x, timestep, uncond, cond, cond_scale, model_options=model_options, seed=seed) File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 634, in sliding_sampling_function cond, uncond = sliding_calc_cond_uncond_batch(model, cond, uncond, x, timestep, model_options) File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 615, in sliding_calc_cond_uncond_batch sub_cond_out, sub_uncond_out = calc_cond_uncond_batch(model, sub_cond, sub_uncond, sub_x, sub_timestep, model_options) File "F:\ComfyUI\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 488, in calc_cond_uncond_batch c['control'] = control.get_control(input_x, timestep, c, len(cond_or_uncond)) File "F:\ComfyUI\ComfyUI\custom_nodes\Steerable-Motion\imports\AdvancedControlNet.py", line 346, in get_control return self.sliding_get_control(x_noisy, t, cond, batched_number) File "F:\ComfyUI\ComfyUI\custom_nodes\Steerable-Motion\imports\AdvancedControlNet.py", line 351, in sliding_get_control control_prev = self.previous_controlnet.get_control(x_noisy, t, cond, batched_number) File "F:\ComfyUI\ComfyUI\custom_nodes\Steerable-Motion\imports\AdvancedControlNet.py", line 346, in get_control return self.sliding_get_control(x_noisy, t, cond, batched_number) File "F:\ComfyUI\ComfyUI\custom_nodes\Steerable-Motion\imports\AdvancedControlNet.py", line 351, in sliding_get_control control_prev = self.previous_controlnet.get_control(x_noisy, t, cond, batched_number) File "F:\ComfyUI\ComfyUI\custom_nodes\Steerable-Motion\imports\AdvancedControlNet.py", line 346, in get_control return self.sliding_get_control(x_noisy, t, cond, batched_number) File "F:\ComfyUI\ComfyUI\custom_nodes\Steerable-Motion\imports\AdvancedControlNet.py", line 351, in sliding_get_control control_prev = self.previous_controlnet.get_control(x_noisy, t, cond, batched_number) File "F:\ComfyUI\ComfyUI\custom_nodes\Steerable-Motion\imports\AdvancedControlNet.py", line 346, in get_control return self.sliding_get_control(x_noisy, t, cond, batched_number) File "F:\ComfyUI\ComfyUI\custom_nodes\Steerable-Motion\imports\AdvancedControlNet.py", line 351, in sliding_get_control control_prev = self.previous_controlnet.get_control(x_noisy, t, cond, batched_number) File "F:\ComfyUI\ComfyUI\custom_nodes\Steerable-Motion\imports\AdvancedControlNet.py", line 346, in get_control return self.sliding_get_control(x_noisy, t, cond, batched_number) File "F:\ComfyUI\ComfyUI\custom_nodes\Steerable-Motion\imports\AdvancedControlNet.py", line 404, in sliding_get_control control = self.control_model(x=x_noisy.to(self.control_model.dtype), hint=self.cond_hint, timesteps=timestep.float(), context=context.to(self.control_model.dtype), y=y) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "F:\ComfyUI\ComfyUI\comfy\cldm\cldm.py", line 287, in forward emb = self.time_embed(t_emb) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\container.py", line 215, in forward input = module(input) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "F:\ComfyUI\python_embeded\lib\site-packages\torch\nn\modules\linear.py", line 114, in forward return F.linear(input, self.weight, self.bias)

xueqing0622 avatar Dec 13 '23 16:12 xueqing0622

+1 - I had to roll back to commit b0aab1e4ea3dfefe09c4f07de0e5237558097e22 to get my comfy working again.

wouterverweirder avatar Dec 14 '23 08:12 wouterverweirder

You need to check theSteerable-Motion, ComfyUI-AnimateDiff-Evolved, and ComfyUI_smZNodes extensions for this.

ltdrdata avatar Dec 14 '23 08:12 ltdrdata

I asked for Steerable-Motion too, because it comes from his workflow! https://github.com/banodoco/Steerable-Motion/blob/main/demo/creative_interpolation_example.json https://github.com/banodoco/Steerable-Motion/issues/13

xueqing0622 avatar Dec 14 '23 09:12 xueqing0622

after update, it works!

xueqing0622 avatar Dec 14 '23 10:12 xueqing0622

+1 and update didnt fix it ERROR:root:!!! Exception during processing !!! ERROR:root:Traceback (most recent call last): File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 153, in recursive_execute output_data, output_ui = get_output_data(obj, input_data_all) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 83, in get_output_data return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 76, in map_node_over_list results.append(getattr(obj, func)(**slice_dict(input_data_all, i))) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\nodes.py", line 1299, in sample return common_ksampler(model, seed, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, denoise=denoise) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\nodes.py", line 1269, in common_ksampler samples = comfy.sample.sample(model, noise, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Impact-Pack\modules\impact\sample_error_enhancer.py", line 22, in informative_sample raise e File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Impact-Pack\modules\impact\sample_error_enhancer.py", line 9, in informative_sample return original_sample(*args, **kwargs) # This code helps interpret error messages that occur within exceptions but does not have any impact on other operations. File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 284, in motion_sample return wrap_function_to_inject_xformers_bug_info(orig_comfy_sample)(model, noise, *args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\model_utils.py", line 205, in wrapped_function return function_to_wrap(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\sample.py", line 100, in sample samples = sampler.sample(noise, positive_copy, negative_copy, cfg=cfg, latent_image=latent_image, start_step=start_step, last_step=last_step, force_full_denoise=force_full_denoise, denoise_mask=noise_mask, sigmas=sigmas, callback=callback, disable_pbar=disable_pbar, seed=seed) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 715, in sample return sample(self.model, noise, positive, negative, cfg, self.device, sampler, sigmas, self.model_options, latent_image=latent_image, denoise_mask=denoise_mask, callback=callback, disable_pbar=disable_pbar, seed=seed) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 621, in sample samples = sampler.sample(model_wrap, sigmas, extra_args, callback, noise, latent_image, denoise_mask, disable_pbar) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 560, in sample samples = self.sampler_function(model_k, noise, sigmas, extra_args=extra_args, callback=k_callback, disable=disable_pbar, **self.extra_options) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\utils_contextlib.py", line 115, in decorate_context return func(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\k_diffusion\sampling.py", line 154, in sample_euler_ancestral denoised = model(x, sigmas[i] * s_in, **extra_args) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 284, in forward out = self.inner_model(x, sigma, cond=cond, uncond=uncond, cond_scale=cond_scale, model_options=model_options, seed=seed) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in call_impl return forward_call(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 274, in forward return self.apply_model(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 271, in apply_model out = sampling_function(self.inner_model, x, timestep, uncond, cond, cond_scale, model_options=model_options, seed=seed) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 634, in sliding_sampling_function cond, uncond = sliding_calc_cond_uncond_batch(model, cond, uncond, x, timestep, model_options) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 615, in sliding_calc_cond_uncond_batch sub_cond_out, sub_uncond_out = calc_cond_uncond_batch(model, sub_cond, sub_uncond, sub_x, sub_timestep, model_options) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 488, in calc_cond_uncond_batch c['control'] = control.get_control(input_x, timestep, c, len(cond_or_uncond)) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 368, in get_control_inject return self.get_control_advanced(x_noisy, t, cond, batched_number) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 572, in get_control_advanced return self.sliding_get_control(x_noisy, t, cond, batched_number) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 577, in sliding_get_control control_prev = self.previous_controlnet.get_control(x_noisy, t, cond, batched_number) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 368, in get_control_inject return self.get_control_advanced(x_noisy, t, cond, batched_number) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 572, in get_control_advanced return self.sliding_get_control(x_noisy, t, cond, batched_number) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 615, in sliding_get_control control = self.control_model(x=x_noisy.to(self.control_model.dtype), hint=self.cond_hint, timesteps=timestep.float(), context=context.to(self.control_model.dtype), y=y) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\cldm\cldm.py", line 287, in forward emb = self.time_embed(t_emb) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\container.py", line 215, in forward input = module(input) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\linear.py", line 114, in forward return F.linear(input, self.weight, self.bias) RuntimeError: Expected all tensors to be on the same device, but found at least two devices, cpu and cuda:0! (when checking argument for argument mat1 in method wrapper_CUDA_addmm)

AossGG avatar Dec 14 '23 14:12 AossGG

你是怎么更新的?

zqlong123 avatar Dec 16 '23 07:12 zqlong123

+1 and update didnt fix it ERROR:root:!!! Exception during processing !!! ERROR:root:Traceback (most recent call last): File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 153, in recursive_execute output_data, output_ui = get_output_data(obj, input_data_all) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 83, in get_output_data return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 76, in map_node_over_list results.append(getattr(obj, func)(**slice_dict(input_data_all, i))) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\nodes.py", line 1299, in sample return common_ksampler(model, seed, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, denoise=denoise) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\nodes.py", line 1269, in common_ksampler samples = comfy.sample.sample(model, noise, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Impact-Pack\modules\impact\sample_error_enhancer.py", line 22, in informative_sample raise e File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Impact-Pack\modules\impact\sample_error_enhancer.py", line 9, in informative_sample return original_sample(*args, **kwargs) # This code helps interpret error messages that occur within exceptions but does not have any impact on other operations. File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 284, in motion_sample return wrap_function_to_inject_xformers_bug_info(orig_comfy_sample)(model, noise, *args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\model_utils.py", line 205, in wrapped_function return function_to_wrap(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\sample.py", line 100, in sample samples = sampler.sample(noise, positive_copy, negative_copy, cfg=cfg, latent_image=latent_image, start_step=start_step, last_step=last_step, force_full_denoise=force_full_denoise, denoise_mask=noise_mask, sigmas=sigmas, callback=callback, disable_pbar=disable_pbar, seed=seed) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 715, in sample return sample(self.model, noise, positive, negative, cfg, self.device, sampler, sigmas, self.model_options, latent_image=latent_image, denoise_mask=denoise_mask, callback=callback, disable_pbar=disable_pbar, seed=seed) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 621, in sample samples = sampler.sample(model_wrap, sigmas, extra_args, callback, noise, latent_image, denoise_mask, disable_pbar) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 560, in sample samples = self.sampler_function(model_k, noise, sigmas, extra_args=extra_args, callback=k_callback, disable=disable_pbar, **self.extra_options) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\utils_contextlib.py", line 115, in decorate_context return func(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\k_diffusion\sampling.py", line 154, in sample_euler_ancestral denoised = model(x, sigmas[i] * s_in, **extra_args) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 284, in forward out = self.inner_model(x, sigma, cond=cond, uncond=uncond, cond_scale=cond_scale, model_options=model_options, seed=seed) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in call_impl return forward_call(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 274, in forward return self.apply_model(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\samplers.py", line 271, in apply_model out = sampling_function(self.inner_model, x, timestep, uncond, cond, cond_scale, model_options=model_options, seed=seed) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 634, in sliding_sampling_function cond, uncond = sliding_calc_cond_uncond_batch(model, cond, uncond, x, timestep, model_options) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 615, in sliding_calc_cond_uncond_batch sub_cond_out, sub_uncond_out = calc_cond_uncond_batch(model, sub_cond, sub_uncond, sub_x, sub_timestep, model_options) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 488, in calc_cond_uncond_batch c['control'] = control.get_control(input_x, timestep, c, len(cond_or_uncond)) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 368, in get_control_inject return self.get_control_advanced(x_noisy, t, cond, batched_number) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 572, in get_control_advanced return self.sliding_get_control(x_noisy, t, cond, batched_number) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 577, in sliding_get_control control_prev = self.previous_controlnet.get_control(x_noisy, t, cond, batched_number) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 368, in get_control_inject return self.get_control_advanced(x_noisy, t, cond, batched_number) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 572, in get_control_advanced return self.sliding_get_control(x_noisy, t, cond, batched_number) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\control\control.py", line 615, in sliding_get_control control = self.control_model(x=x_noisy.to(self.control_model.dtype), hint=self.cond_hint, timesteps=timestep.float(), context=context.to(self.control_model.dtype), y=y) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\ComfyUI\comfy\cldm\cldm.py", line 287, in forward emb = self.time_embed(t_emb) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\container.py", line 215, in forward input = module(input) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl return self._call_impl(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl return forward_call(*args, **kwargs) File "C:\Users\theao\Dev\AI\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\nn\modules\linear.py", line 114, in forward return F.linear(input, self.weight, self.bias) RuntimeError: Expected all tensors to be on the same device, but found at least two devices, cpu and cuda:0! (when checking argument for argument mat1 in method wrapper_CUDA_addmm)

it turns out that I have I have 10G of Vram and wile useing controlNet + animateDiff vid2vid it basses the 10Gs for that it keeps the data on normal RAM and i get the error

AossGG avatar Dec 16 '23 12:12 AossGG

用秋叶启动器 放在comfyui可以更新

xueqing0622 avatar Dec 16 '23 13:12 xueqing0622