Vector image representation is a popular choice when editability and flexibility in resolution are desired. However, most images are only available in raster form, making raster-to-vector image conversion (vectorization) an important task. Classical methods for vectorization are either domain-specific or yield an abundance of shapes which limits editability and interpretability. Learning-based methods, that use differentiable rendering, have revolutionized vectorization, at the cost of poor generalization to out-of-training distribution domains, and optimization-based counterparts are either slow or produce non-editable and redundant shapes. In this work, we propose Optimize & Reduce (O&R), a top-down approach to vectorization that is both fast and domain-agnostic. O&R aims to attain a compact representation of input images by iteratively optimizing B\'ezier curve parameters and significantly reducing the number of shapes, using a devised importance measure. We contribute a benchmark of five datasets comprising images from a broad spectrum of image complexities - from emojis to natural-like images. Through extensive experiments on hundreds of images, we demonstrate that our method is domain agnostic and outperforms existing works in both reconstruction and perceptual quality for a fixed number of shapes. Moreover, we show that our algorithm is $\times 10$ faster than the state-of-the-art optimization-based method.
翻译:矢量图像表示在处理分辨率的可编辑性和灵活性时是一种广泛采用的选择。然而,大多数图像仅以栅格形式存在,这使得栅格到矢量图像的转换(矢量化)成为一项重要任务。经典的矢量化方法要么具有领域特异性,要么生成大量形状,从而限制了可编辑性和可解释性。基于学习的方法利用可微渲染技术革新了矢量化,但代价是对训练分布外领域的泛化能力较差;而基于优化的方法要么速度较慢,要么产生不可编辑或冗余的形状。在本工作中,我们提出了一种自顶向下的矢量化方法——优化与精简(O&R),该方法既快速又具有领域无关性。O&R通过迭代优化贝塞尔曲线参数,并利用所设计的重要性度量显著减少形状数量,旨在获得输入图像的紧凑表示。我们构建了一个包含五个数据集的基准测试,这些数据集涵盖了从表情符号到自然图像等广泛图像复杂度范围内的图像。通过对数百张图像的大量实验,我们证明了该方法具有领域无关性,并且在固定形状数量下,其在重建质量和感知质量上均优于现有方法。此外,我们表明该算法比目前最先进的基于优化方法快10倍。