August 2018
Intermediate to advanced
272 pages
7h 2m
English
Let's go into detail through the build_graph function that contains the network definition, the loss function, and the optimizer used. First, we start the function by defining the placeholders for our inputs. We will use two placeholders to supply data and labels into the graph: __x_ and __y_. The placeholder __x_ will hold our input RGB images, while the placeholder __y_ stores one hot labels of corresponding classes. We use None when defining the N part of the placeholder shape, as this tells TensorFlow that this value can be anything and will be supplied when we execute the graph:
def build_graph(self): self.__x_ = tf.placeholder("float", shape=[None, 32, 32, 3], name='X') self.__y_ = tf.placeholder("int32", shape=[None, ...Read now
Unlock full access