smthemex/ComfyUI_EchoMimic

ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()

liubin79813 opened this issue · 3 comments

视频转视频出现问题,如下,请问大佬,这是什么问题?

got prompt
Failed to validate prompt for output 17:

  • LoadAudio 4:
    • Custom validation failed for node: audio - Invalid audio file: echomimicv2_woman.wav
      Output will be ignored
      invalid prompt: {'type': 'prompt_outputs_failed_validation', 'message': 'Prompt outputs failed validation', 'details': '', 'extra_info': {}}
      got prompt
      ****** refer in EchoMimic V2 mode!******
      loaded temporal unet's pretrained weights from E:\ComfyUI_Mie_V3.0\ComfyUI_Mie_3.0\ComfyUI_Mie_V3.0\ComfyUI\models\echo_mimic\unet ...
      Load motion module params from E:\ComfyUI_Mie_V3.0\ComfyUI_Mie_3.0\ComfyUI_Mie_V3.0\ComfyUI\models\echo_mimic\v2\motion_module.pth
      Loaded 453.20928M-parameter motion module
      ***** start infer video to npy files for drive pose ! *****

0: 640x640 1 person, 18.0ms
Speed: 4.0ms preprocess, 18.0ms inference, 49.6ms postprocess per image at shape (1, 3, 640, 640)
!!! Exception during processing !!! The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
Traceback (most recent call last):
File "E:\ComfyUI_Mie_V3.0\ComfyUI_Mie_3.0\ComfyUI_Mie_V3.0\ComfyUI\execution.py", line 324, in execute
output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_Mie_V3.0\ComfyUI_Mie_3.0\ComfyUI_Mie_V3.0\ComfyUI\execution.py", line 199, in get_output_data
return_values = _map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_Mie_V3.0\ComfyUI_Mie_3.0\ComfyUI_Mie_V3.0\ComfyUI\execution.py", line 170, in _map_node_over_list
process_inputs(input_dict, i)
File "E:\ComfyUI_Mie_V3.0\ComfyUI_Mie_3.0\ComfyUI_Mie_V3.0\ComfyUI\execution.py", line 159, in process_inputs
results.append(getattr(obj, func)(**inputs))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_Mie_V3.0\ComfyUI_Mie_3.0\ComfyUI_Mie_V3.0\ComfyUI\custom_nodes\ComfyUI_EchoMimic\EchoMimic_node.py", line 463, in em_main
output_video=process_video_v2(image, audio_file, width, height, length, seed,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_Mie_V3.0\ComfyUI_Mie_3.0\ComfyUI_Mie_V3.0\ComfyUI\custom_nodes\ComfyUI_EchoMimic\utils.py", line 65, in process_video_v2
_, first_key, first_box_xy = visualizer(np.asarray(input_frames_cv2[0]),None)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_Mie_V3.0\ComfyUI_Mie_3.0\ComfyUI_Mie_V3.0\ComfyUI\custom_nodes\ComfyUI_EchoMimic\src\pose.py", line 105, in call
if not bboxes:
ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()

Prompt executed in 27.92 seconds

Facing the same problem here, any help will be appreciated

yolo未检测到视频里有人物时,导致box无法绘制的bug,我将很快修复它,换而言之,你的视频里有空帧或者跳帧,检测不到人体

YOLO did not detect any characters in the video, which caused the box to fail to draw. I will fix it soon,In other words, if there are empty or skipped frames in your video, the human body cannot be detected

thanks