Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Full connection configure failure #68

Closed
joey2014 opened this issue Apr 26, 2017 · 2 comments
Closed

Full connection configure failure #68

joey2014 opened this issue Apr 26, 2017 · 2 comments

Comments

@joey2014
Copy link

Test environment :
android M+ arm_compute v17.04
in some case, NEFullyConnectedLayer fails to configure. I provide two cases one is workable case and the other is failure case in attach code.
test.zip

build the test sample:
aarch64-linux-android-g++ fc_test1.cpp -std=c++11 -I. -pie -o test3 -Lbuild -larm_compute

terminate called after throwing an instance of 'std::runtime_error'
what(): in void arm_compute::Window::validate() const ./arm_compute/core/Window.inl:73: _dims[i].end() <= _dims[i].start()
Aborted

call stack
04-26 05:57:31.635 309 309 F DEBUG : #00 pc 000000000006a8e4 /system/lib64/libc.so (tgkill+8)
04-26 05:57:31.635 309 309 F DEBUG : #1 pc 0000000000068074 /system/lib64/libc.so (pthread_kill+68)
04-26 05:57:31.635 309 309 F DEBUG : #2 pc 0000000000020e08 /system/lib64/libc.so (raise+28)
04-26 05:57:31.635 309 309 F DEBUG : #3 pc 000000000001b5a8 /system/lib64/libc.so (abort+60)
04-26 05:57:31.635 309 309 F DEBUG : #4 pc 00000000001c07f4 /data/local/tmp/libarm_compute.so (_ZN9__gnu_cxx27__verbose_terminate_handlerEv+348)
04-26 05:57:31.635 309 309 F DEBUG : #5 pc 000000000016eb78 /data/local/tmp/libarm_compute.so (_ZN10__cxxabiv111__terminateEPFvvE+8)
04-26 05:57:31.635 309 309 F DEBUG : #6 pc 000000000016ebe4 /data/local/tmp/libarm_compute.so (_ZSt9terminatev+12)
04-26 05:57:31.635 309 309 F DEBUG : #7 pc 000000000016ed20 /data/local/tmp/libarm_compute.so (__cxa_throw+136)
04-26 05:57:31.635 309 309 F DEBUG : #8 pc 0000000000050340 /data/local/tmp/libarm_compute.so (_ZN11arm_compute5errorEPKcS1_iS1_z+320)
04-26 05:57:31.635 309 309 F DEBUG : #9 pc 000000000005158c /data/local/tmp/libarm_compute.so (_ZNK11arm_compute21AccessWindowRectangle23update_window_if_neededERNS_6WindowE+1068)
04-26 05:57:31.636 309 309 F DEBUG : #10 pc 00000000000e25c4 /data/local/tmp/libarm_compute.so (ZN11arm_compute25NEGEMMInterleave4x4Kernel9configureEPKNS_7ITensorEPS1+1216)
04-26 05:57:31.636 309 309 F DEBUG : #11 pc 000000000015d0c4 /data/local/tmp/libarm_compute.so (ZN11arm_compute21NEFullyConnectedLayer18configure_fc_fc_wbEPKNS_7ITensorES3_PS1+436)
04-26 05:57:31.636 309 309 F DEBUG : #12 pc 000000000015d858 /data/local/tmp/libarm_compute.so (_ZN11arm_compute21NEFullyConnectedLayer9configureEPKNS_7ITensorES3_S3_PS1_b+988)
04-26 05:57:31.636 309 309 F DEBUG : #13 pc 00000000000033bc /data/local/tmp/test3 (main+1464)

Can you help check the issue?

@cyberfire
Copy link

It looks that if change the failed code a little bit, it will work.
Move nefclayer2.configure(&neinput2,&neweights2,&nebiases2,&neoutput2,false);
just after the init stuffs().

printf("failure case:\n");
M_=2,N_=10,K_=60;
neinput2.allocator()->init(TensorInfo( TensorShape(K_,M_), Format::F32));
neweights2.allocator()->init(TensorInfo(TensorShape(N_,K_), Format::F32));
nebiases2.allocator()->init(TensorInfo(TensorShape(N_), Format::F32));
neoutput2.allocator()->init(TensorInfo(TensorShape(N_,M_), Format::F32));
nefclayer2.configure(&neinput2,&neweights2,&nebiases2,&neoutput2,false);
neinput2.allocator()->allocate();
neoutput2.allocator()->allocate();
neweights2.allocator()->allocate();
nebiases2.allocator()->allocate();
nefclayer2.run();

@mpflanzer
Copy link

Same issue as #67 You need to call configure() before allocating the tensors. Otherwise the padding cannot be increased.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants