SSD移植

1,報錯Check failed: label < num_classes (5 vs. 5)
打開train_tv_logo.prototxt搜索num_classes改爲9(8classes+1)

2,報錯Check failed: num_priors_ * num_classes_ == bottom[1]->channels() (62136 vs. 34520) .
理解:在multibox_loss_layer裏,有Number of priors must match number of confidence predictions這一句話,查到http://blog.csdn.net/u012235274/article/details/52212077裏面:
預測loction bottom[0] dimension is [N*C*1*1],confidence bottom[1] dimension is [N*C*1*1]
//priors bottom[2] dimension is [N*1*2*W], gound truth bottom[3] dimension is [N*1*H*8]
修改:train_tv_logo.prototxt1148行num_output=36和另外三個,36=4*9,4是一個cell裏面的priorbox數目,9是8class+背景class

3,報錯:Cannot copy param 0 weights from layer ‘fire8_norm_mbox_conf’; shape mismatch. Source param shape is 20 512 3 3 (92160); target param shape is 36 512 3 3 (165888). To learn this layer’s parameters from scratch rather than copying from a saved net, rename the layer.
在train.sh裏最後一行去掉-weights $WEIGHT

4,正常訓練,loss一直保持在6.9左右不下降
初始化有問題

5,test-train時候警告:Missing true_pos for label:

6,改變flip=true後:Check failed: num_priors_ * loc_classes_ * 4 == bottom[0]->channels() (41424 vs. 27616) Number of priors must match number of location predictions
需要把4個mbox_loc層的numoutput從16改成24(4*4->6*4)(test和train都要改)

7,Check failed: num_priors_ * num_classes_ == bottom[1]->channels() (51780 vs. 34520) Number of priors must match number of confidence predictions.

需要把4個mbox_conf層的numoutput從20改成30(4*5->6*5)(test和train都要改)

8,Check failed: 0 == bottom[0]->count() % explicit_count (0 vs. 2) bottom count (80430) must be divisible by the product of the specified dimensions (4)
test裏面reshape裏面的4改成5(test要改,train沒有)

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章