Issues with Continuous localization

  • ARDK version: 3.0 (beta 4)
  • Unity version: 2021.3.27f1

Description of the issue:

Hi all,

I’ve been trying to get the VPS continuous localization working but i’m running into some issues when enabling it in the samples project. I’m testing this in combination with Shared VPS.

First of i don’t get any calibration going when i specify an ARLocationManager in the SharedSpaceManager, even when calling the StartTracking() myself, this i was able to workaround by simply leaving it empty.

However the problem persists since i want to enable continuous localization, as soon as i do this i get the following error logs every time it tries to relocalize:

In the hierarchy it starts out looking good but then it starts adding a persistent anchor every 2 seconds (which is the time between localizations).
Screenshot 2023-10-24 at 15.33.51

When i try to log the _anchorToARLocationMap dictionary it crashes my Unity Editor, making debugging this issue difficult.
Is this an issue that has been raised before?

Thanks in advance!

Hi Merjin,

Could I see your XR Origin in the Inspector? Could you please provide me with the operating system you’re using Unity on, the software version, and the device’s operating system and software version?

Kind Regards,
Maverick L.

Hi @Maverick_Liberty ,

Thanks for the reply! Here’s my XR Origin:

And here in debug mode, i had to assign the shared root manually:

Also this is the code i use to start a shared space and tracking:
Uploading: Screenshot 2023-10-24 at 20.18.41.png…

I’m running this project on MacOs, Ventura 13.0. Given the nature of the issue i haven’t tested it on iOS yet, could be worth a shot.

Anyhow i’d love to hear some suggestions since i’m out of ideas at this point :sweat_smile:

Edit: i do see that the recommended Unity version for ARDK 3.0 is 2021.3.29f1, i’m running on 2021.3.27f1 instead, could it be worth updating Unity?

Thank you!

Could you try disabling “Continuous Localization Enabled” under “Experimental: Drift Migration?” I think the drift migration and the lack of a default anchor GameObject is why you’re seeing the creation of new anchors every two seconds.

Thanks for the suggestion, it does make sense but my project is working great without drift mitigation and i need to have it included, it’s the reason i opened this thread :slight_smile:

I did set up a default anchor, but no dice as of yet. I don’t think it makes much of a difference looking at the ARDK code. Here is how i try to start the shared space:

And so it can’t find the ARLocation that the persistent anchor is linked to here, i’m struggling to understand where the anchor got mutated or rewritten since i only ever link to a specific one:
Screenshot 2023-10-24 at 22.59.20

So to rephrase my question it’d be the following: Is it possible to use Shared VPS in combination with Continuous localization? or does it require a workaround?

Yes, you’re able to use continuous localization in Shared AR. The location used is the first location registered in the AR Location Manager’s ARLocations list as indicated with the ARLocations.First() call. Have you looked at the Using SharedSpaceManager with ARLocationManager tutorial in the Lightship 3 documentation? It should clear up some of the confusion.

Best,
Maverick L.

Appreciate you taking the time to assist me but I have thoroughly reviewed documentation multiple times to ensure I understand the proper usage of ARDK. However, I continue to encounter errors when enabling continuous localization in editor that are not explained properly.

I found out that the errors arise in the mockpersistentanchor implementation, it generates a new persistent anchor every time you try to update one which is not what i expect to be correct:

But in the runtime implementation i found none of this happening which led me to try it out on location, once localizing at a proper VPS spot (or private one) it ran as expected.

This topic was automatically closed 2 hours after the last reply. New replies are no longer allowed.

Thank you for your patience!

Have you tried updating to the latest version of Lightship 3? Are you still experiencing the issue with the update?