August 2018
Intermediate to advanced
522 pages
12h 45m
English
The option to compute the gradients of all output tensors with respect to any connected input or node is one of the most interesting features of TensorFlow, because it allows us to create learning algorithms without worrying about the complexity of all transformations. In this example, we first define a linear dataset representing the function f(x) = x in the range (-100, 100):
import numpy as npnb_points = 100X = np.linspace(-nb_points, nb_points, 200, dtype=np.float32)
The corresponding plot is shown in the following graph:

Now we want to use TensorFlow to compute the following:
Read now
Unlock full access