diff --git a/mmhuman3d/core/conventions/keypoints_mapping/agora.py b/mmhuman3d/core/conventions/keypoints_mapping/agora.py index 44c7ebc5..60171075 100644 --- a/mmhuman3d/core/conventions/keypoints_mapping/agora.py +++ b/mmhuman3d/core/conventions/keypoints_mapping/agora.py @@ -1,7 +1,7 @@ AGORA_KEYPOINTS = [ - 'pelvis', 'left_hip', 'right_hip', 'spine_1', 'left_knee', 'right_knee', - 'spine_2', 'left_ankle', 'right_ankle', 'spine_3', 'left_foot', - 'right_foot', 'neck', 'left_collar', 'right_collar', 'head', + 'pelvis', 'left_hip_extra', 'right_hip_extra', 'spine_1', 'left_knee', + 'right_knee', 'spine_2', 'left_ankle', 'right_ankle', 'spine_3', + 'left_foot', 'right_foot', 'neck', 'left_collar', 'right_collar', 'head', 'left_shoulder', 'right_shoulder', 'left_elbow', 'right_elbow', 'left_wrist', 'right_wrist', 'jaw', 'left_eyeball', 'right_eyeball', 'left_index_1', 'left_index_2', 'left_index_3', 'left_middle_1', diff --git a/mmhuman3d/data/data_converters/agora.py b/mmhuman3d/data/data_converters/agora.py index 619e4e7a..5d7dfe16 100644 --- a/mmhuman3d/data/data_converters/agora.py +++ b/mmhuman3d/data/data_converters/agora.py @@ -108,7 +108,7 @@ def get_global_orient(self, # flip pose R_mod = cv2.Rodrigues(np.array([np.pi, 0, 0]))[0] R_root = cv2.Rodrigues(globalOrient.reshape(-1))[0] - new_root = R_root.dot(R_mod) + new_root = R_mod.dot(R_root) globalOrient = cv2.Rodrigues(new_root)[0].reshape(3) # apply camera matrices @@ -212,11 +212,16 @@ def convert_by_mode(self, dataset_path: str, out_path: str, occlusion = df.iloc[idx]['occlusion'][pidx] ethnicity = df.iloc[idx]['ethnicity'][pidx] + # skip kid since they use different model + if kid: + continue + # obtain keypoints keypoints2d = df.iloc[idx]['gt_joints_2d'][pidx] if self.res == (1280, 720): keypoints2d *= (720 / 2160) keypoints3d = df.iloc[idx]['gt_joints_3d'][pidx] + keypoints3d -= keypoints3d[0] # root-centered gt_bodymodel_path = os.path.join( dataset_path,