Hi. Trying to use your full_yolo_features.h5 which I believe are pretrained weights from ImageNet (or maybe something else?) as the basis for the weights of all the layers before the last couple+softmax.
Unsure what I'm doing wrong - I think the model that's built isn't being isn't separating the layers properly?
Also, I'm trying to use this to train on VOC2007. What does the program do about boxes with labels that aren't included in the "labels" key in the config.json?
Included a snippet from my config.json as well as my console.
"model" : {
"architecture": "Full Yolo",
"input_size": 416,
"anchors": [0.57273, 0.677385, 1.87446, 2.06253, 3.33843, 5.47434, 7.88282, 3.52778, 9.77052, 9.16828],
"max_box_per_image": 10,
"labels": ["aeroplane","bicycle","bird","boat","bottle","bus","car","cat","chair","cow","diningtable","dog","horse","motorbike","person","pottedplant","sheep","sofa","train","tvmonitor"]
},
vivekme-mac02:basic-yolo-keras vivekme$ python train.py -c config.json
Using TensorFlow backend.
2017-11-02 10:56:49.309727: I tensorflow/core/platform/cpu_feature_guard.cc:137] Your CPU supports instructions that this TensorFlow binary was not compiled to use: SSE4.2 AVX
(13, 13)
____________________________________________________________________________________________________
Layer (type) Output Shape Param # Connected to
====================================================================================================
input_1 (InputLayer) (None, 416, 416, 3) 0
____________________________________________________________________________________________________
model_1 (Model) (None, 13, 13, 1024) 50547936 input_1[0][0]
____________________________________________________________________________________________________
conv_23 (Conv2D) (None, 13, 13, 125) 128125 model_1[1][0]
____________________________________________________________________________________________________
reshape_1 (Reshape) (None, 13, 13, 5, 25) 0 conv_23[0][0]
____________________________________________________________________________________________________
input_2 (InputLayer) (None, 1, 1, 1, 10, 4 0
____________________________________________________________________________________________________
lambda_2 (Lambda) (None, 13, 13, 5, 25) 0 reshape_1[0][0]
input_2[0][0]
====================================================================================================
Total params: 50,676,061
Trainable params: 50,655,389
Non-trainable params: 20,672
____________________________________________________________________________________________________
Loading pre-trained weights in full_yolo_features.h5
Traceback (most recent call last):
File "train.py", line 134, in <module>
_main_(args)
File "train.py", line 111, in _main_
yolo.load_weights(config['train']['pretrained_weights'])
File "/Users/vivekme/workspace/basic-yolo-keras/frontend.py", line 228, in load_weights
self.model.load_weights(weight_path)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/keras/engine/topology.py", line 2619, in load_weights
load_weights_from_hdf5_group(f, self.layers)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/keras/engine/topology.py", line 3068, in load_weights_from_hdf5_group
str(len(filtered_layers)) + ' layers.')
ValueError: You are trying to load a weight file containing 44 layers into a model with 2 layers.