Scalable Vector Graphics (SVG) is a prevalent vector image format with good support for interactivity and animation. Despite such appealing characteristics, it is generally challenging for users to create their own SVG content because of the long learning curve to comprehend SVG grammars or acquaint themselves with professional editing software. Recent progress in text-to-image generation has inspired researchers to explore image-based icon synthesis (i.e., text -> raster image -> vector image) via differential rendering and language-based icon synthesis (i.e., text -> vector image script) via the "zero-shot" capabilities of large language models. However, these methods may suffer from several limitations regarding generation quality, diversity, flexibility, and speed. In this paper, we introduce IconShop, a text-guided vector icon synthesis method using an autoregressive transformer. The key to success of our approach is to sequentialize and tokenize the SVG paths (and textual descriptions) into a uniquely decodable command sequence. With such a single sequence as input, we are able to fully exploit the sequence learning power of autoregressive transformers, while enabling various icon synthesis and manipulation tasks. Through standard training to predict the next token on a large-scale icon dataset accompanied by textural descriptions, the proposed IconShop consistently exhibits better icon synthesis performance than existing image-based and language-based methods both quantitatively (using the FID and CLIP score) and qualitatively (through visual inspection). Meanwhile, we observe a dramatic improvement in generation diversity, which is supported by objective measures (Uniqueness and Novelty). More importantly, we demonstrate the flexibility of IconShop with two novel icon manipulation tasks - text-guided icon infilling, and text-combined icon synthesis.
翻译:可缩放矢量图形(SVG)是一种广泛使用的矢量图像格式,具有良好的交互和动画支持。尽管具有这些吸引人的特性,但用户通常难以自行创建SVG内容,因为掌握SVG语法或熟悉专业编辑软件需要较长的学习曲线。文本到图像生成的最新进展激发了研究者探索通过可微分渲染实现基于图像的图标合成(即文本→栅格图像→矢量图像),以及通过大语言模型的“零样本”能力实现基于语言的图标合成(即文本→矢量图像脚本)。然而,这些方法在生成质量、多样性、灵活性和速度方面可能存在若干局限性。本文提出IconShop,一种使用自回归变换器的文本引导矢量图标合成方法。我们方法成功的关键在于将SVG路径(及文本描述)序列化并分词为唯一可解码的命令序列。通过将该单一序列作为输入,我们能够充分利用自回归变换器的序列学习能力,同时实现多种图标合成与操作任务。通过在大规模带文本描述的图标数据集上进行标准的下一个词元预测训练,所提出的IconShop在量化指标(使用FID和CLIP分数)和定性分析(通过视觉检查)上均持续展现出优于现有基于图像和基于语言方法的图标合成性能。同时,我们观察到生成多样性的显著提升,这一结论得到客观度量(唯一性和新颖性)的支持。更重要的是,我们通过两项新颖的图标操作任务——文本引导的图标补全与文本组合图标合成——展示了IconShop的灵活性。