BlinkPipeline.py 文件源码

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

项目:cozmo_beyond 作者: PeterMitrano 项目源码 文件源码
def __threshold_moving(input, last_image):
        """Thresholds off parts of the image that have moved or changed between
           the previous and next image.
        Args:
            input: A numpy.ndarray.
            last_image: The previous value of the numpy.ndarray.
        Returns:
            A numpy.ndarray with the parts that are the same in black.
        """
        if (last_image.shape == input.shape):
            output =  cv2.absdiff(input, last_image)
        else:
            output = numpy.ndarray(shape=input.shape, dtype=input.dtype)
        return input, output
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号