yjxiong / temporal-segment-networks

Code & Models for Temporal Segment Networks (TSN) in ECCV 2016
BSD 2-Clause "Simplified" License
1.54k stars 477 forks source link

concat_layer check failed for bn_inception_flow model using docker built caffe #232

Closed kaidic closed 6 years ago

kaidic commented 6 years ago

Though the bn-inception rgb model works fine, I find the forward path broke when testing bn-inception flow model using the caffe built in docker.

The message goes as follows,

F0913 09:02:46.497457  4037 concat_layer.cpp:43] Check failed: top_shape[j] == bottom[i]->shape(j) (11 vs. 10) All inputs must have the same shape, except at concat_axis.

Could you give me any hint on how to fix this broken problem. Thanks.

yjxiong commented 6 years ago

Testing of Caffe models should not have a problem in different environments. The error you have seen mostly happens when the input size is not 224x224, for example, where you happened to put in a 200x224 input. So I would suggest you check your entire network construction log and see what is your network's input size.

kaidic commented 6 years ago

Thanks a lot for your reply. I found out where the problem is. In function predict_single_flow_stack() I set over_sample=False each frame is not cropped and the input_size is 256340 in this case. I thought it was right initially but now I understand that it should be 244244 instead. However I have another question here, I noticed that for inception_v3 model input size is 299*299, how did you do preprocessing for inception_v3 model. Thanks.

yjxiong commented 6 years ago

You can specify input size to the predict functions.