Skip to content

Commit 475fd2d

Browse files
authored
Merge pull request #1123 from hanjr92/hanjr-patch
Hanjr patch
2 parents b8c80d9 + 958d489 commit 475fd2d

7 files changed

Lines changed: 111 additions & 0 deletions

File tree

46.8 KB
Loading

docs/images/human_pose_points.jpg

26.3 KB
Loading
1.79 MB
Loading
6.91 MB
Loading

examples/app_tutorials/README.md

Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
# Quick Start
2+
TensorLayer Implementation of [YOLOv4: Optimal Speed and Accuracy of Object Detection][1]
3+
4+
TensorLayer Implementation of [Optimizing Network Structure for 3D Human Pose Estimation][2](ICCV2019)
5+
6+
## YOLOv4
7+
8+
Yolov4 was trained on COCO 2017 Dataset in this demo.
9+
10+
### Data
11+
12+
Download yolov4.weights file [yolov4_model.npz][3], Password: `idsz`, and put yolov4.weights under the folder `./examples/app_tutorials/model/`. Your directory structure should look like this:
13+
14+
```
15+
${root}/examples
16+
└── app_tutorials
17+
└── model
18+
├── yolov4_model.npz
19+
├── coco.names
20+
└── yolov4_weights_congfig.txt
21+
22+
```
23+
24+
25+
You can put an image or a video under the folder `./examples/app_tutorials/data/`,like:
26+
```
27+
${root}/examples
28+
└──app_tutorials
29+
└──data
30+
└── *.jpg/*.png/*.mp4/..
31+
```
32+
### demo
33+
34+
1. Image
35+
36+
Modify `image_path` in `./examples/app_tutorials/tutorial_object_detection_yolov4_image.py` according to your demand, then
37+
38+
```bash
39+
python tutorial_object_detection_yolov4_image.py
40+
```
41+
2. Video
42+
43+
Modify `video_path` in `./examples/app_tutorials/tutorial_object_detection_yolov4_video.py` according to your demand, then
44+
45+
```bash
46+
python tutorial_object_detection_yolov4_video.py
47+
```
48+
3. Output
49+
50+
-Image
51+
52+
<p align="center"><img src="../../docs/images/yolov4_image_result.png" width="640"\></p>
53+
54+
-Video
55+
56+
<p align="center"><img src="../../docs/images/yolov4_video_result.gif" width="640"\></p>
57+
58+
59+
60+
## 3D Human Pose Estimation
61+
62+
### Data
63+
64+
Download 3D Human Pose Estimation model weights [lcn_model.npz][4], Password:`ec07`,and put it under the folder `./examples/app_tutorials/model/`, Your directory structure should look like this:
65+
66+
```
67+
${root}/examples
68+
└── app_tutorials
69+
└── model
70+
├── lcn_model.npz
71+
└── pose_weights_config.txt
72+
```
73+
Download finetuned Stacked Hourglass detections and preprocessed H3.6M data([H36M.rar][5],Password:`kw9i`), then uncompress and put them under the folder `./examples/app_tutorials/data/`, like:
74+
```
75+
${root}/examples
76+
└──app_tutorials
77+
└──data
78+
├── h36m_sh_dt_ft.pkl
79+
├── h36m_test.pkl
80+
└── h36m_train.pkl
81+
```
82+
Each sample is a list with the length of 34 in three `.pkl` files. The list represents `[x,y]` of 17 human pose points:
83+
<p align="center"><img src="../../docs/images/human_pose_points.jpg" width="300"\></p>
84+
85+
If you would like to know how to prepare the H3.6M data, please have a look at the [pose_lcn][6].
86+
87+
### Demo
88+
89+
For a quick demo, simply run
90+
91+
```bash
92+
python tutorial_human_3dpose_estimation_LCN.py
93+
```
94+
This will produce a visualization similar to this:
95+
<p align="center"><img src="../../docs/images/3d_human_pose_result.jpg" width="1500"\></p>
96+
97+
This demo maps 2D poses to 3D space. Each 3D space result list represents `[x,y,z]` of 17 human pose points.
98+
99+
# Acknowledgement
100+
101+
Yolov4 is bulit on https://github.com/AlexeyAB/darknet and https://github.com/hunglc007/tensorflow-yolov4-tflite.
102+
3D Human Pose Estimation is bulit on https://github.com/rujiewu/pose_lcn and https://github.com/una-dinosauria/3d-pose-baseline.
103+
We would like to thank the authors for publishing their code.
104+
105+
106+
[1]:https://arxiv.org/abs/2004.10934
107+
[2]:https://openaccess.thecvf.com/content_ICCV_2019/papers/Ci_Optimizing_Network_Structure_for_3D_Human_Pose_Estimation_ICCV_2019_paper.pdf
108+
[3]:https://pan.baidu.com/s/1MC1dmEwpxsdgHO1MZ8fYRQ
109+
[4]:https://pan.baidu.com/s/1HBHWsAfyAlNaavw0iyUmUQ
110+
[5]:https://pan.baidu.com/s/1nA96AgMsvs1sFqkTs7Dfaw
111+
[6]:https://github.com/rujiewu/pose_lcn
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)