https://github.com/hwalsuklee/tensorflow-gan-1d-gaussian-ex
Tensorflow implementation of Generative Adversarial Network for approximating a 1D Gaussian distribution
https://github.com/hwalsuklee/tensorflow-gan-1d-gaussian-ex
1d-gaussian gan generative-adversarial-networks tensorflow tutorial
Last synced: 6 months ago
JSON representation
Tensorflow implementation of Generative Adversarial Network for approximating a 1D Gaussian distribution
- Host: GitHub
- URL: https://github.com/hwalsuklee/tensorflow-gan-1d-gaussian-ex
- Owner: hwalsuklee
- Created: 2017-03-08T11:56:42.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-04-17T06:15:45.000Z (over 8 years ago)
- Last Synced: 2025-03-27T01:23:00.545Z (6 months ago)
- Topics: 1d-gaussian, gan, generative-adversarial-networks, tensorflow, tutorial
- Language: Python
- Homepage:
- Size: 583 KB
- Stars: 25
- Watchers: 3
- Forks: 8
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Generative Adversarial Network for approximating a 1D Gaussian distribution
Tensorflow implementation of Generative Adversarial Network for approximating a 1D Gaussian distribution.## Results
Desirable result of GAN is to have decision boundary (db) of one-half and probability distribution function (pdf) of generated data similar to the original pdf.
Through the following images, you can see that all of results for various 1D Gaussian distributions are well shaped.
On the other hand, code in two references does not give stable results when changing mean, sigma, or seed.
Please check it out for yourself.mean = -1
mean = +1stdev = 0.7
![]()
stdev = 1.0
![]()
stdev = 2.0
![]()
## References
The implementation is based on the projects:
[1] Project by Eric Jang : [BLOG](http://blog.evjang.com/2016/06/generative-adversarial-nets-in.html), [CODE](https://github.com/ericjang/genadv_tutorial)
[2] Project by John Glober : [BLOG](http://blog.aylien.com/introduction-generative-adversarial-networks-code-tensorflow/), [CODE](https://github.com/AYLIEN/gan-intro)## Implementation Details
### Network architecture
Fully-connected neural network with 1 hidden layer.Generator
DiscriminatorInput layer
1 node
1 nodeHidden layer
32 nodes + relu
32 nodes + reluOutput layer
1 node
1 node + sigmoid### Pre-training
Discriminator is pre-trained with pdf of the orginal data in both two references.
In real situation, we don't know about the pdf of the original data. Actually, that is what we want know.
*Estimated* pdf of the original data is used to pre-train discriminator in this implementation.## Acknowledgements
This implementation has been tested with Tensorflow r0.12 on Windows 10 and Ubuntu 14.04.