Reader small image

You're reading from  Hands-On Generative Adversarial Networks with Keras

Product typeBook
Published inMay 2019
Reading LevelIntermediate
PublisherPackt
ISBN-139781789538205
Edition1st Edition
Languages
Tools
Right arrow
Author (1)
Rafael Valle
Rafael Valle
author image
Rafael Valle

Rafael Valle is a research scientist at NVIDIA focusing on audio applications. He has years of experience developing high performance machine learning models for data/audio analysis, synthesis and machine improvisation with formal specifications. Dr. Valle was the first to generate speech samples from scratch with GANs and to show that simple yet efficient techniques can be used to identify GAN samples. He holds an Interdisciplinary PhD in Machine Listening and Improvisation from UC Berkeley, a Masters degree in Computer Music from the MH-Stuttgart in Germany and a Bachelors degree in Orchestral Conducting from UFRJ in Brazil.
Read more about Rafael Valle

Right arrow

Metrics

We are going to use the Jensen-Shannon divergence (JSD)and the Kolgomorov-Smirnov Two-Sample test for comparing real samples and samples generated with GANs. We are going to use the KS Two-Sample test implementation found on scipy.stats and ks_2samp.

Jensen-Shannon divergence

As we described in Chapter 2, Introduction to Generative Models, the JSD is a symmetric and smoothed version of the Kullback-Leibler divergence:

The implementation in Python is straightforward. First, we normally each distribution by dividing them by their respective norm such that the comparison is at the same scale. After normalizing the distributions, we compute the KL distance from P to M and Q to M, where M is the mean between the distributions...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Hands-On Generative Adversarial Networks with Keras
Published in: May 2019Publisher: PacktISBN-13: 9781789538205

Author (1)

author image
Rafael Valle

Rafael Valle is a research scientist at NVIDIA focusing on audio applications. He has years of experience developing high performance machine learning models for data/audio analysis, synthesis and machine improvisation with formal specifications. Dr. Valle was the first to generate speech samples from scratch with GANs and to show that simple yet efficient techniques can be used to identify GAN samples. He holds an Interdisciplinary PhD in Machine Listening and Improvisation from UC Berkeley, a Masters degree in Computer Music from the MH-Stuttgart in Germany and a Bachelors degree in Orchestral Conducting from UFRJ in Brazil.
Read more about Rafael Valle