denoise_cnn_autoencoder.py 文件源码

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

项目:road-segmentation 作者: paramoecium 项目源码 文件源码
def add_rotations(image):
    """
    Rotates the provided image a couple of time to generate more training data.
    This should make the autoencoder more robust to diagonal roads for example.

    The rotations will keep the dimensions of the image intact.

    :param image: The image to rotate
    :return: A list of rotated images, including the original image
    """
    rot90img = rotate(image, 90, reshape=False, mode='reflect', order=3)
    rot45img = rotate(image, 45, reshape=False, mode='reflect', order=3)
    rot135img = rotate(image, 135, reshape=False, mode='reflect', order=3)

    return [image, rot90img, rot45img, rot135img]
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号