Skip to content

peaks[part_idx] list index out of range #382

@HoangTienDuc

Description

@HoangTienDuc

Hi @ganler. Thanks for your awesome work.
I use your openpose coco 368x656 tensorrt model to get human pose.
I am very happy when i tested tried your hyperpose openpose coco 368x656, the speed and acc is very good.
So, i want to create a python script to read your tensorrt coverted model and make prediction.
Base on your sample code, I think i got right heatmap.
Screenshot from 2021-10-13 00-22-10

To get pose keypoints, I followed your postprocessing. But i stuck in your process_paf.

list index out of range
  File "/data/Openpose_trt/hyperpose/Model/openpose/processor.py", line 84, in process_paf
    peaks[part_idx].append(Peak(peak_idx,part_idx,peak_y,peak_x,peak_score))
  File "/data/Openpose_trt/hyperpose/Model/openpose/processor.py", line 59, in process
    humans=self.process_paf(peak_map[0],conf_map[0],paf_map[0])
  File "/data/Openpose_trt/openpose_infer.py", line 181, in <module> (Current frame)
    humans=postprocessor.process(conf_map[0],paf_map[0], 368, 656)

In coco dataset, we have only 19 positions in total (self.n_pos). But the tensorrt output give us 38.

trt outputs:

0:'output_paf:0': (1, 38, 46, 82)
1:'output_conf:0': (1, 19, 46, 82)

So i got below error:

peaks[part_idx] list index out of range

Inference code (base on your infer.py)

Hope to get a help from you. Thank you!

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions