data_preprocessing_autoencoder.py 文件源码

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

项目:AVSR-Deep-Speech 作者: pandeydivesh15 项目源码 文件源码
def visualize(frame, coordinates_list, alpha = 0.80, color=[255, 255, 255]):
    """
    Args:
        1. frame:               OpenCV's image which has to be visualized.
        2. coordinates_list:    List of coordinates which will be visualized in the given `frame`
        3. alpha, color:        Some parameters which help in visualizing properly. 
                                A convex hull will be shown for each element in the `coordinates_list` 
    """
    layer = frame.copy()
    output = frame.copy()

    for coordinates in coordinates_list:
        c_hull = cv2.convexHull(coordinates)
        cv2.drawContours(layer, [c_hull], -1, color, -1)

    cv2.addWeighted(layer, alpha, output, 1 - alpha, 0, output)
    cv2.imshow("Output", output)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号