Prompt-to-Prompt Image Editing with Cross Attention Control

  1. 问题引入
  • 通过manipulate cross attn map的方式来实现图片编辑的任务;
  1. methods
  • 编辑前后的图片以及prompt I , I ∗ , P , P ∗ I,I^*,P,P^* I,I∗,P,P∗,在cross attn中,pixel feature ϕ ( z t ) \phi(z_t) ϕ(zt)得到 Q = l Q ( ϕ ( z t ) ) Q = l_Q(\phi(z_t)) Q=lQ(ϕ(zt)), K = l K ( ψ ( P ) ) , v = l V ( ψ ( P ) ) K = l_K(\psi(P)),v = l_V(\psi(P)) K=lK(ψ(P)),v=lV(ψ(P)),得到atten map M M M,其中 M i j M_{ij} Mij表示的是 j − t h j-th j−th的token和pixel i i i之间的关系;
  • 编辑的算法如下:
  • 其中 E d i t ( M t , M t ∗ , t ) Edit(M_t,M_t^*,t) Edit(Mt,Mt∗,t)根据任务不同定义如下:
  • word swap:
  • Adding a New Phrase:
  • Attention Re--weighting:
相关推荐
梵得儿SHI8 小时前
Prompt Engineering 核心知识:从基础模式到思维链,掌握大模型高效交互秘籍
大模型·prompt·交互·提示词·对话·大模型提问艺术·极简指令
jimmyleeee8 小时前
人工智能基础知识笔记十八:Prompt Engineering
笔记·prompt
非晓为骁1 天前
AI-Native 能力反思(三):Prompt Engineering 自我提升神器
人工智能·ai·prompt·ai-native·提示词工程
猫头虎4 天前
Paper2Agent:将科研论文转化为可交互的AI智能体工具项目
人工智能·prompt·aigc·交互·pip·agi·ai-native
声网4 天前
阿里发布「夸克 AI 眼镜」:融合阿里购物、地图、支付生态;苹果拟收购计算机视觉初创 Prompt AI丨日报
人工智能·计算机视觉·prompt
Wade_Crab5 天前
第二章:动态 Prompt 管理与多科室智能问答系统
人工智能·spring·prompt
Fuly10247 天前
prompt构建技巧
人工智能·prompt
为java加瓦7 天前
前端学AI:如何写好提示词(prompt)
前端·人工智能·prompt
猫头虎8 天前
HAMi 2.7.0 发布:全面拓展异构芯片支持,优化GPU资源调度与智能管理
嵌入式硬件·算法·prompt·aigc·embedding·gpu算力·ai-native