( 提示 ) 图片转提示词
这篇教学会介绍 Replicate 里的几个“分析图片并撰写提示词”模型,只要提供图片,就能运用 AI 分析图片内容,撰写出 AI 绘图专用的提示词。
快速导览:
img2prompt ( 不用注册 )
这个模型可以分析图片内容,并撰写相关提示词 ( 最适合 Stable Diffusion )。
打开网页后,点击下方“Drop a file or click to upload”按钮选择并上传图片 ( 也可以将图片拖曳到这个区域上传 ),上传图片后点击“Run”按钮开始运作模型。
范例中上传了一张蒙娜丽莎的图片,经过 AI 分析后可以得到下列提示词:“a close up of a painting of a woman, a painting by Leonardo da Vinci, pixabay contest winner, academic art, da vinci, detailed painting, artwork”。
使用支援 Stable Diffusion 的 AI 绘图工具,根据这段提示词进行绘图,就可以得到类似的结果,下图使用 Leonardo.Ai 的 Stable Diffusion 1.5 模型绘制。
clip-interrogator ( 不用注册 )
这个模型可以分析图片内容,同时使用 OpenAI 的 CLIP 和 Salesforce 的 BLIP 来提高提示词质量,产生适合 AI 绘图的提示词 ( 最适合 Stable Diffusion )。
打开网页后,点击下方“Drop a file or click to upload”按钮选择并上传图片 ( 也可以将图片拖曳到这个区域上传 ),上传图片后点击“Run”按钮开始运作模型。
这个模型有两个参数,clip_model_name 会产生最适合特定模型的提示词 ( ViT-L 适合 Stable Diffusion 1,ViT-H 适合 Stable Diffusion 2,ViT-bigG 适合 Stable Diffusion XL ),mode 则是提示词质量,质量越好所花费的时间越多。
范例中上传了一张蒙娜丽莎的图片,使用 ViT-L 模型分析,完成后可以得到下列提示词:“a close up of a painting of a woman with a smile, golden ratio face, woman is sitting, front page, corrected hand, lisa, 2 0 2 1 award winning painting, the woman has long dark hair, subtle confident smile, exaggerated proportions, reference, bad art”。
使用支援 Stable Diffusion 的 AI 绘图工具,根据这段提示词进行绘图,就可以得到类似的结果,下图使用 Leonardo.Ai 的 Stable Diffusion 1.5 模型绘制。
下图使用一张码头风景的照片,使用 ViT-H 模型分析,完成后可以得到下列提示词:“arafed wooden pier with birds flying over a lake at sunset, full of colour 8-w 1024, high qulity, sunset view, yang qi, beautiful visuals, beach landscape, trailer, on ship, view, house, good photography, horizon view, <hd, lake blue, eight eight eight, frameless, resting”。
使用支援 Stable Diffusion 的 AI 绘图工具,根据这段提示词进行绘图,就可以得到类似的结果,下图使用 Leonardo.Ai 的 Stable Diffusion 2.1 模型绘制。
微信扫码关注
抖音扫码关注