denoise_cnn_autoencoder.py 文件源码

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

项目:road-segmentation 作者: paramoecium 项目源码 文件源码
def binarize(image):
    """
    Binarizes an image with the threshold defined in the AE config
    :param image: The image to binarize. Most likely a low-res image where each pixel
                  represents a patch
    :return: An image where each pixel larger than the threshold is set to 1,
             and otherwise set to 0.
    """
    binarized = np.zeros(image.shape)
    binarized[image > conf.binarize_threshold] = 1
    return binarized
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号