parameters: (self, pose_2d, weights)
return_statement: return pose_3d
docstring: Reconstruct 3D poses given 2D estimations
docstring_summary: Reconstruct 3D poses given 2D estimations
docstring_tokens: Reconstruct 3D poses given 2D estimations
function: def compute_3d(self, pose_2d, weights):
          """Reconstruct 3D poses given 2D estimations"""
  
          _J_POS = [1, 2, 3, 4, 5, 6, 8, 10, 11, 12, 13, 14, 15, 16]
          _SCALE_3D = 1174.88312988
  
          if pose_2d.shape[1] != config.H36M_NUM_JOINTS:
              # need to call the linear regressor
              reg_joints = np.zeros(
                  (pose_2d.shape[0], config.H36M_NUM_JOINTS, 2))
              for oid, singe_pose in enumerate(pose_2d):
                  reg_joints[oid, _J_POS] = singe_pose
  
              norm_pose, _ = Prob3dPose.normalise_data(reg_joints, weights)
          else:
              norm_pose, _ = Prob3dPose.normalise_data(pose_2d, weights)
  
          pose_3d = self.create_rec(norm_pose, weights) * _SCALE_3D
          return pose_3d
function_tokens: def compute_3d ( self , pose_2d , weights ) : _J_POS = [ 1 , 2 , 3 , 4 , 5 , 6 , 8 , 10 , 11 , 12 , 13 , 14 , 15 , 16 ] _SCALE_3D = 1174.88312988 if pose_2d . shape [ 1 ] != config . H36M_NUM_JOINTS : # need to call the linear regressor reg_joints = np . zeros ( ( pose_2d . shape [ 0 ] , config . H36M_NUM_JOINTS , 2 ) ) for oid , singe_pose in enumerate ( pose_2d ) : reg_joints [ oid , _J_POS ] = singe_pose norm_pose , _ = Prob3dPose . normalise_data ( reg_joints , weights ) else : norm_pose , _ = Prob3dPose . normalise_data ( pose_2d , weights ) pose_3d = self . create_rec ( norm_pose , weights ) * _SCALE_3D return pose_3d