Why x_data is 3 dimensions ?
CS2YU opened this issue · 1 comments
My data have 2 dimensions, data[0] means one sample, data[0][0] means first feature 's first data. i don't understand why x_data have 3 dimensions .
i can see, the program have
self.num_samples = x_data.shape[0]
self.num_features = x_data.shape[2]
so i know x_data have sample and feature, but another dimension is what ?
and i observed this x_data: predictor variables. shape (num_samples, x_dim, num_features) what is x_dim ?
The way it is written, the variables are 2 dimensional -- we represent length-n vectors with 1 by n arrays. This means that the data will be 3 dimensional, with the first dimension indicating sample size.
In the bullseye example, the variable x has dimension (1,6), and the variable y is scalar. So if we have 5000 samples, x_data has shape (5000, 1, 6), and y_data has shape (5000, 1).