Hello,
I have successfully completed the tutorials here,
but when I try to run the snpe-sample application on the rb5 (it works on the host pc) I get the following Segmentation fault:
sh-4.4# export SNPE_TARGET_ARCH=aarch64-linux-gcc4.9
sh-4.4# cd /data/local/tmp/alexnet
xt --use_gpu-net-run --container bvlc_alexnet.dlc --input_list target_raw_list.tx
-------------------------------------------------------------------------------
Model String: N/A
SNPE v1.50.0.2622
-------------------------------------------------------------------------------
Processing DNN input(s):
cropped/notice_sign.raw
Processing DNN input(s):
cropped/trash_bin.raw
Processing DNN input(s):
cropped/plastic_cup.raw
Processing DNN input(s):
cropped/chairs.raw
snpepe-sample -b ITENSOR -d bvlc_alexnet.dlc -i target_raw_list.txt -o outpput_sample
Segmentation fault (core dumped)
It may have to do with how I compile the snpe-sample application for the rb5, which is as follows:
export SNPE_TARGET_ARCH=aarch64-linux-gcc4.9
export SNPE_TARGET_STL=libc++_shared.so
export SNPE_ROOT=snpe-1.50.0.2622
echo $SNPE_ROOT
export PATH=$PATH:$SNPE_ROOT/examples/NativeCpp/SampleCode/obj/local/$SNPE_TARGET_ARCH/
echo $PATH
export LD_LIBRARY_PATH=$SNPE_ROOT/lib/$SNPE_TARGET_ARCH:$SNPE_ROOT/examples/NativeCpp/SampleCode/obj/local/$SNPE_TARGET_ARCH
ls $SNPE_ROOT/lib/$SNPE_TARGET_ARCH
echo $LD_LIBRARY_PATH
cd $SNPE_ROOT/examples/NativeCpp/SampleCode
export CXX=aarch64-linux-gnu-g++
make -f Makefile.$SNPE_TARGET_ARCH
What makefile and compiler should I use for the rb5?
(currently using:
aarch64-linux-gnu-g++
Actually, the sample application compilesadn snpe-sample -h runs correcty on the target, but fails with
when executing a model.
How would you execute the inceptio_V3 model for exampl with snpe-sample?
I tried:
Thanks in advance
I have tried the following combinations:
snpe-sample -r cpu -b USERBUFFER_FLOAT -d data/inception_v3/inception_v3.dlc -i data/inception_v3/target_raw_list.txt -o data/inception_v3/output
snpe-sample -r cpu -b ITENSOR -d data/inception_v3/inception_v3.dlc -i data/inception_v3/target_raw_list.txt -o data/inception_v3/output
snpe-sample -r dsp -b USERBUFFER_FLOAT -d data/inception_v3/inception_v3.dlc -i data/inception_v3/target_raw_list.txt -o data/inception_v3/output
snpe-sample -r dsp -b ITENSOR -d data/inception_v3/inception_v3.dlc -i data/inception_v3/target_raw_list.txt -o data/inception_v3/output
snpe-sample -r aip -b USERBUFFER_FLOAT -d data/inception_v3/inception_v3.dlc -i data/inception_v3/target_raw_list.txt -o data/inception_v3/output
snpe-sample -r aip -b ITENSOR -d data/inception_v3/inception_v3.dlc -i data/inception_v3/target_raw_list.txt -o data/inception_v3/output
And I am getting the following errors saying that the dsp and aip runtimes are not present:
However, I used the benchmarking tool and it was able to execute models on the dsp, so what may be causing this?
Following from the above, I tried using the dlc models prepared for the dsp and aip runtimes via the
and
commands.
And after pushing the model to the RB5 target; I ran:
and got:
and ran:
and got:
Why would the dsp not work on the RB5 and how could I ensure all realtimes are up and working?
Thanks,
Hello,
I can confirm that the exact same snpe-sample approach is working for me on the
but not on the RB5
I get
with
for the RB5,
where I compile it as follows:
PLEASE HELP ME UNDERSTAND WHY AND HOW I COULD RESOLVE THIS.
Thanks
hello customer,
I will check with our AI team
Hello Mita,
That would be great. Do we have any updates from the AI team? How do they compile the app in https://developer.qualcomm.com/sites/default/files/docs/snpe/cplus_plus_... for the RB5?
Thanks in advance!
Hi Customer,
In the SNPE directory:snpe-1.51/examples/NativeCpp/SampleCode
There is a Makefile:Makefile.aarch64-ubuntu-gcc7.5
Please try this one.
even if there is issue please send us log file on [email protected]
Regards,
Mita
Hello Mita,
Thank you very much for your answer.
If I compile snpe-sample with
and the following:
I get this error:
Which CXX should I export? (I currently export CXX=g++ to build for aarch64-ubuntu-gcc7.5)
Thanks for your continuous support, it is very much appreciated.
Hello,
The problem seems to be cross compiling:
If I compile with Makefile.aarch64-ubuntu-gcc7.5 on the Host computer, it fails with the error in the comment above.
If I compile with Makefile.aarch64-ubuntu-gcc7.5 on the RB5 directly, it builds as follows:
Build commands:
Build Log:
How can I cross compile and build the application on the Host PC and only transfer the binaries to the RB5?
Thank you in advance.