compute_fv.py 文件源码

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

项目:c3d_ucf101_siamese_yilin 作者: fxing328 项目源码 文件源码
def dictionary(descriptors, N):
        pdb.set_trace()
    em = cv2.EM(N)
    em.train(descriptors)

    return np.float32(em.getMat("means")), \
        np.float32(em.getMatVector("covs")), np.float32(em.getMat("weights"))[0]

#def image_descriptors(file):
#   img = cv2.imread(file, 0)
#   img = cv2.resize(img, (256, 256))
#   _ , descriptors = cv2.SIFT().detectAndCompute(img, None)
#   return descriptors
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号