A data representation is a particular way to encode or view data. The same information can become easier or harder to use depending on the representation chosen for the task. section 1.4
One image, two useful representations
A color image can use RGB or HSV values. Selecting red pixels is simpler in RGB, while reducing saturation is simpler in HSV. The data stays the same; its encoding changes to suit the task. section 1.4
Machine learning learns representations that transform inputs into outputs useful for a goal. In deep networks, early visual representations retain much of the image and detect edges; deeper representations become more abstract, encoding concepts such as cat ears and cat eyes while discarding irrelevant visual detail. section 1.4 section 10.1
Representations can be examined at several levels:
- Input representation: raw values such as image pixels or point coordinates. section 1.4
- Intermediate representation: layer activations that expose features detected by a neural network. section 10.1
- Higher representation: increasingly abstract features carrying more information about the target and less about the exact input. section 10.1
Listing 10.6 Visualizing every channel in every intermediate activation
for (layer_name in names(activations)) { #1
layer_activation <- activations[[layer_name]]
.[.., n_features] <- dim(layer_activation) #2
par(mfrow = n2mfrow(n_features, asp = 1.75), #3
mar = rep(.1, 4), oma = c(0, 0, 1.5, 0)) #3
for (j in 1:n_features) #4
plot_activations(layer_activation[, , , j]) #4
title(main = layer_name, outer = TRUE) #5
}
Visualize every channel in each intermediate activation to compare how a convolutional network changes its representation across layers. section 10.1



