Advanced Model Target Databases

Advanced Model Targets support recognition and tracking of one or more objects from all sides, all contained in a single Advanced Model Target Database. Recognition ranges can be defined up to a full 360-degrees around every object, without requiring the user to align an outline of the model with the physical object to start tracking.

All that is required is training one or more Model Targets in the Model Target Generator (MTG). In contrast to Model Targets without training the MTG uploads your 3D models to the Vuforia Cloud for the deep learning training process.

The Vuforia sample package presents the NASA Viking lander, which can be 3D printed and tested with the 360-degree detection range. The model and printing instructions can be found on the 3D Printing Instructions for the Viking Mars Lander page. It demonstrates the Advanced Model Targets Databases and is a resource to help you get started. The sample package is available on Vuforia’s website in the Downloads section under the Samples tab.
In addition, the Vuforia Engine samples for Unity contain an Advanced Model Target of a 1:18 toy model of the Polaris RZR XP 1000, which can be acquired for testing, e.g. on Amazon.
 

The Model Target Generator (MTG)

Use the Model Target Generator developed by Vuforia to create Advanced Model Target Databases. It is available for Windows and macOS. It takes a 3D model as input and outputs a Vuforia Device Database. See the Model Target Generator User Guide for more information regarding installation and general information on Model Targets and Guide Views.

Multiple Objects, Multiple Guide Views for Advanced Recognition

When you use an Advanced Model Target Database containing multiple Model Targets and/or multiple Guide Views with up to 360-degree detection range, Vuforia Engine distinguishes between objects purely by their visual appearance, which means that the following additional considerations should be taken into account when selecting different objects and/or different Guide Views.

Essentially, each Guide View must look different - that is, each Guide View must be distinguishable based on appearance alone. There should be no ambiguity about which object the user is looking at, nor which Guide View corresponds to the current viewing angle and distance.

Objects should look different

All your objects must look different from each other. If you have multiple objects that have a similar shape (for example two cars) you will need to make sure that each one can be well distinguished from the other (in the car example the sedan and convertible versions of a car would be likely distinctive enough).

NOTE: The 3D model and object should match in scale. Using an incorrect scale and measurements can result in poorer recognition and tracking . See How to Create a Model Target for more information on this topic.

Guide Views should look different

When setting up Guide Views for Advanced Model Targets, make sure to create them using the Create Advanced View button in the Model Target Generator. This will allow you to define the recognition ranges for the view and selecting a range that makes sense for your model. For objects like toys or cars a full 360-degree recognition range may be the right choice.

NOTE: The closer you move to the physical object in an AR session, the more crucial it is that the 3D model of the object is accurate with respect to the physical object.
Additionally, if you create a view focused on part of a model, i.e. the motor block of a machine, and the physical object contains a different motor, recognition will not work.

Please see the article on Guide Views for more information.

If you create a Guide View without recognition ranges, you can always go back and add recognition ranges to each Guide View before training an Advanced Model Target. Note, that a Model Target can only be generated with on type of Guide Views.

NOTE: The closer you move to the physical object, the more crucial it is that the 3D model of the object is accurate with respect to the physical object.
E.g. if you create a view focused on the motor block of a machine, but the 3D model contains a different motor, recognition will not work.

Recognition Ranges and Target Extents of Guide views should not overlap

Only configure multiple Guide Views per Advanced Model Target if the Target Extent of those views differ significantly. This is the case if the different views focus on different parts of the object, and the Target Extentconfigured in the recognition range screen, have been reduced to that part accordingly.
Setting up two or more Guide Views that cover different recognition ranges, but have the same target extent, will result in larger dataset files and longer recognition times without bringing any benefit. This is the case e.g. if you configure one Guide View to cover the left side of the object, and another that covers the right side of the object, but the Target Extent covers the full object in both Guide Views. In such a case, it is better to combine those two Guide Views into a single one that covers both ranges, e.g. a 360 recognition range around the object.

Please see the article on Guide Views for more information on Target Extent.

In addition, if you have multiple objects in a single Advanced Model Target Database, each of the Guide Views for each object should be visually distinct.

  • Having a database where one object is a target, but also a part of another target should be avoided. One example is a motor block that is a target by itself, but also contained in a car model with the hood open. Both objects might be confused. If you cannot avoid such situations, then you need to make sure that one of the objects has at least a distinctive appearance (logo or pattern) covering ideally most of its surfaceWhen doing so you need to use the realistic option during training. Alternatively, you could set up the Guide Views for the car so that they do not include the motor block (e.g. by setting the Target Extents to exclude it).

Creating a Trained Model Target Database

Now that the models has been prepared, continue to create an Advanced Model Target Database from the Home Screen of the MTG.

  1. Start the Model Target Generator
    • To create a training session, at minimum a database with a single object with one or more Advanced Views with recognition ranges is required. Such Guide Views are necessary for training the Model Target.
      If you created a Guide View without recognition ranges, you can always go back and add recognition ranges to each Guide View before training an Advanced Model Target.
  2. Navigate to the Databases tab. (If you are currently editing a single Model Target, you may need to click the return arrow first to return to the Home Screen).

  1. Click Create Database and choose a Name for the training session, optionally enter a Description. The database is created in the Training Sets column in the Home Screen. 

  1. For every object, you want to add to the database, select a Model Target project from the list that appears, or browse to an existing .vup project via the Browse button. (If you cannot see your Model Target in the list, it is likely because it has not yet been generated. In that case, go back to the Model Targets tab, double-click on the Model Target, and click the Generate Model Target button.)  
    • If the Guide Views of a Model Target have been created without recognition ranges, you will not be able to select the model for training.
      In this case, go back to the model and configure recognition ranges for all Guide Views.
    • When a Model Target is added to a database, a copy is made of it in its current state. If you make any further changes to the Model Target afterwards, any databases that contain it will not be automatically updated.
    • We recommend adding no more than 10-20 objects to a single database, depending on the number of Guide Views you have defined for each object. If you have a large number of Guide Views per object, you should try and keep the number of objects per database smaller, to get better results.
    • Each object added to a single database (and each of their Guide Views) must be visually distinguishable in order to be successfully recognized at runtime. If you have similar looking objects, or if you have set up Guide Views in such a way that different looking objects appear similar from some of their Guide Views, you may have trouble getting recognition to work reliably.

Starting Training

When generating the Model Targets and preparing them for inclusion in an Advanced Model Target Database by setting their Recognition Ranges, it is necessary to consider which Appearance Mode the models should be trained in as models are treated differently depending on their appearance. Make the following considerations when adding the Model Targets to a database for training. 

  1.  Realistic should be selected if the 3D models look like the real physical objects in terms of textures and colors etc. If this setting is selected, the resulting database will only work well for objects that have the same colors, patterns, or decals like the 3D model. This mode is e.g. typically used for toys or in cases when the shape is not distinctive enough between objects. In general, using textures typically helps with recognition.
  2. Non-realistic should be used for cases where the 3D model does not have realistic colors or texture. The resulting database will not look at the actual colors of the real physical objects. This mode is typically used for 3D models of industrial objects where no information of appearance is available.

Please note the following restrictions:

  • If you are using the Coloring functionality for any of the Model Targets in your database, the Non-realistic option is pre-selected after adding your models to a Training Session. 
  • If all the Model Targets selected are configured with the Tracking Mode SCAN and were imported and generated with a texture, the Appearance Mode is set to Realistic
  • If your Advanced Model Target Database possess some Model Targets, but not all, that were created from a scan, it is recommended to separate those Model Targets into an additional training session. 

NOTE: A warning message will also appear if inconsistent Model Targets appearances are detected. 

  1. From the Home Screen, press the Train button found next to the database you have created. The following Appearance Mode window will ask you to choose between Realistic and Non-realistic; it is pre-selected if one of the three circumstances above are identified by the MTG.

NOTE: To help improve our software products, you can allow PTC to securely store and test your CAD models used for Model Target training by checking the Allow PTC to test CAD data checkbox.

Please see Model Target Generator Data Processing for more information.

  1. Conclude the setup and start the training process by pressing Continue.

Exporting the Trained Database

  1. Once training is complete, an Export button appears next to the database on the Home Screen. Click the button to export the trained database as a Vuforia Engine native and Unity package. The training set can be accessed both during and after the training process by double-clicking on the database. The training quota only gets affected upon the successful export of the training result.

What to do if Training Fails?

If training fails, the database status will change to Failed. In addition, there may be one or more status messages in the detailed database view (underneath the list of added Model Targets) with additional information about the cause of failure. Depending on the status messages, you may want to try again or send a support request.

Even if training does not fail completely, the training process may issue warnings about the quality of the trained data, and suggest possible fixes, e.g:

Usually, training fails for one of the following reasons:

If you encounter a different problem, or if you have any other questions or issues, you can make a support request via email from the Model Target Generator by clicking the Send Feedback button.

Using an Advanced Model Target Database

The Model Target Generator saves the trained database to your hard drive as .unitypackage files and .dat/.xml file pairs. See Introduction to Model Targets in Unity for a step by step guide on importing the unity package to your Unity project and how to configure a ModelTarget GameObject. If you are building a native app, load the .dat/.xml file pair into a Dataset created from the ObjectTracker. For further information, refer to the Model Targets API Overview and Model Target Native Workflow.

Testing with the Test Application

Test your advanced database on the Android Model Target Test App. Simply load the two database files to the directory of the installed test application on your Android device and test your newly generated Advanced Model Targets. The directory on your device is usually found here:

/sdcard/Android/data/com.vuforia.engine.ModelTargetsTest/files/ModelTargetData/YourDatabaseName/

Once the two database files have been copied to the directory, you can run the application. Find your Advanced Model Target Database by double-tapping on the screen. A menu will appear where you may select your database from a list. The object will be outlined once recognition and tracking have begun.

Learn More

Model Targets Overview

Model Targets Supported Objects & CAD Model Best Practices

Model Target Guide View

Model Targets API Overview

Automatic Coloring of Model Targets