gpt4 book ai didi

machine-learning - 使用 nolearn\lasagne 制作神经网络来绘制图像(又名 Google 的 inceptionism)

转载 作者:行者123 更新时间:2023-11-30 08:52:27 25 4
gpt4 key购买 nike

可能很多人已经看过 Google 研究的这篇文章:

http://googleresearch.blogspot.ru/2015/06/inceptionism-going-deeper-into-neural.html

它描述了 Google 团队如何创建神经网络来实际绘制图片,就像人工艺术家一样:)

我想做一些类似的事情,只是为了看看它是如何工作的,也许将来会使用它来更好地了解是什么导致我的网络失败。问题是 - 如何使用 nolearn\lasagne (或者也许 pybrain - 它也可以工作,但我更喜欢 nolearn)来实现它。

更具体地说,Google 的人员使用某种架构训练了一个 ANN 来对图像进行分类(例如,对照片上的鱼进行分类)。好吧,假设我有一个用 nolearn 构建的具有某种架构的 ANN,并且我已经进行了一定程度的训练。但是……接下来该怎么办?我从他们的文章中没有得到它。他们似乎不只是可视化某些特定层的权重。在我看来(也许我错了)他们做了以下两件事之一:

1) 将一些现有图像或纯粹的随机噪声馈送到经过训练的网络中,并将其中一个神经元层的激活可视化。但是 - 看起来并不完全正确,因为如果他们使用卷积神经网络,层的维度可能会低于原始图像的维度

2) 或者他们向经过训练的 ANN 提供随机噪声,从其中一个中间层获取中间输出并将其反馈到网络中 - 获得某种循环并检查神经网络层认为可能存在的内容在随机噪声中。但同样,由于与 #1 中相同的维度问题,我可能是错的

所以...对此有什么想法吗?我们如何使用 nolearn 或 pybrain 做与 Google 在原始文章中所做的类似的事情?

最佳答案

From their ipython notebook on github :

Making the "dream" images is very simple. Essentially it is just a gradient ascent process that tries to maximize the L2 norm of activations of a particular DNN layer. Here are a few simple tricks that we found useful for getting good images:

  • offset image by a random jitter
  • normalize the magnitude of gradient
  • ascent steps apply ascent across multiple scales (octaves)

关于machine-learning - 使用 nolearn\lasagne 制作神经网络来绘制图像(又名 Google 的 inceptionism),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31192859/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com