Top AI Repos — open-source AI, indexed and scored
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
Code for paper "Synthesizing the preferred inputs for neurons in neural networks via deep generator networks"
| Date | Stars |
|---|---|
| 2026-07-31 | 471 |
| 2026-08-05 | 471 |
| 2026-08-06 | 471 |
Today
— stars today
This week
— stars this week
This month
— stars this month
Momentum
0.0
growth rate 0.00%/day
## Synthesizing preferred inputs via deep generator networks
This repository contains source code necessary to reproduce some of the main results in the paper:
[Nguyen A](http://anhnguyen.me), [Dosovitskiy A](http://lmb.informatik.uni-freiburg.de/people/dosovits/), [Yosinski J](http://yosinski.com/), [Brox T](http://lmb.informatik.uni-freiburg.de/people/brox/index.en.html), [Clune J](http://jeffclune.com). (2016). ["Synthesizing the preferred inputs for neurons in neural networks via deep generator networks."](http://arxiv.org/abs/1605.09304). NIPS 29
**If you use this software in an academic article, please cite:**
@article{nguyen2016synthesizing,
title={Synthesizing the preferred inputs for neurons in neural networks via deep generator networks},
author={Nguyen, Anh and Dosovitskiy, Alexey and Yosinski, Jason band Brox, Thomas and Clune, Jeff},
journal={NIPS 29},
year={2016}
}
For more information regarding the paper, please visit www.evolvingai.org/synthesizing
## Setup
### Installing software
This code is built on top of Caffe. You'll need to install the following:
* Install Caffe; follow the official [installation instructions](http://caffe.berkeleyvision.org/installation.html).
* Build the Python bindings for Caffe
* If you have an NVIDIA GPU, you can optionally build Caffe with the GPU option to make it run faster
* Make sure the path to your `caffe/python` folder in [settings.py](settings.py) is correct
* Install [ImageMagick](http://www.imagemagick.org/script/binary-releases.php) command-line interface on your system.
### Downloading models
You will need to download a few models. There are `download.sh` scripts provided for your convenience.
* The image generation network (Upconvolutional network) from [3]. You can download directly on their [website](https://github.com/anguyen8/upconv_release) or using the provided script `cd nets/upconv && ./download.sh`
* A network being visualized (e.g. from Caffe software package or Caffe Model Zoo). The provided examples use these models:
* [BVLC reference CaffeNet](https://github.com/BVLC/caffe/tree/master/models/bvlc_reference_caffenet): `cd nets/caffenet && ./download.sh`
* [BVLC GoogLeNet](https://github.com/BVLC/caffe/tree/master/models/bvlc_googlenet): `cd nets/googlenet && ./download.sh`
* [AlexNet CNN trained on MIT Places dataset](http://places.csail.mit.edu/): `cd nets/placesCNN && ./download.sh`
Settings:
* Paths to the downloaded models are in [settings.py](settings.py). They are relative and should work if the `download.sh` scripts run correctly.
* The paths to the model being visualized can be overriden by providing arguments `net_weights` and `net_definition` to [act_max.py](act_max.py).
## Usage
The main algorithm is in [act_max.py](act_max.py), which is a standalone Python script; you can pass various command-line arguments to run different experiments. Basically, to synthesize a preferred input for a target neuron *h* (e.g. the “candle” class output neuron), we optimize the hidden code input (red) of a [deep image generator network](https://arxiv.org/abs/1602.02644) to produce an image that highly activates *h*.
<p align="center">
<img src="http://anhnguyen.me/wp-content/uploads/2017/03/160531__arxiv_main_concept-1024x445.jpg" width=600px>
</p>
### Examples
We provide here four different examples as a starting point. Feel free to be creative and fork away to produce even cooler results!
[1_activate_output.sh](1_activate_output.sh): Optimizing codes to activate *output* neurons of the [CaffeNet DNN](https://github.com/BVLC/caffe/tree/master/models/bvlc_reference_caffenet) trained on ImageNet dataset. This script synthesizes images for 5 example neurons.
* Running `./1_activate_output.sh` produces this result:
<p align="center">
<img src="examples/example1.jpg" width=600px>
</p>
[2_activate_output_placesCNN.sh](2_activate_output_placesCNN.sh): Optimizing codes to activate *output* neurons of a differenExcerpt of 8,287 characters
Read on GitHubWould you bet a product on this? Bounded 0–100 and slow moving.
matched fp:d2865f9bbff2b5c9, topic:neural-network