Hands-On Neural Networks with Keras
上QQ阅读APP看书,第一时间看更新

Plotting a single training instance

As we can see, there are 25,000 training and test samples. We can also plot out an individual training sample to see how we can represent a single review. Here, we can see that each review simply contains a list of integers, where each integer corresponds to a word in a dictionary:

x_train[1]

[1, 194, 1153, 194, 8255, 78, 228, 5, 6, 1463, 4369, 5012, 134, 26, 4, 715, 8, 118, 1634, 14, 394, 20, 13, 119, 954,