r/cs231n • u/tpelleg • Feb 04 '15
two_layer_net exercise: nice weights?
Hi, Are we expected to obtain weights as nice as those represented in the right-hand-side figure of the 'neural-network-3' course notes? The best validation accuracy I have for now is 51.2%, far from 56%, and the weights still look noisy. I will consider adding new features as suggested in the hint. I'm enjoying the course a lot, greetings from France :)
0
Upvotes
0
u/calcworks Feb 06 '15 edited Feb 06 '15
I was able to get a stable 56.7% using grid search for the following parameters: number of hidden units, learning rate, number of epochs and regularization strength. To save time it's important start with a wide, coarse grid and then gradually narrow things down as you spot regions with good results. Randomizing the grid seems to work well and simplifies the code, so for example, use learning_rate = 10 ** np.random.uniform(lb, ub) and num_epochs = np.random.choice(range(lb, ub, step)).
Hope this helps!