基于代码的图像生成:基准测试、基线模型与改进的奖励机制
Code-based Image Generation: Benchmarking, Baselines, and Improved Rewards
AI总结:
该研究针对基于代码的图像生成任务,测试大语言模型,提出两阶段后训练方法,发现同时结合图像与程序的奖励机制可提升模型性能,且开源模型经后训练能达到或超越混合教师模型水平。
摘要:
语言模型编码能力的近期提升使代码成为图像生成的新兴范式:模型编写程序,渲染器将其转换为图像。我们在基于代码的图像生成(CIG)任务上对前沿及开放权重的大语言模型(LLM)进行基准测试,并提出两个进一步的问题:1)开源LLM能否通过后训练从更强的模型中学习该能力;2)拥有程序能否为训练提供更好的奖励。为回答这些问题,我们分两个阶段对开源LLM进行后训练:首先通过混合更强教师模型的监督微调进行知识蒸馏,随后使用GRPO进行强化学习。我们仅在评判者的输入内容上设置差异以比较奖励:仅图像、仅程序,或两者兼具。研究发现:1)后训练后,我们的模型Pictor-27B在GenEval2和PRISM-Bench上的表现与混合教师模型相当或更优;2)程序确实能提供更好的奖励:评判者同时查看图像和程序时训练的模型,其GenEval2 GM分数较基础模型提升18.0,而仅查看程序时提升15.5,仅查看图像时提升14.3。人类也更偏好该模型生成的图像而非仅图像模型的结果。我们分析了原因:仅图像无法体现形状的预期含义,仅程序无法体现其在渲染中是否可见;同时查看两者时,评判者可验证程序意图与渲染图像的一致性。代码、数据和模型可在该httpsURL获取。
英文摘要:
Recent improvements in the coding ability of language models have made code an emerging paradigm for image generation: the model writes a program, and a renderer turns it into an image. We benchmark frontier and open-weight LLMs on code-based image generation (CIG) and ask two further questions: 1) can open-source LLMs learn this capability from stronger models through post-training, and 2) does having a program enable a better reward for training? To answer them, we post-train open-source LLMs in two stages: distillation with supervised fine-tuning from a mixture of stronger teachers, then reinforcement learning with GRPO. We compare rewards that differ only by what the judge is shown: the image, the program, or both. We find that 1) after post-training, our model, Pictor-27B, matches or beats its teacher mix on GenEval2 and PRISM-Bench. 2) The program does enable a better reward: the model trained with the judge shown both image and program gains 18.0 GenEval2 GM points over its base model, against 15.5 for the program alone and 14.3 for the image alone. People also prefer its images to those of the image-only model. We analyse why. The image alone does not show what a shape is meant to be, and the program alone does not show whether it is visible in the render. Shown both, the judge can verify the intent of the program against the rendered image. Code, data and models are available at this https URL.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。