Trying To upscale an image with the core node UpscaleImageWithModel that was upscaled by seedvr2 in the workflow, results in: Input type (struct c10::Half) and bias type (float) should be the same
- Dominant language
- Python
- Stars
- 133k
- Forks
- 15.7k
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 158
Description
### Custom Node Testing
- [ ] I have tried disabling custom nodes and the issue persists (see [how to disable custom nodes](https://docs.comfy.org/troubleshooting/custom-node-issues#step-1%3A-test-with-all-custom-nodes-disabled) if you need help)
### Expected Behavior
I expect the upscaling to work with UpscaleImageWithModel regardless where the image comes from
### Actual Behavior
Error: Input type (struct c10::Half) and bias type (float) should be the same
### Steps to Reproduce
see attached workflow in the debug log. it's simple. Load image. upscale image by seedvr2 using standard setting. upscale the resulting image agin using the core node.
### Debug Logs
```powershell
# ComfyUI Error Report
## Error Details
- **Node ID:** 11
- **Node Type:** ImageUpscaleWithModel
- **Exception Type:** RuntimeError
- **Exception Message:** Input type (struct c10::Half) and bias type (float) should be the same
## Stack Trace
File "E:\ComfyUI_windows_portable_2\ComfyUI\execution.py", line 496, in execute
output_data, output_ui, has_subgraph, has_pending_tasks = await get_output_data(prompt_id, unique_id, obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb, hidden_inputs=hidden_inputs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_windows_portable_2\ComfyUI\execution.py", line 315, in get_output_data
return_values = await _async_map_node_over_list(prompt_id, unique_id, obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb, hidden_inputs=hidden_inputs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_windows_portable_2\ComfyUI\execution.py", line 289, in _async_map_node_over_list
await process_inputs(input_dict, i)
File "E:\ComfyUI_windows_portable_2\ComfyUI\execution.py", line 277, in process_inputs
result = f(**inputs)
File "E:\ComfyUI_windows_portable_2\ComfyUI\comfy_extras\nodes_upscale_model.py", line 69, in upscale
s = comfy.utils.tiled_scale(in_img, lambda a: upscale_model(a), tile_x=tile, tile_y=tile, overlap=overlap, upscale_amount=upscale_model.scale, pbar=pbar)
File "E:\ComfyUI_windows_portable_2\ComfyUI\comfy\utils.py", line 1012, in tiled_scale
return tiled_scale_multidim(samples, function, (tile_y, tile_x), overlap=overlap, upscale_amount=upscale_amount, out_channels=out_channels, output_device=output_device, pbar=pbar)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\utils\_contextlib.py", line 120, in decorate_context
return func(*args, **kwargs)
File "E:\ComfyUI_windows_portable_2\ComfyUI\comfy\utils.py", line 984, in tiled_scale_multidim
ps = function(s_in).to(output_device)
~~~~~~~~^^^^^^
File "E:\ComfyUI_windows_portable_2\ComfyUI\comfy_extras\nodes_upscale_model.py", line 69, in
s = comfy.utils.tiled_scale(in_img, lambda a: upscale_model(a), tile_x=tile, tile_y=tile, overlap=overlap, upscale_amount=upscale_model.scale, pbar=pbar)
~~~~~~~~~~~~~^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\utils\_contextlib.py", line 120, in decorate_context
return func(*args, **kwargs)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\spandrel\__helpers\model_descriptor.py", line 472, in __call__
output = self._call_fn(self.model, image)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\spandrel\__helpers\model_descriptor.py", line 439, in
self._call_fn = call_fn or (lambda model, image: model(image))
~~~~~^^^^^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1773, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1784, in _call_impl
return forward_call(*args, **kwargs)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\spandrel\architectures\ESRGAN\__arch\RRDB.py", line 142, in forward
x = self.model(x)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1773, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1784, in _call_impl
return forward_call(*args, **kwargs)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\container.py", line 244, in forward
input = module(input)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1773, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1784, in _call_impl
return forward_call(*args, **kwargs)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\conv.py", line 548, in forward
return self._conv_forward(input, self.weight, self.bias)
~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\conv.py", line 543, in _conv_forward
return F.conv2d(
~~~~~~~~^
input, weight, bias, self.stride, self.padding, self.dilation, self.groups
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
## System Information
- **ComfyUI Version:** 0.3.59
- **Arguments:** ComfyUI\main.py --windows-standalone-build --use-sage-attention --listen --reserve-vram 0.5 --fast fp16_accumulation
- **OS:** nt
- **Python Version:** 3.13.6 (tags/v3.13.6:4e66535, Aug 6 2025, 14:36:00) [MSC v.1944 64 bit (AMD64)]
- **Embedded Python:** true
- **PyTorch Version:** 2.8.0+cu129
## Devices
- **Name:** cuda:0 NVIDIA GeForce RTX 4060 Ti : cudaMallocAsync
- **Type:** cuda
- **VRAM Total:** 17175150592
- **VRAM Free:** 15962472448
- **Torch VRAM Total:** 0
- **Torch VRAM Free:** 0
## Logs
2025-09-20T00:21:16.315902 -
2025-09-20T00:21:16.316569 - 🎨 Encoding tiles 1-5 / 122025-09-20T00:21:16.316768 -
2025-09-20T00:21:16.569523 - 🎨 Encoding tiles 5-9 / 122025-09-20T00:21:16.570229 -
2025-09-20T00:21:17.100842 - 🎨 Encoding tiles 10-12 / 122025-09-20T00:21:17.101652 -
2025-09-20T00:21:17.318268 - 🎨 Encoding tile 12 / 122025-09-20T00:21:17.319220 -
2025-09-20T00:21:17.342186 - ℹ️ Latents shape: torch.Size([1, 178, 134, 16])2025-09-20T00:21:17.342821 -
2025-09-20T00:21:17.343620 - 📊 After VAE encode:2025-09-20T00:21:17.343730 -
2025-09-20T00:21:17.343820 - 📊 [VRAM] 0.54GB allocated / 1.88GB reserved / Peak: 1.55GB / 12.93GB free / 16.00GB total2025-09-20T00:21:17.343902 -
2025-09-20T00:21:17.343984 - 📊 [RAM] 1.34GB process / 8.08GB others / 54.34GB free / 63.76GB total2025-09-20T00:21:17.344076 -
2025-09-20T00:21:17.344161 - 📊 Memory changes: VRAM +0.02GB2025-09-20T00:21:17.344237 -
2025-09-20T00:21:17.344318 - 📊 Resetting VRAM peak memory statistics2025-09-20T00:21:17.344444 -
2025-09-20T00:21:17.344559 - 🎬 Starting inference upscale...2025-09-20T00:21:17.344635 -
2025-09-20T00:21:17.377136 -
EulerSampler: 0%| | 0/1 [00:00
s = comfy.utils.tiled_scale(in_img, lambda a: upscale_model(a), tile_x=tile, tile_y=tile, overlap=overlap, upscale_amount=upscale_model.scale, pbar=pbar)
~~~~~~~~~~~~~^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\utils\_contextlib.py", line 120, in decorate_context
return func(*args, **kwargs)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\spandrel\__helpers\model_descriptor.py", line 472, in __call__
output = self._call_fn(self.model, image)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\spandrel\__helpers\model_descriptor.py", line 439, in
self._call_fn = call_fn or (lambda model, image: model(image))
~~~~~^^^^^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1773, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1784, in _call_impl
return forward_call(*args, **kwargs)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\spandrel\architectures\ESRGAN\__arch\RRDB.py", line 142, in forward
x = self.model(x)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1773, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1784, in _call_impl
return forward_call(*args, **kwargs)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\container.py", line 244, in forward
input = module(input)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1773, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1784, in _call_impl
return forward_call(*args, **kwargs)
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\conv.py", line 548, in forward
return self._conv_forward(input, self.weight, self.bias)
~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_windows_portable_2\python_embeded\Lib\site-packages\torch\nn\modules\conv.py", line 543, in _conv_forward
return F.conv2d(
~~~~~~~~^
input, weight, bias, self.stride, self.padding, self.dilation, self.groups
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
RuntimeError: Input type (struct c10::Half) and bias type (float) should be the same
2025-09-20T00:21:26.312520 - Prompt executed in 11.39 seconds
## Attached Workflow
Please make sure that workflow does not contain any sensitive information such as API keys or passwords.
{"id":"36beb966-dd53-4013-9fab-b11de25eeb1a","revision":0,"last_node_id":11,"last_link_id":18,"nodes":[{"id":2,"type":"SeedVR2BlockSwap","pos":[-2047.0087890625,-309.7735900878906],"size":[287.7833251953125,82],"flags":{},"order":0,"mode":0,"inputs":[{"localized_name":"blocks_to_swap","name":"blocks_to_swap","type":"INT","widget":{"name":"blocks_to_swap"},"link":null},{"localized_name":"offload_io_components","name":"offload_io_components","type":"BOOLEAN","widget":{"name":"offload_io_components"},"link":null}],"outputs":[{"localized_name":"block_swap_config","name":"block_swap_config","type":"block_swap_config","links":[7]}],"properties":{"aux_id":"numz/ComfyUI-SeedVR2_VideoUpscaler","ver":"d504eeafa6047d72fada54bcb7d4e8aced0596de","Node name for S&R":"SeedVR2BlockSwap","ue_properties":{"widget_ue_connectable":{"blocks_to_swap":true,"offload_io_components":true},"version":"7.1","input_ue_unconnectable":{}}},"widgets_values":[36,false]},{"id":6,"type":"SeedVR2ExtraArgs","pos":[-2055.94189453125,80.65494537353516],"size":[285.263671875,202],"flags":{},"order":1,"mode":0,"inputs":[{"localized_name":"tiled_vae","name":"tiled_vae","type":"BOOLEAN","widget":{"name":"tiled_vae"},"link":null},{"localized_name":"vae_tile_size","name":"vae_tile_size","type":"INT","widget":{"name":"vae_tile_size"},"link":null},{"localized_name":"vae_tile_overlap","name":"vae_tile_overlap","type":"INT","widget":{"name":"vae_tile_overlap"},"link":null},{"localized_name":"preserve_vram","name":"preserve_vram","type":"BOOLEAN","widget":{"name":"preserve_vram"},"link":null},{"localized_name":"cache_model","name":"cache_model","type":"BOOLEAN","widget":{"name":"cache_model"},"link":null},{"localized_name":"enable_debug","name":"enable_debug","type":"BOOLEAN","widget":{"name":"enable_debug"},"link":null},{"localized_name":"device","name":"device","type":"COMBO","widget":{"name":"device"},"link":null}],"outputs":[{"localized_name":"extra_args","name":"extra_args","type":"extra_args","links":[8]}],"properties":{"aux_id":"numz/ComfyUI-SeedVR2_VideoUpscaler","ver":"d504eeafa6047d72fada54bcb7d4e8aced0596de","Node name for S&R":"SeedVR2ExtraArgs","ue_properties":{"widget_ue_connectable":{"tiled_vae":true,"vae_tile_size":true,"vae_tile_overlap":true,"preserve_vram":true,"cache_model":true,"enable_debug":true,"device":true},"version":"7.1","input_ue_unconnectable":{}}},"widgets_values":[true,512,64,false,false,true,"cuda:0"]},{"id":3,"type":"LoadImage","pos":[-2785.675048828125,-279.1000061035156],"size":[270,314],"flags":{},"order":2,"mode":0,"inputs":[{"localized_name":"image","name":"image","type":"COMBO","widget":{"name":"image"},"link":null},{"localized_name":"upload","name":"upload","type":"IMAGEUPLOAD","widget":{"name":"upload"},"link":null}],"outputs":[{"localized_name":"IMAGE","name":"IMAGE","type":"IMAGE","links":[9]},{"localized_name":"MASK","name":"MASK","type":"MASK","links":null}],"properties":{"cnr_id":"comfy-core","ver":"0.3.59","Node name for S&R":"LoadImage","ue_properties":{"widget_ue_connectable":{"image":true,"upload":true},"version":"7.1","input_ue_unconnectable":{}}},"widgets_values":["1.png","image"]},{"id":7,"type":"ImageCASharpening+","pos":[-2487.486572265625,-269.5328063964844],"size":[352.51666259765625,58],"flags":{},"order":4,"mode":0,"inputs":[{"localized_name":"image","name":"image","type":"IMAGE","link":9},{"localized_name":"amount","name":"amount","type":"FLOAT","widget":{"name":"amount"},"link":null}],"outputs":[{"localized_name":"IMAGE","name":"IMAGE","type":"IMAGE","links":[10]}],"properties":{"cnr_id":"comfyui_essentials","ver":"1.1.0","Node name for S&R":"ImageCASharpening+"},"widgets_values":[0.8]},{"id":9,"type":"EsesImageCompare","pos":[-1093.73095703125,-309.39886474609375],"size":[606.0034790039062,668.1715087890625],"flags":{},"order":7,"mode":0,"inputs":[{"localized_name":"image_a","name":"image_a","type":"IMAGE","link":13},{"localized_name":"image_b","name":"image_b","shape":7,"type":"IMAGE","link":18}],"outputs":[{"localized_name":"image_a","name":"image_a","type":"IMAGE","links":null},{"localized_name":"diff_mask","name":"diff_mask","type":"MASK","links":null}],"properties":{"aux_id":"quasiblob/ComfyUI-EsesImageCompare","ver":"c0fc9823d0af3595dae191847e06941be4d16bb7","Node name for S&R":"EsesImageCompare"},"widgets_values":["normal",null],"isManuallyResized":true,"slider_pos":0.12043374563670807},{"id":5,"type":"SeedVR2","pos":[-2047.9072265625,-173.2037353515625],"size":[283.6569519042969,194.8033447265625],"flags":{},"order":5,"mode":0,"inputs":[{"localized_name":"images","name":"images","type":"IMAGE","link":10},{"localized_name":"block_swap_config","name":"block_swap_config","shape":7,"type":"block_swap_config","link":7},{"localized_name":"extra_args","name":"extra_args","shape":7,"type":"extra_args","link":8},{"localized_name":"model","name":"model","type":"COMBO","widget":{"name":"model"},"link":null},{"localized_name":"seed","name":"seed","type":"INT","widget":{"name":"seed"},"link":null},{"localized_name":"new_resolution","name":"new_resolution","type":"INT","widget":{"name":"new_resolution"},"link":null},{"localized_name":"batch_size","name":"batch_size","type":"INT","widget":{"name":"batch_size"},"link":null}],"outputs":[{"localized_name":"image","name":"image","type":"IMAGE","links":[13,17]}],"properties":{"aux_id":"numz/ComfyUI-SeedVR2_VideoUpscaler","ver":"d504eeafa6047d72fada54bcb7d4e8aced0596de","Node name for S&R":"SeedVR2","ue_properties":{"widget_ue_connectable":{"model":true,"seed":true,"new_resolution":true,"batch_size":true},"version":"7.1","input_ue_unconnectable":{}}},"widgets_values":["seedvr2_ema_3b_fp8_e4m3fn.safetensors",1880995968,"randomize",1072,1]},{"id":11,"type":"ImageUpscaleWithModel","pos":[-1488.1632080078125,-59.22515106201172],"size":[221.96665954589844,46],"flags":{},"order":6,"mode":0,"inputs":[{"localized_name":"upscale_model","name":"upscale_model","type":"UPSCALE_MODEL","link":16},{"localized_name":"image","name":"image","type":"IMAGE","link":17}],"outputs":[{"localized_name":"IMAGE","name":"IMAGE","type":"IMAGE","links":[18]}],"properties":{"cnr_id":"comfy-core","ver":"0.3.59","Node name for S&R":"ImageUpscaleWithModel"}},{"id":10,"type":"UpscaleModelLoader","pos":[-1633.8436279296875,-366.5514831542969],"size":[270,58],"flags":{},"order":3,"mode":0,"inputs":[{"localized_name":"model_name","name":"model_name","type":"COMBO","widget":{"name":"model_name"},"link":null}],"outputs":[{"localized_name":"UPSCALE_MODEL","name":"UPSCALE_MODEL","type":"UPSCALE_MODEL","links":[16]}],"properties":{"cnr_id":"comfy-core","ver":"0.3.59","Node name for S&R":"UpscaleModelLoader"},"widgets_values":["2x_PureVision.pth"]}],"links":[[7,2,0,5,1,"block_swap_config"],[8,6,0,5,2,"extra_args"],[9,3,0,7,0,"IMAGE"],[10,7,0,5,0,"IMAGE"],[13,5,0,9,0,"IMAGE"],[16,10,0,11,0,"UPSCALE_MODEL"],[17,5,0,11,1,"IMAGE"],[18,11,0,9,1,"IMAGE"]],"groups":[],"config":{},"extra":{"ue_links":[],"links_added_by_ue":[],"ds":{"scale":1.8224924014140185,"offset":[2081.37859521822,434.8149765112296]}},"version":0.4}
## Additional Context
(Please add any additional context or steps to reproduce the error here)
```
### Other
Not sure if this needs to go here or at the seevr2 repo
Contributor guide
Assessment
This issue has not been assessed yet.