NS之VGG(Keras):基于Keras的VGG16实现之《复仇者联盟3》灭霸图像风格迁移设计(A Neural Algorithm of Artistic Style)


勤恳爱睫毛
勤恳爱睫毛 2022-09-19 16:43:57 50219
分类专栏: 资讯

NS之VGG(Keras):基于Keras的VGG16实现之《复仇者联盟3》灭霸图像风格迁移设计(A Neural Algorithm of Artistic Style)

导读
通过代码设计,基于Keras的VGG16实现A Neural Algorithm of Artistic Style之灭霸风格迁移设计

目录

输出结果实现

核心代码


输出结果实现

灭霸风格素材


 

1、对我的偶像胡歌,下手……

  1. 22044672/58889256 [==========>...................] - ETA: 1:53
  2. 22077440/58889256 [==========>...................] - ETA: 1:53
  3. 22093824/58889256 [==========>...................] - ETA: 1:53
  4. 22126592/58889256 [==========>...................] - ETA: 1:52
  5. 22142976/58889256 [==========>...................] - ETA: 1:52
  6. 22183936/58889256 [==========>...................] - ETA: 1:52
  7. ……
  8. 58826752/58889256 [============================>.] - ETA: 0s
  9. 58859520/58889256 [============================>.] - ETA: 0s
  10. 58875904/58889256 [============================>.] - ETA: 0s
  11. 58892288/58889256 [==============================] - 250s 4us/step
  12. Model loaded.
  13. Start of iteration 0
  14. Current loss value: 2254528800.0
  15. Image saved as F:\File_Python\Python_example\fast_style_transfer_master\examples\results_at_iteration_0.png
  16. Iteration 0 completed in 252s
  17. Start of iteration 1
  18. Current loss value: 1771042400.0
  19. Image saved as F:\File_Python\Python_example\fast_style_transfer_master\examples\results_at_iteration_1.png
  20. Iteration 1 completed in 238s
  21. Start of iteration 2



2、其他风格迁移设计



核心代码

  1. Keras:基于Keras的VGG16实现A Neural Algorithm of Artistic Style
  2. from keras.preprocessing.image import load_img, img_to_array
  3. import numpy as np
  4. from scipy.misc import imsave
  5. from scipy.optimize import fmin_l_bfgs_b
  6. import time
  7. from keras.applications.vgg16 import VGG16
  8. from keras.applications.vgg16 import preprocess_input
  9. from keras import backend as K
  10. import os
  11. References
  12. - [A Neural Algorithm of Artistic Style](http://arxiv.org/abs/1508.06576)
  13. '''
  14. base_image_path=r'F:\File_Python\Python_example\fast_style_transfer_master\examples\content\20180214(21).jpg'
  15. style_reference_image_path=r'F:\File_Python\Python_example\fast_style_transfer_master\examples\style\mieba02.jpg'
  16. result_prefix=r'F:\File_Python\Python_example\fast_style_transfer_master\examples\results'
  17. iterations=10
  18. content_weight=0.025
  19. style_weight=1.0
  20. total_variation_weight=1.0

网站声明:如果转载,请联系本站管理员。否则一切后果自行承担。

本文链接:https://www.xckfsq.com/news/show.html?id=3679
赞同 0
评论 0 条
勤恳爱睫毛L0
粉丝 0 发表 6 + 关注 私信
上周热门
如何使用 StarRocks 管理和优化数据湖中的数据?  2941
【软件正版化】软件正版化工作要点  2860
统信UOS试玩黑神话:悟空  2819
信刻光盘安全隔离与信息交换系统  2712
镜舟科技与中启乘数科技达成战略合作,共筑数据服务新生态  1246
grub引导程序无法找到指定设备和分区  1213
华为全联接大会2024丨软通动力分论坛精彩议程抢先看!  163
点击报名 | 京东2025校招进校行程预告  162
2024海洋能源产业融合发展论坛暨博览会同期活动-海洋能源与数字化智能化论坛成功举办  160
华为纯血鸿蒙正式版9月底见!但Mate 70的内情还得接着挖...  157
本周热议
我的信创开放社区兼职赚钱历程 40
今天你签到了吗? 27
信创开放社区邀请他人注册的具体步骤如下 15
如何玩转信创开放社区—从小白进阶到专家 15
方德桌面操作系统 14
我有15积分有什么用? 13
用抖音玩法闯信创开放社区——用平台宣传企业产品服务 13
如何让你先人一步获得悬赏问题信息?(创作者必看) 12
2024中国信创产业发展大会暨中国信息科技创新与应用博览会 9
中央国家机关政府采购中心:应当将CPU、操作系统符合安全可靠测评要求纳入采购需求 8

加入交流群

请使用微信扫一扫!