Skip to content

Commit

Permalink
add argument show for image_demo
Browse files Browse the repository at this point in the history
  • Loading branch information
Ben-Louis committed Feb 13, 2023
1 parent 35f71d0 commit c9935ef
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
7 changes: 6 additions & 1 deletion demo/image_demo.py
Expand Up @@ -20,6 +20,11 @@ def parse_args():
'--draw-heatmap',
action='store_true',
help='Visualize the predicted heatmap')
parser.add_argument(
'--show',
action='store_true',
default=False,
help='whether to show img')
args = parser.parse_args()
return args

Expand Down Expand Up @@ -56,7 +61,7 @@ def main():
draw_gt=False,
draw_bbox=True,
draw_heatmap=args.draw_heatmap,
show=True,
show=args.show,
out_file=args.out_file)


Expand Down
4 changes: 1 addition & 3 deletions docs/en/installation.md
Expand Up @@ -117,12 +117,10 @@ python demo/image_demo.py \
--draw-heatmap
```

If everything goes fine, you will get this visualization result:
If everything goes fine, you will be able to get the following visualization result from `vis_results.jpg` in your current folder, which displays the predicted keypoints and heatmaps overlaid on the person in the image.

![image](https://user-images.githubusercontent.com/87690686/187824033-2cce0f55-034a-4127-82e2-52744178bc32.jpg)

And the visualization result will be saved as `vis_results.jpg` on your current folder, where the predicted keypoints and heatmaps are plotted on the person in the image.

Option (B). If you install mmpose with pip, open you python interpreter and copy & paste the following codes.

```python
Expand Down

0 comments on commit c9935ef

Please sign in to comment.