---
# System prepended metadata

title: 解析 Human-Pose-Compare 的執行
tags: [openpose]

---

---
tags: openpose
---
# 解析 Human-Pose-Compare 的執行 
## 2021/6/7
### https://github.com/kr1210/Human-Pose-Compare

![](https://i.imgur.com/cBCMP7z.png)


```
python start_here.py --activity "punch - side" --video "test.mp4"
```


```
python keypoints_from_video.py --activity "punch - side" --video "test.mp4" --lookup "lookup_new.pickle"/[YOUR_LOOKUP_NAME]
```

```
python start_here.py --activity "punch - side" --video "test.mp4" --lookup "lookup_new.pickle"/[YOUR_LOOKUP_NAME]
```

---

### 介紹上面3行指命意思

(1)

> python start_here.py --activity "punch - side" --video "test.mp4"

start_here.py 裡的 lookup_test.pickle(default)，跟 test.mp4 做比對，**產生分數跟分數陣列資訊**

(2)

> python keypoints_from_video.py --activity "punch - side" --video "test.mp4" --lookup "lookup_new.pickle"/[YOUR_LOOKUP_NAME]

斜線跟中括號內的東西是註解，故正確的指令為 : 

> python keypoints_from_video.py --activity "punch - side" --video "test.mp4" --lookup "lookup_new.pickle"~~/[YOUR_LOOKUP_NAME]~~

產生 test.mp4 的**每個frame的骨架座標**

(3)


> python start_here.py --activity "punch - side" --video "test.mp4" --lookup "lookup_new.pickle"/[YOUR_LOOKUP_NAME]

斜線跟中括號內的東西一樣是註解，故正確的指令為 : 


> python start_here.py --activity "punch - side" --video "test.mp4" --lookup "lookup_new.pickle"~~/[YOUR_LOOKUP_NAME]~~

這邊是 **lookup_new.pickle** 跟 test.mp4 做比較，產生分數跟分數陣列資訊


### start_here.py

=> 產生分數跟分數陣列資訊

### keypoints_from_video.py

=> 每個frame的骨架座標

----

### 應用 true.mp4 跟 false.mp4 做比對

[true.mp4](https://www.dropbox.com/s/9ddmzn0147sze5p/true.mp4?dl=0)

[false.mp4](https://www.dropbox.com/s/8tjxmox4vf1jnzn/false.mp4?dl=0)

> # true VS false
> 
>(1)
> python keypoints_from_video.py --activity "punch - side" --video "false.mp4" --lookup "false_new.pickle"
> 
>(2)
> python start_here.py --activity "punch - side" --video "true.mp4" --lookup "false_new.pickle"
> 
> 
> Total Score :  67.29411764705883
> Score List :  [57, 54, 54, 54, 54, 66, 65, 70, 67, 64, 57, 82, 80, 84, 78, 82, 76]
> 
> 
> # false VS true 
> 
> 
> (1)
> python keypoints_from_video.py --activity "punch - side" --video "true.mp4" --lookup "true_new.pickle"
> 
> (2)
> python start_here.py --activity "punch - side" --video "false.mp4" --lookup "true_new.pickle"
> 
> 
> Total Score :  67.29411764705883
> Score List :  [57, 54, 54, 54, 54, 66, 65, 70, 67, 64, 57, 82, 80, 84, 78, 82, 76]