Reader small image

You're reading from  Generative Adversarial Networks Cookbook

Product typeBook
Published inDec 2018
PublisherPackt
ISBN-139781789139907
Edition1st Edition
Right arrow
Author (1)
Josh Kalin
Josh Kalin
author image
Josh Kalin

Josh Kalin is a Physicist and Technologist focused on the intersection of robotics and machine learning. Josh works on advanced sensors, industrial robotics, machine learning, and automated vehicle research projects. Josh holds degrees in Physics, Mechanical Engineering, and Computer Science. In his free time, he enjoys working on cars (has owned 36 vehicles and counting), building computers, and learning new techniques in robotics and machine learning (like writing this book).
Read more about Josh Kalin

Right arrow

Training the simGAN network


Now that we've built the infrastructure, we can develop the training methodology in the train script. In this section, we'll also create the run python and shell scripts that will be used for running everything in the Docker environment.

Getting ready

We're almost at the end! So, make sure you have every one of the following directories and files in your $HOME directory:

├── data
├── docker
│   ├── build.sh
│   ├── clean.sh
│   ├── Dockerfile
│   └── kaggle.json
├── out
│   ├── GAN_Model.png
│   └── Generator_Model.png
├── README.md
├── run.sh
└── src
    ├── discriminator.py
    ├── gan.py
    ├── generator.py
    ├── loss.py
    ├── run.py
    └── train.py

How to do it...

The training script will read in data, process the data for input into the networks, and then train the simGAN model.

Initialization

Take the following steps to initialize the training class and the basic functionality needed to train the models:

 

 

  1. Create a train.py file and place the following imports...
lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Generative Adversarial Networks Cookbook
Published in: Dec 2018Publisher: PacktISBN-13: 9781789139907

Author (1)

author image
Josh Kalin

Josh Kalin is a Physicist and Technologist focused on the intersection of robotics and machine learning. Josh works on advanced sensors, industrial robotics, machine learning, and automated vehicle research projects. Josh holds degrees in Physics, Mechanical Engineering, and Computer Science. In his free time, he enjoys working on cars (has owned 36 vehicles and counting), building computers, and learning new techniques in robotics and machine learning (like writing this book).
Read more about Josh Kalin