# Semantic Segmentation Example Crashes On Android

**URL:** <https://community.nianticspatial.com/t/semantic-segmentation-example-crashes-on-android/1498>\
**Category:** I'm Stuck\
**Created:** [February 19, 2022, 4:30am UTC](https://community.nianticspatial.com/t/semantic-segmentation-example-crashes-on-android/1498 "2022-02-19T04:30:14Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Anthony\_Melo](https://avatars.discourse-cdn.com/v4/letter/a/eb8c5e/32.png) [@Anthony\_Melo](https://community.nianticspatial.com/u/Anthony_Melo)\
**Post date:** [February 19, 2022, 4:30am UTC](https://community.nianticspatial.com/t/semantic-segmentation-example-crashes-on-android/1498/1 "2022-02-19T04:30:14Z")

</div>

_Include the following details (edit as applicable):_

- **Issue category** : Semantic Segmentation
- **Device type & OS version** : Android /Pixel 3 on Android 11
- **Host machine & OS version** : PC / Windows 10
- **Issue Environment** : On Device
- **Xcode version** : N/A
- **ARDK version** : 1.2.0
- **Unity version** : 2020.3.24f1

Description of the issue:  
I am trying to run the Semantic Segmentation scene from the examples package on Android. I have not touched any scripts, I simply want to run the scene on device.

Once built, the app opens and asked for camera permission, then waits for a couple seconds, starts the camera, then it crashes. I have run the scene in the editor but do not see any errors.

I have tried leaving API Compatibility Level at .Net Standard 2.0 , only using OpenGLES3, and unchecking Dynamic Batching.

My best guess is that it is associated with the ardk client platform because it is mentioned in the Logcat error (see bottom of post). Anyone else have this issue, I appreciate any help / suggestions!

Below are screenshots of my build settings:

 ![Settings](https://us1.discourse-cdn.com/niantic/original/1X/a7c40a6631d5cd473bef259ec049fffe87528c2f.png)

 ![Settings 2](https://us1.discourse-cdn.com/niantic/original/1X/9d56a3903f0e98296532697846e120f1434247b2.png)

 ![Settings 3](https://us1.discourse-cdn.com/niantic/original/1X/cd24be26928e4b287945d3fb8a2a511498de32d2.png)

Below is the error from Android Studio:

2022-02-18 23:03:25.717 27418-27457/? E/AndroidRuntime: FATAL EXCEPTION: UnityMain  
Process: com.DefaultCompany.ARDKDemo, PID: 27418  
java.lang.Error: \*\*\* \*\*\* \*\*\* \*\*\* \*\*\* \*\*\* \*\*\* \*\*\* \*\*\* \*\*\* \*\*\* \*\*\* \*\*\* \*\*\* \*\*\* \*\*\*  
Version ‘2020.3.24f1 (79c78de19888)’, Build type ‘Development’, Scripting Backend ‘il2cpp’, CPU ‘arm64-v8a’  
Build fingerprint: ‘google/blueline/blueline:12/SP1A.210812.015/7679548:user/release-keys’  
Revision: ‘MP1.0’  
ABI: ‘arm64’  
Timestamp: 2022-02-18 23:03:25-0500  
pid: 27418, tid: 27652, name: Thread-10 \>\>\> com.DefaultCompany.ARDKDemo \<\<\<  
uid: 10221  
signal 6 (SIGABRT), code -1 (SI\_QUEUE), fault addr --------  
x0 0000000000000000 x1 0000000000006c04 x2 0000000000000006 x3 0000006c1e4c0ff0  
x4 736f646277641f73 x5 736f646277641f73 x6 736f646277641f73 x7 7f7f7f7f7f7f7f7f  
x8 00000000000000f0 x9 e15f254b666aba48 x10 0000000000000000 x11 ffffff80fffffbdf  
x12 0000000000000001 x13 0000000000000018 x14 000003382eb5e5d6 x15 000c52413b72f215  
x16 00000070aa4f8050 x17 00000070aa4d4eb0 x18 0000000000000000 x19 0000000000006b1a  
x20 0000000000006c04 x21 00000000ffffffff x22 ffffff80ffffffc8 x23 0000006c1e4c1240  
x24 0000006c1e4c1120 x25 0000006c1e4c1160 x26 0000000000000001 x27 0000006e2dbf24d0  
x28 0000006c1e4ca000 x29 0000006c1e4c1070  
sp 0000006c1e4c0fd0 lr 00000070aa487ba0 pc 00000070aa487bcc

```
backtrace:
      #00 pc 000000000004fbcc /apex/com.android.runtime/lib64/bionic/libc.so (abort+164) (BuildId: ba489d4985c0cf173209da67405662f9)
      #01 pc 0000000001360004 /data/app/~~Qc_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk_client_platform.so (std::set_unexpected(void (*)())) (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)
      #02 pc 0000000001360168 /data/app/~~Qc_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk_client_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)
      #03 pc 000000000135d1d0 /data/app/~~Qc_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk_client_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)
      #04 pc 000000000135c8b4 /data/app/~~Qc_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk_client_platform.so (__cxa_get_exception_ptr) (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)
      #05 pc 000000000135c834 /data/app/~~Qc_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk_client_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)
      #06 pc 0000000000925318 /data/app/~~Qc_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk_client_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)
      #07 pc 0000000000923eb0 /data/app/~~Qc_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk_client_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)
      #08 pc 000000000091708c /data/app/~~Qc_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk_client_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)
      #09 pc 000000000091a2ec /data/app/~~Qc_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk_client_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)
      #10 pc 000000000091a180 /data/app/~~Qc_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk_client_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)
      #11 pc 000000000092b158 /data/app/~~Qc_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk_client_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)

```

2022-02-18 23:03:25.717 27418-27457/? E/AndroidRuntime: #12 pc 0000000000916598 /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)  
#13 pc 0000000000915904 /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (LNTLib::LNTManager::InitNetworks(std::\_\_ndk1::map\<std::\_\_ndk1::basic\_string\<char, std::\_\_ndk1::char\_traits, std::\_\_ndk1::allocator \>, std::\_\_ndk1::pair\<\_\_sFILE\*, \_\_sFILE\*\>, std::\_\_ndk1::less\<std::\_\_ndk1::basic\_string\<char, std::\_\_ndk1::char\_traits, std::\_\_ndk1::allocator \> \>, std::\_\_ndk1::allocator\<std::\_\_ndk1::pair\<std::\_\_ndk1::basic\_string\<char, std::\_\_ndk1::char\_traits, std::\_\_ndk1::allocator \> const, std::\_\_ndk1::pair\<\_\_sFILE\*, \_\_sFILE\*\> \> \> \> const&, UtilsLib::KeyValueConfig const&, void\*)+3904) (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)  
#14 pc 00000000007488b4 /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)  
#15 pc 00000000007fe824 /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)  
#16 pc 00000000004d17e4 /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)  
#17 pc 00000000004c25ac /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)  
#18 pc 00000000003f08a4 /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)  
#19 pc 00000000003c95e8 /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)  
#20 pc 00000000007f6f30 /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)  
#21 pc 00000000004101a4 /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)  
#22 pc 0000000000c06da0 /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)  
#23 pc 0000000000df771c /data/app/~~Qc\_fjX94aN9SmglH3DUqXA==/com.DefaultCompany.ARDKDemo-D7HEVu68z7L50O-OJkKeHg==/lib/arm64/libardk\_client\_platform.so (BuildId: 3b75c812bf5b779b26b5ab2e76f89b62175cc5bf)

```
    at libc.abort(abort:164)
    at libardk_client_platform.std::set_unexpected(void (*)())(set_unexpected:0)
    at libardk_client_platform.0x1360168(Native Method)
    at libardk_client_platform.0x135d1d0(Native Method)
    at libardk_client_platform.__cxa_get_exception_ptr(__cxa_get_exception_ptr:0)
    at libardk_client_platform.0x135c834(Native Method)
    at libardk_client_platform.0x925318(Native Method)
    at libardk_client_platform.0x923eb0(Native Method)
    at libardk_client_platform.0x91708c(Native Method)
    at libardk_client_platform.0x91a2ec(Native Method)
    at libardk_client_platform.0x91a180(Native Method)
    at libardk_client_platform.0x92b158(Native Method)
    at libardk_client_platform.0x916598(Native Method)

```

2022-02-18 23:03:25.717 27418-27457/? E/AndroidRuntime: at libardk\_client\_platform.LNTLib::LNTManager::InitNetworks(std::\_\_ndk1::map\<std::\_\_ndk1::basic\_string\<char, std::\_\_ndk1::char\_traits, std::\_\_ndk1::allocator \>, std::\_\_ndk1::pair\<\_\_sFILE\*, \_\_sFILE\*\>, std::\_\_ndk1::less\<std::\_\_ndk1::basic\_string\<char, std::\_\_ndk1::char\_traits, std::\_\_ndk1::allocator \> \>, std::\_\_ndk1::allocator\<std::\_\_ndk1::pair\<std::\_\_ndk1::basic\_string\<char, std::\_\_ndk1::char\_traits, std::\_\_ndk1::allocator \> const, std::\_\_ndk1::pair\<\_\_sFILE\*, \_\_sFILE\*\> \> \> \> const&, UtilsLib::KeyValueConfig const&, void\*)(InitNetworks:3904)  
at libardk\_client\_platform.0x7488b4(Native Method)  
at libardk\_client\_platform.0x7fe824(Native Method)  
at libardk\_client\_platform.0x4d17e4(Native Method)  
at libardk\_client\_platform.0x4c25ac(Native Method)  
at libardk\_client\_platform.0x3f08a4(Native Method)  
at libardk\_client\_platform.0x3c95e8(Native Method)  
at libardk\_client\_platform.0x7f6f30(Native Method)  
at libardk\_client\_platform.0x4101a4(Native Method)  
at libardk\_client\_platform.0xc06da0(Native Method)  
at libardk\_client\_platform.0xdf771c(Native Method)

---

<div class="post-metadata">

**Author:** ![Erik\_Brown](https://sea2.discourse-cdn.com/niantic/user_avatar/community.nianticspatial.com/erik_brown/32/25_2.png) [@Erik\_Brown](https://community.nianticspatial.com/u/Erik_Brown)\
**Post date:** [February 21, 2022, 5:52pm UTC](https://community.nianticspatial.com/t/semantic-segmentation-example-crashes-on-android/1498/2 "2022-02-21T17:52:51Z")

</div>

I recreated the Semantic Segmentation Example scene based on the Unity settings you provided (with OpenGLES3, Dynamic Batching, and .NET 4x). While using a lower Target API Level, I was able to build and run without issue, though built outside of Android Studio. Please try changing your Target API Level to Android 10.0 (API level 29). To target a higher API level, or if you are experiencing issues related to Android Studio, please double check the Building for Android 11 (API level 30) and higher directions, the Google Play Services for AR settings and your Gradle version.

[https://lightship.dev/docs/building\_android.html](https://lightship.dev/docs/building_android.html)

[https://developers.google.com/ar/develop/java/enable-arcore](https://developers.google.com/ar/develop/java/enable-arcore)

---

<div class="post-metadata">

**Author:** ![Anthony\_Melo](https://avatars.discourse-cdn.com/v4/letter/a/eb8c5e/32.png) [@Anthony\_Melo](https://community.nianticspatial.com/u/Anthony_Melo)\
**Post date:** [February 22, 2022, 1:50am UTC](https://community.nianticspatial.com/t/semantic-segmentation-example-crashes-on-android/1498/3 "2022-02-22T01:50:07Z")

</div>

Thanks for the response Erik.

I was indeed targeting Android 11 and followed the steps you listed but no luck. However, changing my build target to Android 10 did the trick! I appreciate your help.

---

<div class="post-metadata">

**Author:** ![Maverick\_Niantic](https://avatars.discourse-cdn.com/v4/letter/m/8edcca/32.png) [@Maverick\_Niantic](https://community.nianticspatial.com/u/Maverick_Niantic)\
**Post date:** [March 5, 2026, 11:50pm UTC](https://community.nianticspatial.com/t/semantic-segmentation-example-crashes-on-android/1498/4 "2026-03-05T23:50:22Z")

</div>

Age
