October 2018
Intermediate to advanced
472 pages
10h 57m
English
We will define all of the required hyperparameters in the hy_param.py file and then import it as a module in our other codes. This makes it easy in deployment, and is good practice to make your code as modular as possible. Let's look into the hyperparameter configurations that we have in our hy_param.py file:
#!/usr/bin/env python2# Hyperparameters and all other kind of params# Parameterslearning_rate = 0.01num_steps = 100batch_size = 128display_step = 1# Network Parametersn_hidden_1 = 300 # 1st layer number of neuronsn_hidden_2 = 300 # 2nd layer number of neuronsnum_input = 784 # MNIST data input (img shape: 28*28)num_classes = 10 # MNIST total classes (0-9 digits)#Training Parameterscheckpoint_every = 100checkpoint_dir ...
Read now
Unlock full access