ltdrdata / ComfyUI-Impact-Pack

Custom nodes pack for ComfyUI This custom node helps to conveniently enhance images through Detector, Detailer, Upscaler, Pipe, and more.
GNU General Public License v3.0
1.92k stars 188 forks source link

Error when using FaceRestoreWithModel #211

Closed drago87 closed 1 year ago

drago87 commented 1 year ago

I have a AMD Radeon RX 5700 XT with 8gb vram and are on windows 10 Runnin ComfyUI with the

--directml

command

When i use this workflow facedetailer i get this error

Error occurred when executing FaceRestoreWithModel:

Input type (torch.FloatTensor) and weight type (PrivateUse1FloatType) should be the same or input should be a MKLDNN tensor and weight is a dense tensor

File "D:\AI\ComfyUI_AMD\ComfyUI\execution.py", line 152, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
File "D:\AI\ComfyUI_AMD\ComfyUI\execution.py", line 82, in get_output_data
return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
File "D:\AI\ComfyUI_AMD\ComfyUI\execution.py", line 75, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
File "D:\AI\ComfyUI_AMD\ComfyUI\custom_nodes\facerestore\__init__.py", line 145, in restore_face
self.face_helper.get_face_landmarks_5(only_center_face=False, resize=640, eye_dist_threshold=5)
File "D:\AI\ComfyUI_AMD\ComfyUI\custom_nodes\facerestore\facelib\utils\face_restoration_helper.py", line 151, in get_face_landmarks_5
bboxes = self.face_det.detect_faces(input_img)
File "D:\AI\ComfyUI_AMD\ComfyUI\custom_nodes\facerestore\facelib\detection\retinaface\retinaface.py", line 209, in detect_faces
loc, conf, landmarks, priors = self.__detect_faces(image)
File "D:\AI\ComfyUI_AMD\ComfyUI\custom_nodes\facerestore\facelib\detection\retinaface\retinaface.py", line 156, in __detect_faces
loc, conf, landmarks = self(inputs)
File "C:\Users\Drago87\AppData\Local\Programs\Python\Python310\lib\site-packages\torch\nn\modules\module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "D:\AI\ComfyUI_AMD\ComfyUI\custom_nodes\facerestore\facelib\detection\retinaface\retinaface.py", line 121, in forward
out = self.body(inputs)
File "C:\Users\Drago87\AppData\Local\Programs\Python\Python310\lib\site-packages\torch\nn\modules\module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "C:\Users\Drago87\AppData\Local\Programs\Python\Python310\lib\site-packages\torchvision\models\_utils.py", line 69, in forward
x = module(x)
File "C:\Users\Drago87\AppData\Local\Programs\Python\Python310\lib\site-packages\torch\nn\modules\module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "C:\Users\Drago87\AppData\Local\Programs\Python\Python310\lib\site-packages\torch\nn\modules\conv.py", line 463, in forward
return self._conv_forward(input, self.weight, self.bias)
File "C:\Users\Drago87\AppData\Local\Programs\Python\Python310\lib\site-packages\torch\nn\modules\conv.py", line 459, in _conv_forward
return F.conv2d(input, weight, bias, self.stride,
ltdrdata commented 1 year ago

According to the logs, it appears that the functionality of "facerestore" is being executed instead of the "FaceDetailer" in the impact pack. It seems like there might be a conflict with this extension. Please try removing the extension and running it again.