Skip to content

Commit

Permalink
fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
LareinaM authored Sep 13, 2023
1 parent 2f6b9ac commit b1d51e3
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions mmpose/models/pose_estimators/topdown.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,8 @@ def add_pred_to_datasample(self, batch_pred_instances: InstanceList,
input_size = data_sample.metainfo['input_size']

pred_instances.keypoints[..., :2] = \
pred_instances.keypoints[..., :2] / input_size * bbox_scales \
+ bbox_centers - 0.5 * bbox_scales
pred_instances.keypoints[..., :2] / input_size * input_scale \
+ input_center - 0.5 * input_scale
if 'keypoints_visible' not in pred_instances:
pred_instances.keypoints_visible = \
pred_instances.keypoint_scores
Expand Down Expand Up @@ -182,4 +182,5 @@ def add_pred_to_datasample(self, batch_pred_instances: InstanceList,
pred_fields.set_field(value[output_keypoint_indices],
key)
data_sample.pred_fields = pred_fields

return batch_data_samples

0 comments on commit b1d51e3

Please sign in to comment.