【stablediffusion】AI绘画炸裂更新!阿里重磅发布In-Context-LoRA:Flux ID一致性,分镜头,字体设计,BizyAir带你免下载极速体验10Lora
假设文本到图像的 DiT 本质上具有上下文生成功能,只需要很少的调整来激活它们,从而重新评估和简化这个框架。通过不同的任务实验,定性地证明了现有的文本到图像 DiT 可以有效地执行上下文生成,而无需任何调整。基于这一见解,提出了一个非常简单的管道来利用 DiT 的上下文能力:(1) 连接图像而不是标记, (2) 执行多个图像的联合字幕,以及 (3) 应用特定于任务的 LoRA 调整使用小数据集(例
好玩,好用的项目:阿里重磅发布基于Flux的In-Context-LoRA项目–适用于扩散变压器的上下文 LoRA,可以一次性生成多个分镜头,并保持分镜头人物的ID一致性。更有:
-
情侣头像设计
-
字体设计
-
家居装饰
-
肖像插画
-
人物摄影
-
PPT模版
-
沙尘暴视觉效果
-
烟火视觉效果
-
视觉识别设计
等10款In-Context-LoRA。
这里利用之前介绍的BizyAir
工具,让你免下载Lora
,极速体验In-Context-LoRA,10秒出图。
In-Context-LoRA 简介
假设文本到图像的 DiT 本质上具有上下文生成功能,只需要很少的调整来激活它们,从而重新评估和简化这个框架。通过不同的任务实验,定性地证明了现有的文本到图像 DiT 可以有效地执行上下文生成,而无需任何调整。
基于这一见解,提出了一个非常简单的管道来利用 DiT 的上下文能力:(1) 连接图像而不是标记, (2) 执行多个图像的联合字幕,以及 (3) 应用特定于任务的 LoRA 调整使用小数据集(例如, 20∼100 样本)而不是使用大型数据集进行全参数调整。我们将模型命名为 In-Context LoRA (IC-LoRA)。这种方法不需要修改原始 DiT 模型,只需要更改训练数据。
https://github.com/ali-vilab/In-Context-LoRA 为了方便进一步的研究,和解决剩余问题,阿里发布了代码、数据和模型。
主要效果包括:1)原始的文本到图像模型已经可以生成在身份、风格、照明和字体方面具有连贯一致性的多面板输出,尽管仍然存在一些小缺陷。2) FLUX.1-dev在解释描述多个面板的组合提示方面表现出强大的能力
主要假设:文本到图像模型本质上具有上下文生成功能
它保持一致的属性,例如主体身份、风格、照明条件和调色板,同时修改姿势、3D 方向和布局等其他方面。
重要的见解:
-
固有的上下文学习:文本到图像模型已经具备上下文生成能力。通过适当地触发和增强这种能力,我们可以利用它来完成复杂的生成任务。
-
无需架构修改的模型可重用性:由于文本到图像模型可以解释合并的字幕,因此我们可以重用它们进行上下文生成,而无需对其架构进行任何更改。这涉及简单地更改输入数据而不是修改模型本身。
-
最少数据和计算的效率:无需大量数据集或延长训练时间即可获得高质量结果。小型、高质量的数据集加上最少的计算资源可能就足够了。
基于这些见解,阿里设计了一个极其简单但有效的管道,用于使文本到图像模型适应不同的任务。方法与 GDT 的对比如下:
-
图像连接:我们将一组图像连接成单个大图像,而不是连接注意力标记。此方法大致相当于扩散变换器 (DiT) 中的标记串联,忽略变分自动编码器 (VAE) 组件引入的差异。
-
提示串联:我们将每个图像的提示合并为一个长提示,使模型能够同时处理和生成多个图像。这与 GDT 方法不同,在 GDT 方法中,每个图像的标记仅交叉参与其文本标记。
-
使用小数据集进行最小微调:我们不是对数十万个样本进行大规模训练,而是使用一小组仅 20∼100 图像集。这种方法显着减少了所需的计算资源,并在很大程度上保留了原始文本到图像模型的知识和上下文功能。
生成的模型非常简单,不需要对原始文本到图像模型进行修改。适应仅通过根据特定任务需求调整一小组调整数据来实现。
具体详情请查看论文:https://arxiv.org/abs/2410.23775
如果你也想训练这样的Lora,请使用:AI-Toolkit 工具,以及配置文件和训练数据:- 配置文件:config/movie-shots.yml
(放在AI-Toolkit的config/
目录下) - 示例训练数据: data/movie-shots.zip
(将其提取到AI-Toolkit的data/movie-shots
) 安装必要的依赖项并设置 AI-Toolkit 后,您可以通过运行以下命令开始训练:
python run.py config/movie-shots.yml
训练在至少具有 24GB 内存的单个 GPU 上运行(根据不同的 GPU 内存限制调整config/movie-shots.yml
中的resolution
参数)。
10 款 In-Context-LoRA 国内下载:
https://hf-mirror.com/ali-vilab/In-Context-LoRA/tree/main
image.png
具体模型以及示例提示词:
任务 | 模型 | 推荐大小 | 示例提示词 |
---|---|---|---|
1. Couple Profile Design 情侣头像设计 | couple-profile.safetensors |
width: 2048, height: 1024 |
This two-part image portrays a couple of cartoon cats in detective attire; [LEFT] a black cat in a trench coat and fedora holds a magnifying glass and peers to the right, while [RIGHT] a white cat with a bow tie and matching hat raises an eyebrow in curiosity, creating a fun, noir-inspired scene against a dimly lit background. 这张由两部分组成的图片描绘了一对穿着侦探服装的卡通猫;[左]一只身穿风衣、头戴软呢帽的黑猫拿着放大镜凝视着右边,而[右]一只打着领结、戴着相配帽子的白猫好奇地扬起眉毛,在昏暗的背景下创造了一个有趣的黑色风格的场景。 |
2. Film Storyboard 电影分镜 | film-storyboard.safetensors |
width: 1024, height: 1536 |
[MOVIE-SHOTS] In a vibrant festival, [SCENE-1] we find <Leo>, a shy boy, standing at the edge of a bustling carnival, eyes wide with awe at the colorful rides and laughter, [SCENE-2] transitioning to him reluctantly trying a daring game, his friends cheering him on, [SCENE-3] culminating in a triumphant moment as he wins a giant stuffed bear, his face beaming with pride as he holds it up for all to see. 在一个充满活力的节日里,[SCENE-1]我们发现,一个害羞的男孩,站在热闹的狂欢节边缘,对五颜六色的游乐设施和笑声睁大了眼睛,[SCENE-2]过渡到他不愿意尝试一个大胆的游戏,他的朋友们为他欢呼,[SCENE-3]在胜利的时刻达到高潮,他赢得了一个巨大的毛绒熊,他的脸上洋溢着骄傲,因为他把它举起来给所有人看。 |
3. Font Design 字体设计 | font-design.safetensors |
width: 1792, height: 1216 |
The four-panel image showcases a playful bubble font in a vibrant pop-art style. [TOP-LEFT] displays "Pop Candy" in bright pink with a polka dot background; [TOP-RIGHT] shows "Sweet Treat" in purple, surrounded by candy illustrations; [BOTTOM-LEFT] has "Yum!" in a mix of bright colors; [BOTTOM-RIGHT] shows "Delicious" against a striped background, perfect for fun, kid-friendly products. 四面板图像展示了一个充满活力的流行艺术风格的俏皮泡泡字体。[左上]以亮粉色的圆点背景显示“Pop Candy”;[右上]以紫色显示“Sweet Treat”,周围是糖果插图;[左下]用鲜艳的颜色组合着“Yum!”[右下]在条纹背景下显示“Delicious”,非常适合有趣的儿童友好型产品。 |
4. Home Decoration家居装饰 | home-decoration.safetensors |
width: 1344, height: 1728 |
This four-panel image showcases a rustic living room with warm wood tones and cozy decor elements; [TOP-LEFT] features a large stone fireplace with wooden shelves filled with books and candles; [TOP-RIGHT] shows a vintage leather sofa draped in plaid blankets, complemented by a mix of textured cushions; [BOTTOM-LEFT] displays a corner with a wooden armchair beside a side table holding a steaming mug and a classic book; [BOTTOM-RIGHT] captures a cozy reading nook with a window seat, a soft fur throw, and decorative logs stacked neatly. 这张四面板图像展示了一个质朴的客厅,温暖的木材色调和舒适的装饰元素;[左上]有一个巨大的石砌壁炉,里面有摆满书籍和蜡烛的木架子;[右上]展示了一张铺着格纹毯子的复古皮沙发,搭配了多种纹理的靠垫;[左下]展示了一个角落里的一张木扶手椅,旁边是一张边桌,上面放着一个热气腾腾的杯子和一本经典书籍;[右下]拍摄了一个舒适的阅读角,有一个靠窗的座位,柔软的毛皮垫子,以及整齐堆放的装饰性原木。 |
5. Portrait Illustration肖像插画 | portrait-illustration.safetensors |
width: 1152, height: 1088 |
This two-panel image presents a transformation from a realistic portrait to a playful illustration, capturing both detail and artistic flair; [LEFT] the photograph shows a woman standing in a bustling marketplace, wearing a wide-brimmed hat, a flowing bohemian dress, and a leather crossbody bag; [RIGHT] the illustration panel exaggerates her accessories and features, with the bohemian dress depicted in vibrant patterns and bold colors, while the background is simplified into abstract market stalls, giving the scene an animated and lively feel. 这两个面板的图像呈现了从一个现实的肖像到一个有趣的插图,捕捉细节和艺术天赋的转变;[左]照片中,一个女人站在熙熙攘攘的集市上,头戴宽边帽,身穿飘逸的波西米亚长裙,挎着皮质斜挎包;[右]插图面板夸张了她的配饰和特征,以充满活力的图案和大胆的色彩描绘了波西米亚的服装,而背景则简化为抽象的市场摊位,给场景带来了动画和活泼的感觉。 |
6. Portrait Photography 人像摄影 | portrait-photography.safetensors |
width: 1344, height: 1728 |
This [FOUR-PANEL] image illustrates a young artist's creative process in a bright and inspiring studio; [TOP-LEFT] she stands before a large canvas, brush in hand, adding vibrant colors to a partially completed painting, [TOP-RIGHT] she sits at a cluttered wooden table, sketching ideas in a notebook with various art supplies scattered around, [BOTTOM-LEFT] she takes a moment to step back and observe her work, adjusting her glasses thoughtfully, and [BOTTOM-RIGHT] she experiments with different textures by mixing paints directly on the palette, her focused expression showcasing her dedication to her craft. 这张 [四联画] 展示了一位年轻艺术家在明亮而鼓舞人心的工作室中的创作过程;[左上] 她站在一块大画布前,手拿画笔,为一幅未完成的画作增添鲜艳的色彩;[右上] 她坐在一张杂乱的木桌前,在散落着各种美术用品的笔记本上勾勒出想法;[左下] 她花了一点时间退后一步观察自己的作品,若有所思地调整眼镜;[右下] 她直接在调色板上混合颜料,尝试不同的纹理,她专注的表情展现了她对自己作品的奉献精神。 |
7. PPT Template PPT模版 | ppt-templates.safetensors |
width: 1984, height: 1152 |
This four-panel image showcases a rustic-themed PowerPoint template for a culinary workshop; [TOP-LEFT] introduces "Farm to Table Cooking" in warm, earthy tones; [TOP-RIGHT] organizes workshop sections like "Ingredients," "Preparation," and "Serving"; [BOTTOM-LEFT] displays ingredient lists for seasonal produce; [BOTTOM-RIGHT] includes chef profiles with short bios. 这张四面板图片展示了一个烹饪工作坊的乡村主题 PowerPoint 模板;[左上] 用温暖、朴实的色调介绍了“从农场到餐桌的烹饪”;[右上] 组织了“配料”、“准备”和“上菜”等工作坊部分;[左下] 展示了时令农产品的配料清单;[右下] 包括带有简短简历的厨师资料。 |
8. Sandstorm Visual Effect 沙尘暴视觉效果 | sandstorm-visual-effect.safetensors |
width: 1408, height: 1600 |
[SANDSTORM-PSA] This two-part image showcases the transformation of a cyclist through a sandstorm visual effect; [TOP] the upper panel features a cyclist in vibrant gear pedaling steadily on a clear, open road with a serene sky in the background, highlighting focus and determination, [BOTTOM] the lower panel transforms the scene as the cyclist becomes enveloped in a fierce sandstorm, with sand particles swirling intensely around the bike and rider against a stormy, darkened backdrop, emphasizing chaos and power. [SANDSTORM-PSA] 这张由两部分组成的图片通过沙尘暴的视觉效果展示了骑行者的变化;[顶部] 上图展示了一名骑行者身着鲜艳装备,在清澈开阔的道路上稳步骑行,背景是宁静的天空,强调了专注和决心;[底部] 下面板展示了骑行者被猛烈的沙尘暴笼罩时的场景,沙粒在暴风雨般黑暗的背景下在自行车和骑行者周围激烈地旋转,强调了混乱和力量。 |
9. Sparklers Visual Effect 烟火视觉效果 | sparklers-visual-effect.safetensors |
width: 960, height: 1088 |
[REAL-SPARKLERS-OVERLAYS] The two-part image vividly illustrates a woodland proposal transformed by sparkler overlays; [TOP] the first panel depicts a man kneeling on one knee with an engagement ring before his partner in a forest clearing at dusk, with warm, natural lighting, [BOTTOM] while the second panel introduces glowing sparklers that form a heart shape around the couple, amplifying the romance and joy of the moment. [真实烟花覆盖] 这张由两部分组成的图片生动地展示了一场由烟花覆盖而产生的林地求婚场景;[顶部] 第一幅图片描绘了一位男士在黄昏时分的森林空地上,手拿订婚戒指单膝跪在他的伴侣面前,周围是温暖的自然灯光;[底部] 而第二幅图片则展示了发光的烟花,它们在情侣周围形成了一个心形,放大了那一刻的浪漫和喜悦。 |
10. Visual Identity Design 视觉识别设计 | visual-identity-design.safetensors |
width: 1472, height: 1024 |
The two-panel image showcases the joyful identity of a produce brand, with the left panel showing a smiling pineapple graphic and the brand name “Fresh Tropic” in a fun, casual font on a light aqua background; [LEFT] while the right panel translates the design onto a reusable shopping tote with the pineapple logo in black, held by a person in a market setting, emphasizing the brand’s approachable and eco-friendly vibe. 这张双面板图像展示了一个农产品品牌的欢乐形象,左侧面板展示了一个微笑的菠萝图形和品牌名称“Fresh Tropic”,在浅绿色背景上采用了有趣、休闲的字体;[左] 而右侧面板将设计转化为一个可重复使用的购物手提袋,上面有黑色的菠萝标志,由市场环境中的人拿着,强调了该品牌平易近人和环保的氛围。 |
BizyAir 体验In-Context-LoRA
工作流
image.png
这里使用了共享Lora节点,直接使用大佬们上传好的In-Context-LoRA:
image.png
share_id: clx40kwpe0016c66lev4tzrux
工作流如有需要文末下载。
肖像插画
This two-panel image presents a transformation from a realistic portrait to a playful illustration, capturing both detail and artistic flair; [LEFT] the photograph shows a woman standing in a bustling marketplace, wearing a wide-brimmed hat, a flowing bohemian dress, and a leather crossbody bag; [RIGHT] the illustration panel exaggerates her accessories and features, with the bohemian dress depicted in vibrant patterns and bold colors, while the background is simplified into abstract market stalls, giving the scene an animated and lively feel.
In-Context-LoRA | Flux 原生 |
---|---|
![]() |
|
![]() |
|
情侣头像设计
The pair of images depicts cartoon characters enjoying music together; [IMAGE1] features a character with a spiky mohawk and wide headphones, bobbing their head with closed eyes, while [IMAGE2] presents a character with a ponytail, holding a guitar and also wearing headphones, both set against a dark blue background with musical notes scattered around.
In-Context-LoRA | Flux 原生 |
---|---|
![]() |
|
![]() |
|
电影镜头
[MOVIE-SHOTS] In a vibrant festival, [SCENE-1] we find <Leo>, a shy boy, standing at the edge of a bustling carnival, eyes wide with awe at the colorful rides and laughter, [SCENE-2] transitioning to him reluctantly trying a daring game, his friends cheering him on, [SCENE-3] culminating in a triumphant moment as he wins a giant stuffed bear, his face beaming with pride as he holds it up for all to see.
In-Context-LoRA | Flux 原生 |
---|---|
![]() |
|
![]() |
|
字体设计:
The four-panel image showcases a playful bubble font in a vibrant pop-art style. [TOP-LEFT] displays "Dev Ops AIGC" in bright pink with a polka dot background; [TOP-RIGHT] shows "Hello World" in purple, surrounded by candy illustrations; [BOTTOM-LEFT] has "By ali In-Context LoRA" in a mix of bright colors; [BOTTOM-RIGHT] shows "Wo, it cool" against a striped background, perfect for fun, kid-friendly products.
In-Context-LoRA | Flux 原生 |
---|---|
![]() |
|
![]() |
|
家居装饰:
This four-panel image showcases a rustic living room with warm wood tones and cozy decor elements; [TOP-LEFT] features a large stone fireplace with wooden shelves filled with books and candles; [TOP-RIGHT] shows a vintage leather sofa draped in plaid blankets, complemented by a mix of textured cushions; [BOTTOM-LEFT] displays a corner with a wooden armchair beside a side table holding a steaming mug and a classic book; [BOTTOM-RIGHT] captures a cozy reading nook with a window seat, a soft fur throw, and decorative logs stacked neatly.
In-Context-LoRA | Flux 原生 |
---|---|
![]() |
|
![]() |
|
人物摄影
This [FOUR-PANEL] image illustrates a young artist's creative process in a bright and inspiring studio; [TOP-LEFT] she stands before a large canvas, brush in hand, adding vibrant colors to a partially completed painting, [TOP-RIGHT] she sits at a cluttered wooden table, sketching ideas in a notebook with various art supplies scattered around, [BOTTOM-LEFT] she takes a moment to step back and observe her work, adjusting her glasses thoughtfully, and [BOTTOM-RIGHT] she experiments with different textures by mixing paints directly on the palette, her focused expression showcasing her dedication to her craft.
In-Context-LoRA | Flux 原生 |
---|---|
![]() |
|
![]() |
|
PPT模板
This four-panel image showcases a rustic-themed PowerPoint template for a culinary workshop; [TOP-LEFT] introduces "Farm to Table Cooking" in warm, earthy tones; [TOP-RIGHT] organizes workshop sections like "Ingredients," "Preparation," and "Serving"; [BOTTOM-LEFT] displays ingredient lists for seasonal produce; [BOTTOM-RIGHT] includes chef profiles with short bios.
In-Context-LoRA | Flux 原生 |
---|---|
![]() |
|
![]() |
|
沙尘暴视觉效果
[SANDSTORM-PSA] This two-part image showcases the transformation of a cyclist through a sandstorm visual effect; [TOP] the upper panel features a cyclist in vibrant gear pedaling steadily on a clear, open road with a serene sky in the background, highlighting focus and determination, [BOTTOM] the lower panel transforms the scene as the cyclist becomes enveloped in a fierce sandstorm, with sand particles swirling intensely around the bike and rider against a stormy, darkened backdrop, emphasizing chaos and power.
In-Context-LoRA | Flux 原生 |
---|---|
![]() |
|
![]() |
|
烟火视觉效果
[REAL-SPARKLERS-OVERLAYS] The two-part image vividly illustrates a woodland proposal transformed by sparkler overlays; [TOP] the first panel depicts a man kneeling on one knee with an engagement ring before his partner in a forest clearing at dusk, with warm, natural lighting, [BOTTOM] while the second panel introduces glowing sparklers that form a heart shape around the couple, amplifying the romance and joy of the moment.
In-Context-LoRA | Flux 原生 |
---|---|
![]() |
|
![]() |
|
视觉识别设计
The two-panel image showcases the joyful identity of a produce brand, with the left panel showing a smiling pineapple graphic and the brand name “Fresh Tropic” in a fun, casual font on a light aqua background; [LEFT] while the right panel translates the design onto a reusable shopping tote with the pineapple logo in black, held by a person in a market setting, emphasizing the brand’s approachable and eco-friendly vibe.
In-Context-LoRA | Flux 原生 |
---|---|
![]() |
|
![]() |
资料软件免费放送
次日同一发放请耐心等待
关于AI绘画技术储备
学好 AI绘画 不论是就业还是做副业赚钱都不错,但要学会 AI绘画 还是要有一个学习规划。最后大家分享一份全套的 AI绘画 学习资料,给那些想学习 AI绘画 的小伙伴们一点帮助!
感兴趣的小伙伴,赠送全套AIGC学习资料和安装工具,包含AI绘画、AI人工智能等前沿科技教程,模型插件,具体看下方。
需要的可以微信扫描下方CSDN官方认证二维码免费领取【保证100%免费】
**一、AIGC所有方向的学习路线**
AIGC所有方向的技术点做的整理,形成各个领域的知识点汇总,它的用处就在于,你可以按照下面的知识点去找对应的学习资源,保证自己学得较为全面。
二、AIGC必备工具
工具都帮大家整理好了,安装就可直接上手!
三、最新AIGC学习笔记
当我学到一定基础,有自己的理解能力的时候,会去阅读一些前辈整理的书籍或者手写的笔记资料,这些笔记详细记载了他们对一些技术点的理解,这些理解是比较独到,可以学到不一样的思路。
四、AIGC视频教程合集
观看全面零基础学习视频,看视频学习是最快捷也是最有效果的方式,跟着视频中老师的思路,从基础到深入,还是很容易入门的。
五、实战案例
纸上得来终觉浅,要学会跟着视频一起敲,要动手实操,才能将自己的所学运用到实际当中去,这时候可以搞点实战案例来学习。
这份完整版的学习资料已经上传CSDN,朋友们如果需要可以微信扫描下方CSDN官方认证二维码免费领取【保证100%免费】
更多推荐
所有评论(0)