Shapes of blobs produced by InnerProductLayer and MemoryDataLayer do not match

137 views
Skip to first unread message

Ziyu Wang

unread,
Jul 2, 2015, 10:59:32 AM7/2/15
to caffe...@googlegroups.com
Hi,

I'm trying to pass the output of InnerProductLayer and MemoryDataLayer to a EltwiseLayer.

The problem is that the top shape of InnerProductLayer is (n, channels), while the top shape of MemoryDataLayer is (n, channels, 1, 1) (I set w=h=1 in model definition ). Caffe seems to think that the two shapes are different, and an assertion fails when creating the EltwiseLayer.

So how can it be fixed? Thanks in advance.

Part of the log file (the network definition and full log is attached):
I0702 22:30:18.717506 22613 net.cpp:90] Creating Layer IP5
I0702 22:30:18.717509 22613 net.cpp:410] IP5 <- I4R
I0702 22:30:18.717511 22613 net.cpp:368] IP5 -> output
I0702 22:30:18.717515 22613 net.cpp:120] Setting up IP5
I0702 22:30:18.717578 22613 net.cpp:127] Top shape: 32 18 (576)
I0702 22:30:18.717584 22613 layer_factory.hpp:74] Creating layer SELData
I0702 22:30:18.717589 22613 net.cpp:90] Creating Layer SELData
I0702 22:30:18.717592 22613 net.cpp:368] SELData -> SelData
I0702 22:30:18.717597 22613 net.cpp:368] SELData -> dummy2
I0702 22:30:18.717600 22613 net.cpp:120] Setting up SELData
I0702 22:30:18.717607 22613 net.cpp:127] Top shape: 32 18 1 1 (576)
I0702 22:30:18.717609 22613 net.cpp:127] Top shape: 32 (32)
I0702 22:30:18.717612 22613 layer_factory.hpp:74] Creating layer SEL
I0702 22:30:18.717617 22613 net.cpp:90] Creating Layer SEL
I0702 22:30:18.717618 22613 net.cpp:410] SEL <- output
I0702 22:30:18.717622 22613 net.cpp:410] SEL <- SelData
I0702 22:30:18.717624 22613 net.cpp:368] SEL -> FilteredData
I0702 22:30:18.717630 22613 net.cpp:120] Setting up SEL
F0702 22:30:18.717639 22613 eltwise_layer.cpp:35] Check failed: bottom[i]->shape() == bottom[0]->shape() 


AtariDL.INFO1

deep.learn...@gmail.com

unread,
Aug 20, 2015, 2:48:08 PM8/20/15
to Caffe Users
Hi,

I am experiencing with the same error message. Did you find the solution?

Thanks.
Reply all
Reply to author
Forward
0 new messages