Skip to content

Commit

Permalink
fix mmpose version of v0.24.0 (open-mmlab#217)
Browse files Browse the repository at this point in the history
  • Loading branch information
RunningLeon committed Mar 8, 2022
1 parent 24c7f47 commit 3ca452f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 13 deletions.
9 changes: 3 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,7 @@ jobs:
run: rm -rf .eggs && pip install -e .
- name: Run unittests and generate coverage report
run: |
coverage run --branch --source mmdeploy -m pytest -rsE tests --ignore=tests/test_codebase/test_mmpose
coverage run --branch --source mmdeploy --append -m pytest -rsE tests/test_codebase/test_mmpose
coverage run --branch --source mmdeploy -m pytest -rsE tests
coverage xml
coverage report -m
Expand Down Expand Up @@ -96,8 +95,7 @@ jobs:
python tools/check_env.py
- name: Run unittests and generate coverage report
run: |
coverage run --branch --source mmdeploy -m pytest -rsE tests --ignore=tests/test_codebase/test_mmpose
coverage run --branch --source mmdeploy --append -m pytest -rsE tests/test_codebase/test_mmpose
coverage run --branch --source mmdeploy -m pytest -rsE tests
coverage xml
coverage report -m
Expand Down Expand Up @@ -141,8 +139,7 @@ jobs:
python tools/check_env.py
- name: Run unittests and generate coverage report
run: |
coverage run --branch --source mmdeploy -m pytest -rsE tests --ignore=tests/test_codebase/test_mmpose
coverage run --branch --source mmdeploy --append -m pytest -rsE tests/test_codebase/test_mmpose
coverage run --branch --source mmdeploy -m pytest -rsE tests
coverage xml
coverage report -m
- name: Upload coverage to Codecov
Expand Down
10 changes: 4 additions & 6 deletions mmdeploy/codebase/mmpose/deploy/pose_detection.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ def create_input(self,
Returns:
tuple: (data, img), meta information for the input image and input.
"""
from mmpose.apis.inference import LoadImage, _box2cs
from mmpose.apis.inference import _box2cs
from mmpose.datasets.dataset_info import DatasetInfo
from mmpose.datasets.pipelines import Compose

Expand All @@ -98,10 +98,7 @@ def create_input(self,
bboxes = np.array([box['bbox'] for box in person_results])

# build the data pipeline
channel_order = cfg.test_pipeline[0].get('channel_order', 'rgb')
test_pipeline = [LoadImage(channel_order=channel_order)
] + cfg.test_pipeline[1:]
test_pipeline = Compose(test_pipeline)
test_pipeline = Compose(cfg.test_pipeline)
dataset_name = dataset_info.dataset_name
flip_pairs = dataset_info.flip_pairs
batch_data = []
Expand All @@ -114,7 +111,7 @@ def create_input(self,

# prepare data
data = {
'img_or_path':
'img':
imgs,
'center':
center,
Expand All @@ -138,6 +135,7 @@ def create_input(self,
'flip_pairs': flip_pairs
}
}

data = test_pipeline(data)
batch_data.append(data)

Expand Down
2 changes: 1 addition & 1 deletion requirements/optional.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ mmcls>=0.15.0,<=0.19.0
mmdet>=2.19.0,<=2.20.0
mmedit
mmocr>=0.3.0
mmpose>=0.23.0
mmpose>=0.24.0
mmsegmentation
onnxruntime>=1.8.0
openvino-dev

0 comments on commit 3ca452f

Please sign in to comment.