ARM-software / armnn

Arm NN ML Software. The code here is a read-only mirror of https://review.mlplatform.org/admin/repos/ml/armnn
https://developer.arm.com/products/processors/machine-learning/arm-nn
MIT License
1.15k stars 307 forks source link

DelegateUintTest for Android test Failed #622

Closed xiaotongnii closed 2 years ago

xiaotongnii commented 2 years ago

Frist,Can Arm NN Tfite Delegate support on Android platform? I build Arm NN TFlite Delegate and Delegate UintTest,but DelegateUintTest test on Android(12) phone, Failed

Env: Arm NN :21.02 tensorflow:2.3.1 android NDK: r20b

After build Arm NN Tflite Delegate Ut ,test on Android(12) phone, Failed.

xxxx:/data/local/tmp/delegate/20220315 # ./DelegateUnitTests --test-suite=CpuRef [doctest] doctest version is "2.4.0" [doctest] run with "--help" for options INFO: Initialized TensorFlow Lite runtime.

/home/user/armnn/delegate/src/test/ActivationTest.cpp:179: TEST SUITE: Activation_CpuRefTests TEST CASE: Activation_ReLu_CpuRef_Test /home/user/armnn/delegate/src/test/ActivationTest.cpp:179: FATAL ERROR: test case CRASHED: SIGSEGV - Segmentation violation signal

[doctest] test cases: 1 | 0 passed | 1 failed | 512 skipped [doctest] assertions: 6 | 6 passed | 0 failed | [doctest] Status: FAILURE! Segmentation fault (core dumped)

Frist case is Failed, what's matter?

xiaotongnii commented 2 years ago

Hi @TeresaARM I test on CPU,and result as follow:

./DelegateUnitTests -ts=CpuRef doctest] doctest version is "2.4.0" [doctest] run with "--help" for options INFO: Initialized TensorFlow Lite runtime.

/home/user/armnn/delegate/src/test/ActivationTest.cpp:179: TEST SUITE: Activation_CpuRefTests TEST CASE: Activation_ReLu_CpuRef_Test /home/user/armnn/delegate/src/test/ActivationTest.cpp:179: FATAL ERROR: test case CRASHED: SIGSEGV - Segmentation violation signal

[doctest] test cases: 1 | 0 passed | 1 failed | 512 skipped [doctest] assertions: 6 | 6 passed | 0 failed | [doctest] Status: FAILURE! Segmentation fault (core dumped)

./DelegateUnitTests -tse=CpuAcc doctest] doctest version is "2.4.0" [doctest] run with "--help" for options INFO: Initialized TensorFlow Lite runtime.

/home/user/armnn/delegate/src/test/ActivationTest.cpp:220: TEST SUITE: Activation_CpuAccTests TEST CASE: Activation_ReLu_CpuAcc_Test /home/user/armnn/delegate/src/test/ActivationTest.cpp:220: FATAL ERROR: test case CRASHED: SIGSEGV - Segmentation violation signal

[doctest] test cases: 1 | 0 passed | 1 failed | 512 skipped [doctest] assertions: 6 | 6 passed | 0 failed | [doctest] Status: FAILURE!

I find a question about delegate build , it is not android.mk on delegate flod ; is it not depend on android.mk when build for android platform ?

TeresaARM commented 2 years ago

Hi @Niuxiaotong, could you tell us how you built? can you try to build in debug so that we can have more information about what is failing

xiaotongnii commented 2 years ago

Hi @Niuxiaotong, could you tell us how you built? can you try to build in debug so that we can have more information about what is failing

Hi @TeresaARM I try to build in debug,such as change " -DCMAKE_BUILD_TYPE=Release " to " -DCMAKE_BUILD_TYPE=Debug", Right?

TeresaARM commented 2 years ago

These 2 guides may help: https://github.com/ARM-software/armnn/blob/branches/armnn_22_02/delegate/BuildGuideNative.md https://github.com/ARM-software/armnn/blob/branches/armnn_22_02/delegate/DelegateQuickStartGuide.md

MikeJKelly commented 2 years ago

I'm closing this due to inactivity, if you still need help with this then please create a new ticket, thanks!