diff --git a/.github/ISSUE_TEMPLATE/bug-report.md b/.github/ISSUE_TEMPLATE/bug-report.md new file mode 100644 index 0000000000..2f9c005993 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug-report.md @@ -0,0 +1,96 @@ +name: "🐞 Bug report" +description: "Create a report to help us reproduce and fix the bug" +labels: bug +title: "\[Bug\] " + +body: + +- type: markdown + attributes: + value: | + \## Note + For general usage questions or idea discussions, please post it to our [**Forum**](https://github.com/open-mmlab/mmpose/discussions) + Please fill in as **much** of the following form as you're able to. **The clearer the description, the shorter it will take to solve it.** + +- type: checkboxes + attributes: + label: Prerequisite + description: Please check the following items before creating a new issue. + options: + + - label: I have searched [Issues](https://github.com/open-mmlab/mmpose/issues) and [Discussions](https://github.com/open-mmlab/mmpose/discussions) but cannot get the expected help. + required: true + - label: The bug has not been fixed in the latest version(https://github.com/open-mmlab/mmpose). + required: true + +- type: textarea + attributes: + label: Environment + description: | + Please run following commands and and copy-paste it here: + \- `python -c "from mmpose.utils import collect_env; print(collect_env())"` to collect necessary environment information. + \- `pip list | grep mm` to collect repositories related to OpenMMLab. + \- \[Optional\] Other environment variables that may be related (such as `$PATH`, `$LD_LIBRARY_PATH`, `$PYTHONPATH`, etc.) + validations: + required: true + +- type: textarea + attributes: + label: Reproduces the problem - code sample + description: | + Please provide a code sample that reproduces the problem you ran into. It can be a Colab link or just a code snippet. + placeholder: | + `python # Sample code to reproduce the problem ` + validations: + required: true + +- type: textarea + attributes: + label: Reproduces the problem - command or script + description: | + What command or script did you run? + placeholder: | + `shell The command or script you run. ` + validations: + required: true + +- type: textarea + attributes: + label: Reproduces the problem - error message + description: | + Please provide the error message or logs you got, with the full traceback. + + ``` + Tip: You can attach screenshots or log files by dragging them into the text area.. + ``` + + placeholder: | + ` The error message or logs you got, with the full traceback. ` + validations: + required: true + +- type: textarea + attributes: + label: Additional information + description: | + Tell us anything else you think we should know. + + ``` + Tip: You can attach screenshots or log files by dragging them into the text area. + ``` + + placeholder: | + 1\. What's your expected result? + 2\. What dataset did you use? + 3\. What do you think might be the reason? + +- type: markdown + attributes: + value: | + \## Acknowledgement + Thanks for taking the time to fill out this report. + + ``` + If you have already identified the reason, we strongly appreciate you creating a new PR to fix it [**Here**](https://github.com/open-mmlab/mmpose/pulls)! + Please refer to [**Contribution Guide**](https://mmpose.readthedocs.io/en/latest/contribution_guide.html) for contributing. + ``` diff --git a/.github/ISSUE_TEMPLATE/error-report.md b/.github/ISSUE_TEMPLATE/error-report.md deleted file mode 100644 index 6c7bdea9a1..0000000000 --- a/.github/ISSUE_TEMPLATE/error-report.md +++ /dev/null @@ -1,56 +0,0 @@ ---- -name: Error report -about: Create a report to help us improve -title: '' -labels: '' -assignees: '' ---- - -Thanks for your error report and we appreciate it a lot. -If you feel we have helped you, give us a STAR! :satisfied: - -**Checklist** - -1. I have searched related issues but cannot get the expected help. -2. The bug has not been fixed in the latest version. - -**Describe the bug** - -A clear and concise description of what the bug is. - -**Reproduction** - -- What command or script did you run? - -``` -A placeholder for the command. -``` - -- What config did you run? - -``` -A placeholder for the config. -``` - -- Did you make any modifications on the code or config? Did you understand what you have modified? -- What dataset did you use? - -**Environment** - -1. Please run `PYTHONPATH=${PWD}:$PYTHONPATH python mmpose/utils/collect_env.py` to collect necessary environment information and paste it here. -2. You may add addition that may be helpful for locating the problem, such as - -- How you installed PyTorch \[e.g., pip, conda, source\] -- Other environment variables that may be related (such as `$PATH`, `$LD_LIBRARY_PATH`, `$PYTHONPATH`, etc.) - -**Error traceback** - -If applicable, paste the error traceback here. - -``` -A placeholder for traceback. -``` - -**Bug fix** - -If you have already identified the reason, you can provide the information here. If you are willing to create a PR to fix it, please also leave a comment here and that would be much appreciated! diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md index b4ea6903ed..ca94a6f1de 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -1,33 +1,42 @@ ---- -name: Feature request -about: Suggest an idea for this project -title: '' -labels: '' -assignees: '' ---- - -Thanks for your feature request and we will review and plan for it when necessary. -If you feel we have helped you, give us a STAR! :satisfied: - -**Steps** - -1. Check if the feature has been requested in the [meta issue](https://github.com/open-mmlab/mmpose/issues/9), and if so, click thumb up button. -2. Post the feature request in the [meta issue](https://github.com/open-mmlab/mmpose/issues/9), if it is new. - -**Describe the feature** - -**Motivation** - -A clear and concise description of the motivation of the feature. - -1. Ex1. It is inconvenient when \[....\]. -2. Ex2. There is a recent paper \[....\], which is very helpful for \[....\]. - -**Related resources** - -If there is an official code released or third-party implementations, please also provide the information here, which would be very helpful. - -**Additional context** - -Add any other context or screenshots about the feature request here. -If you would like to implement the feature and create a PR, please leave a comment here and that would be much appreciated. +name: 🚀 Feature request +description: Suggest an idea for this project +labels: \[feature-request\] +title: "\[Feature\] " + +body: + +- type: markdown + attributes: + value: | + \## Note + For general usage questions or idea discussions, please post it to our [**Forum**](https://github.com/open-mmlab/mmpose/discussions) + + ``` + Please fill in as **much** of the following form as you're able to. **The clearer the description, the shorter it will take to solve it.** + ``` + +- type: textarea + attributes: + label: What is the feature? + description: Tell us more about the feature and how this feature can help. + placeholder: | + E.g., It is inconvenient when \[....\]. + validations: + required: true + +- type: textarea + attributes: + label: Any other context? + description: | + Have you considered any alternative solutions or features? If so, what are they? Also, feel free to add any other context or screenshots about the feature request here. + +- type: markdown + attributes: + value: | + \## Acknowledgement + Thanks for taking the time to fill out this report. + + ``` + We strongly appreciate you creating a new PR to implement it [**Here**](https://github.com/open-mmlab/mmpose/pulls)! + Please refer to [**Contribution Guide**](https://mmpose.readthedocs.io/en/latest/contribution_guide.html) for contributing. + ``` diff --git a/.github/ISSUE_TEMPLATE/reimplementation_questions.md b/.github/ISSUE_TEMPLATE/reimplementation_questions.md deleted file mode 100644 index 5e1f91e39f..0000000000 --- a/.github/ISSUE_TEMPLATE/reimplementation_questions.md +++ /dev/null @@ -1,70 +0,0 @@ ---- -name: Reimplementation Questions -about: Ask about questions during model reimplementation -title: '' -labels: reimplementation -assignees: '' ---- - -If you feel we have helped you, give us a STAR! :satisfied: - -**Notice** - -There are several common situations in the reimplementation issues as below - -1. Reimplement a model in the model zoo using the provided configs. -2. Reimplement a model in the model zoo on other dataset (e.g., custom datasets). -3. Reimplement a custom model but all the components are implemented in MMPose. -4. Reimplement a custom model with new modules implemented by yourself. - -There are several things to do for different cases as below. - -- For case 1 & 3, please follow the steps in the following sections thus we could help to quick identify the issue. -- For case 2 & 4, please understand that we are not able to do much help here because we usually do not know the full code and the users should be responsible to the code they write. -- One suggestion for case 2 & 4 is that the users should first check whether the bug lies in the self-implemented code or the original code. For example, users can first make sure that the same model runs well on supported datasets. If you still need help, please describe what you have done and what you obtain in the issue, and follow the steps in the following sections and try as clear as possible so that we can better help you. - -**Checklist** - -1. I have searched related issues but cannot get the expected help. -2. The issue has not been fixed in the latest version. - -**Describe the issue** - -A clear and concise description of what the problem you meet and what have you done. - -**Reproduction** - -- What command or script did you run? - -``` -A placeholder for the command. -``` - -- What config dir you run? - -``` -A placeholder for the config. -``` - -- Did you make any modifications on the code or config? Did you understand what you have modified? -- What dataset did you use? - -**Environment** - -1. Please run `PYTHONPATH=${PWD}:$PYTHONPATH python mmpose/utils/collect_env.py` to collect necessary environment information and paste it here. -2. You may add addition that may be helpful for locating the problem, such as - -- How you installed PyTorch \[e.g., pip, conda, source\] -- Other environment variables that may be related (such as `$PATH`, `$LD_LIBRARY_PATH`, `$PYTHONPATH`, etc.) - -**Results** - -If applicable, paste the related results here, e.g., what you expect and what you get. - -``` -A placeholder for results comparison -``` - -**Issue fix** - -If you have already identified the reason, you can provide the information here. If you are willing to create a PR to fix it, please also leave a comment here and that would be much appreciated! diff --git a/.owners.yml b/.owners.yml new file mode 100644 index 0000000000..2050b43c10 --- /dev/null +++ b/.owners.yml @@ -0,0 +1,16 @@ +assign: + issues: enabled + pull_requests: disabled + strategy: + # random + daily-shift-based + scedule: + '*/1 * * * *' + assignees: + - Tau-J + - LareinaM + - Ben-Louis + - LareinaM + - Ben-Louis + - Tau-J + - Tau-J diff --git a/projects/rtmpose/README.md b/projects/rtmpose/README.md index b7eff118f1..bdb1db13d1 100644 --- a/projects/rtmpose/README.md +++ b/projects/rtmpose/README.md @@ -546,10 +546,6 @@ In this tutorial, we organize files as follows: |----mmdeploy |----mmdetection |----mmpose -|----rtmdet_nano -| |----rtmdet_nano.pth -|----rtmpose_m - |----rtmpose_m.pth ``` #### ONNX @@ -559,24 +555,28 @@ In this tutorial, we organize files as follows: cd ${PATH_TO_MMDEPLOY} # run the command to convert RTMDet +# Model file can be either a local path or a download link python tools/deploy.py \ configs/mmdet/detection/detection_onnxruntime_static.py \ - {RTMPOSE_PROJECT}/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ - ../rtmdet_nano/rtmdet_nano.pth \ + ../mmpose/projects/rtmpose/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmpose/rtmdet_nano_8xb32-100e_coco-obj365-person-05d8511e.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmdet/ort \ + --work-dir rtmpose-ort/rtmdet-nano \ --device cpu \ - --show + --show \ + --dump-info # dump sdk info # run the command to convert RTMPose +# Model file can be either a local path or a download link python tools/deploy.py \ configs/mmpose/pose-detection_simcc_onnxruntime_dynamic.py \ - {RTMPOSE_PROJECT}/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ - ../rtmpose_m/rtmpose_m.pth \ + ../mmpose/projects/rtmpose/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmposev1/rtmpose-m_simcc-aic-coco_pt-aic-coco_420e-256x192-63eb25f7_20230126.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmpose/ort \ + --work-dir rtmpose-ort/rtmpose-m \ --device cpu \ - --show + --show \ + --dump-info # dump sdk info ``` The converted model file is `{work-dir}/end2end.onnx` by defaults. @@ -588,24 +588,28 @@ The converted model file is `{work-dir}/end2end.onnx` by defaults. cd ${PATH_TO_MMDEPLOY} # run the command to convert RTMDet +# Model file can be either a local path or a download link python tools/deploy.py \ configs/mmdet/detection/detection_tensorrt_static-320x320.py \ - {RTMPOSE_PROJECT}/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ - ../rtmdet_nano/rtmdet_nano.pth \ + ../mmpose/projects/rtmpose/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmpose/rtmdet_nano_8xb32-100e_coco-obj365-person-05d8511e.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmdet/trt \ + --work-dir rtmpose-trt/rtmdet-nano \ --device cuda:0 \ - --show + --show \ + --dump-info # dump sdk info # run the command to convert RTMPose +# Model file can be either a local path or a download link python tools/deploy.py \ configs/mmpose/pose-detection_simcc_tensorrt_dynamic-256x192.py \ - {RTMPOSE_PROJECT}/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ - ../rtmpose_m/rtmpose_m.pth \ + ../mmpose/projects/rtmpose/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmposev1/rtmpose-m_simcc-aic-coco_pt-aic-coco_420e-256x192-63eb25f7_20230126.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmpose/trt \ + --work-dir rtmpose-trt/rtmpose-m \ --device cuda:0 \ - --show + --show \ + --dump-info # dump sdk info ``` The converted model file is `{work-dir}/end2end.engine` by defaults. @@ -631,27 +635,29 @@ backend_config = dict( We provide both Python and C++ inference API with MMDeploy SDK. -To use SDK, you need to dump the required info during converting the model. Just add --dump-info to the model conversion command: +To use SDK, you need to dump the required info during converting the model. Just add --dump-info to the model conversion command. ```shell # RTMDet +# Model file can be either a local path or a download link python tools/deploy.py \ configs/mmdet/detection/detection_onnxruntime_dynamic.py \ - {RTMPOSE_PROJECT}/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ - ../rtmdet_nano/rtmdet_nano.pth \ + ../mmpose/projects/rtmpose/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmpose/rtmdet_nano_8xb32-100e_coco-obj365-person-05d8511e.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmdet/sdk \ + --work-dir rtmpose-ort/rtmdet-nano \ --device cpu \ --show \ --dump-info # dump sdk info # RTMPose +# Model file can be either a local path or a download link python tools/deploy.py \ configs/mmpose/pose-detection_simcc_onnxruntime_dynamic.py \ - {RTMPOSE_PROJECT}/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ - ../rtmpose_m/rtmpose_m.pth \ + ../mmpose/projects/rtmpose/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmposev1/rtmpose-m_simcc-aic-coco_pt-aic-coco_420e-256x192-63eb25f7_20230126.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmpose/sdk \ + --work-dir rtmpose-ort/rtmpose-m \ --device cpu \ --show \ --dump-info # dump sdk info @@ -660,7 +666,7 @@ python tools/deploy.py \ After running the command, it will dump 3 json files additionally for the SDK: ```shell -|----sdk +|----{work-dir} |----end2end.onnx # ONNX model |----end2end.engine # TensorRT engine file @@ -807,7 +813,7 @@ If the user has MMDeploy compiled correctly, you will see the `det_pose` executa cd ${PATH_TO_MMDEPLOY}/build/bin/ # inference for an image -./det_pose {det work-dir} {pose work-dir} {your_img.jpg} --device cpu +./det_pose rtmpose-ort/rtmdet-nano/ rtmpose-ort/rtmpose-m/ your_img.jpg --device cpu required arguments: det_model Object detection model path [string] @@ -835,12 +841,14 @@ optional arguments: If the user has MMDeploy compiled correctly, you will see the `pose_tracker` executable under the `mmdeploy/build/bin/`. +- pass `0` to `input` can inference from a webcam + ```shell # go to the mmdeploy folder cd ${PATH_TO_MMDEPLOY}/build/bin/ # inference for a video -./pose_tracker {det work-dir} {pose work-dir} {your_video.mp4} --device cpu +./pose_tracker rtmpose-ort/rtmdet-nano/ rtmpose-ort/rtmpose-m/ your_video.mp4 --device cpu required arguments: det_model Object detection model path [string] diff --git a/projects/rtmpose/README_CN.md b/projects/rtmpose/README_CN.md index 293dc82f80..5b7979c3ec 100644 --- a/projects/rtmpose/README_CN.md +++ b/projects/rtmpose/README_CN.md @@ -243,6 +243,7 @@ RTMPose 是一个长期优化迭代的项目,致力于业务场景下的高性 cd ${PATH_TO_MMPOSE} # RTMDet 与 RTMPose 联合推理 +# 输入模型路径可以是本地路径,也可以是下载链接。 python demo/topdown_demo_with_mmdet.py \ projects/rtmpose/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ https://download.openmmlab.com/mmpose/v1/projects/rtmpose/rtmdet_nano_8xb32-100e_coco-obj365-person-05d8511e.pth \ @@ -252,6 +253,7 @@ python demo/topdown_demo_with_mmdet.py \ --show # 摄像头推理 +# 输入模型路径可以是本地路径,也可以是下载链接。 python demo/topdown_demo_with_mmdet.py \ projects/rtmpose/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ https://download.openmmlab.com/mmpose/v1/projects/rtmpose/rtmdet_nano_8xb32-100e_coco-obj365-person-05d8511e.pth \ @@ -297,20 +299,20 @@ pip install mmdeploy-runtime-gpu # onnxruntime # for ubuntu wget -c https://github.com/open-mmlab/mmdeploy/releases/download/v1.0.0/mmdeploy-1.0.0-linux-x86_64-cxx11abi.tar.gz -# unzip then add third party runtime libraries to the PATH +# 解压并将 third_party 中第三方推理库的动态库添加到 PATH # for centos7 and lower wget -c https://github.com/open-mmlab/mmdeploy/releases/download/v1.0.0/mmdeploy-1.0.0-linux-x86_64.tar.gz -# unzip then add third party runtime libraries to the PATH +# 解压并将 third_party 中第三方推理库的动态库添加到 PATH # onnxruntime-gpu / tensorrt # for ubuntu wget -c https://github.com/open-mmlab/mmdeploy/releases/download/v1.0.0/mmdeploy-1.0.0-linux-x86_64-cxx11abi-cuda11.3.tar.gz -# unzip then add third party runtime libraries to the PATH +# 解压并将 third_party 中第三方推理库的动态库添加到 PATH # for centos7 and lower wget -c https://github.com/open-mmlab/mmdeploy/releases/download/v1.0.0/mmdeploy-1.0.0-linux-x86_64-cuda11.3.tar.gz -# unzip then add third party runtime libraries to the PATH +# 解压并将 third_party 中第三方推理库的动态库添加到 PATH ``` 3. 下载 sdk 模型并解压到 `./example/python` 下。(该模型只用于演示,如需其他模型,请参考 [SDK 推理](#%EF%B8%8F-sdk-推理)) @@ -542,10 +544,6 @@ example\cpp\build\Release |----mmdeploy |----mmdetection |----mmpose -|----rtmdet_nano -| |----rtmdet_nano.pth -|----rtmpose_m - |----rtmpose_m.pth ``` #### ONNX @@ -557,24 +555,28 @@ example\cpp\build\Release cd ${PATH_TO_MMDEPLOY} # 转换 RTMDet +# 输入模型路径可以是本地路径,也可以是下载链接。 python tools/deploy.py \ configs/mmdet/detection/detection_onnxruntime_static.py \ - {RTMPOSE_PROJECT}/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ - ../rtmdet_nano/rtmdet_nano.pth \ + ../mmpose/projects/rtmpose/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmpose/rtmdet_nano_8xb32-100e_coco-obj365-person-05d8511e.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmdet/ort \ + --work-dir rtmpose-ort/rtmdet-nano \ --device cpu \ - --show + --show \ + --dump-info # 导出 sdk info # 转换 RTMPose +# 输入模型路径可以是本地路径,也可以是下载链接。 python tools/deploy.py \ configs/mmpose/pose-detection_simcc_onnxruntime_dynamic.py \ - {RTMPOSE_PROJECT}/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ - ../rtmpose_m/rtmpose_m.pth \ + ../mmpose/projects/rtmpose/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmposev1/rtmpose-m_simcc-aic-coco_pt-aic-coco_420e-256x192-63eb25f7_20230126.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmpose/ort \ + --work-dir rtmpose-ort/rtmpose-m \ --device cpu \ - --show + --show \ + --dump-info # 导出 sdk info ``` 默认导出模型文件为 `{work-dir}/end2end.onnx` @@ -588,24 +590,28 @@ python tools/deploy.py \ cd ${PATH_TO_MMDEPLOY} # 转换 RTMDet +# 输入模型路径可以是本地路径,也可以是下载链接。 python tools/deploy.py \ configs/mmdet/detection/detection_tensorrt_static-320x320.py \ - {RTMPOSE_PROJECT}/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ - ../rtmdet_nano/rtmdet_nano.pth \ + ../mmpose/projects/rtmpose/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmpose/rtmdet_nano_8xb32-100e_coco-obj365-person-05d8511e.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmdet/trt \ + --work-dir rtmpose-trt/rtmdet-nano \ --device cuda:0 \ - --show + --show \ + --dump-info # 导出 sdk info # 转换 RTMPose +# 输入模型路径可以是本地路径,也可以是下载链接。 python tools/deploy.py \ configs/mmpose/pose-detection_simcc_tensorrt_dynamic-256x192.py \ - {RTMPOSE_PROJECT}/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ - ../rtmpose_m/rtmpose_m.pth \ + ../mmpose/projects/rtmpose/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmposev1/rtmpose-m_simcc-aic-coco_pt-aic-coco_420e-256x192-63eb25f7_20230126.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmpose/trt \ + --work-dir rtmpose-trt/rtmpose-m \ --device cuda:0 \ - --show + --show \ + --dump-info # 导出 sdk info ``` 默认导出模型文件为 `{work-dir}/end2end.engine` @@ -635,23 +641,25 @@ backend_config = dict( ```shell # RTMDet +# 输入模型路径可以是本地路径,也可以是下载链接。 python tools/deploy.py \ configs/mmdet/detection/detection_onnxruntime_dynamic.py \ - {RTMPOSE_PROJECT}/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ - ../rtmdet_nano/rtmdet_nano.pth \ + ../mmpose/projects/rtmpose/rtmdet/person/rtmdet_nano_320-8xb32_coco-person.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmpose/rtmdet_nano_8xb32-100e_coco-obj365-person-05d8511e.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmdet/sdk \ + --work-dir rtmpose-ort/rtmdet-nano \ --device cpu \ --show \ - --dump-info # 导出 sdk info + --dump-info # 导出 sdk info # RTMPose +# 输入模型路径可以是本地路径,也可以是下载链接。 python tools/deploy.py \ configs/mmpose/pose-detection_simcc_onnxruntime_dynamic.py \ - {RTMPOSE_PROJECT}/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ - ../rtmpose_m/rtmpose_m.pth \ + ../mmpose/projects/rtmpose/rtmpose/body_2d_keypoint/rtmpose-m_8xb256-420e_coco-256x192.py \ + https://download.openmmlab.com/mmpose/v1/projects/rtmposev1/rtmpose-m_simcc-aic-coco_pt-aic-coco_420e-256x192-63eb25f7_20230126.pth \ demo/resources/human-pose.jpg \ - --work-dir mmdeploy_models/mmpose/sdk \ + --work-dir rtmpose-ort/rtmpose-m \ --device cpu \ --show \ --dump-info # 导出 sdk info @@ -800,7 +808,7 @@ target_link_libraries(${name} PRIVATE mmdeploy ${OpenCV_LIBS}) cd ${PATH_TO_MMDEPLOY}/build/bin/ # 单张图片推理 -./det_pose {det work-dir} {pose work-dir} {your_img.jpg} --device cpu +./det_pose rtmpose-ort/rtmdet-nano/ rtmpose-ort/rtmpose-m/ your_img.jpg --device cpu required arguments: det_model Detection 模型路径 [string] @@ -829,12 +837,14 @@ optional arguments: 如果用户有跟随 MMDeploy 安装教程进行正确编译,在 `mmdeploy/build/bin/` 路径下会看到 `pose_tracker` 的可执行文件。 +- 将 `input` 输入 `0` 可以使用摄像头推理 + ```shell # 前往 mmdeploy 目录 cd ${PATH_TO_MMDEPLOY}/build/bin/ # 视频推理 -./pose_tracker {det work-dir} {pose work-dir} {your_video.mp4} --device cpu +./pose_tracker rtmpose-ort/rtmdet-nano/ rtmpose-ort/rtmpose-m/ your_video.mp4 --device cpu required arguments: det_model Detection 模型路径 [string]