caffe icon indicating copy to clipboard operation
caffe copied to clipboard

I0425 10:13:21.205826 9167 solver.cpp:208] Iteration 220, lr = 0.01 I0425 10:13:21.206111 9167 solver.cpp:65] Iteration 220, loss = nan

Open lixyresearch opened this issue 12 years ago • 2 comments

I0425 10:12:49.611122 9167 solver.cpp:65] Iteration 180, loss = 6.55607 I0425 10:13:04.672341 9167 solver.cpp:208] Iteration 200, lr = 0.01 I0425 10:13:04.672637 9167 solver.cpp:65] Iteration 200, loss = 6.55622 I0425 10:13:04.978760 9167 solver.cpp:130] Snapshotting to caffe_dishll_train_iter_200 I0425 10:13:05.657246 9167 solver.cpp:137] Snapshotting solver state to caffe_dishll_train_iter_200.solverstate I0425 10:13:21.205826 9167 solver.cpp:208] Iteration 220, lr = 0.01 I0425 10:13:21.206111 9167 solver.cpp:65] Iteration 220, loss = nan

lixyresearch avatar Apr 25 '14 02:04 lixyresearch

It's hard to know exactly what the problem is with so little information, but in general neural network training can diverge and you can get NaNs when this happens*. you might try setting the learning rate to a lower value, increasing batch size, and/or increasing momentum.

*On a related note, perhaps Caffe should crash when the solver sees a NaN loss as we can't really do anything useful at that point.

jeffdonahue avatar Apr 26 '14 23:04 jeffdonahue

@jeffdonahue Agreed for death on NaN loss.

Sorry for your loss @lxycnu.

On Sat, Apr 26, 2014 at 4:08 PM, Jeff Donahue [email protected]:

It's hard to know exactly what the problem is with so little information, but in general neural network training can diverge and you can get NaNs when this happens*. you might try setting the learning rate to a lower value, increasing batch size, and/or increasing momentum.

*On a related note, perhaps Caffe should crash when the solver sees a NaN loss as we can't really do anything useful at that point.

— Reply to this email directly or view it on GitHubhttps://github.com/BVLC/caffe/issues/361#issuecomment-41483711 .

shelhamer avatar Apr 26 '14 23:04 shelhamer