BirdsEyeView.py 文件源码

python
阅读 22 收藏 0 点赞 0 评论 0

项目:svm-street-detector 作者: morris-frank 项目源码 文件源码
def world2image_uvMat(self, uv_mat):
        '''

        @param XYZ_mat: is a 4 or 3 times n matrix
        '''
        if uv_mat.shape[0] == 2:
            if len(uv_mat.shape)==1:
                uv_mat = uv_mat.reshape(uv_mat.shape + (1,))
            uv_mat = np.vstack((uv_mat, np.ones((1, uv_mat.shape[1]), uv_mat.dtype)))
        result = np.dot(self.Tr33, uv_mat)
        #w0 = -(uv_mat[0]* self.Tr_inv_33[1,0]+ uv_mat[1]* self.Tr_inv[1,1])/self.Tr_inv[1,2]
        resultB = np.broadcast_arrays(result, result[-1,:])
        return resultB[0] / resultB[1]
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号