realvirtual.io
  • Building Digital Twins with Unity and realvirtual.io
  • Basics
    • Installation
    • Demo Model
      • Old Demo Model
    • Editor User Interface
      • Hierarchy Window
      • 3D Views
      • Quick Edit
      • Move Pivot Points (Pro)
      • Selection Window (Pro)
      • Material Window (Pro)
      • Measurement (Pro)
      • Kinematic Tool (Pro)
      • Model Checker
    • Runtime UI
      • Group Manager
      • Debug Console
      • Responsiveness
      • Runtime Persistence
    • Importing and exporting
    • Folder structure
    • Tutorial
    • Physics
    • CAD import (Pro)
      • CADLink (Pro)
      • CAD Checker (Pro)
      • CAD Updater (Pro)
    • Reusable Components (Prefabs)
    • Cadenas parts4cad
    • Publishing the Digital Twin
    • Revision management
  • News
  • Login & Download Updates (Pro)
  • Components & Scripts
    • Realvirtual
      • Environment Controller
    • MU, Source and Sink
      • Source
      • Sink
    • Motion and Kinematic
      • Drive
      • Kinematic
      • Group
      • Joint
      • CAM
      • TransportSurface
      • Guided Transport
      • Drive behavior
      • Chain
      • Chain element
      • Motion for developers
    • Sensors
      • Sensor
      • Measure
      • MeasureRaycast
    • Picking and Placing MUs
      • Grip
      • Gripper
      • Fixer
      • Pattern
    • Changing MUs
      • MaterialChanger
      • PartChanger
      • Cutter
    • Scene Interaction
      • 3D Buttons
      • Screen Overlay Buttons
      • Scene Selectables
      • Lamp
      • Interact3D
      • UI components
      • HMI components (Pro)
        • Start your own HMI
        • HMI Tab
        • HMI DropDown
        • HMI Puschbutton
        • HMI Switch
        • HMI Value
        • HMI Text
        • HMI Slider
        • HMI Message
        • HMI Marker
      • ModelZoo (Pro)
    • Interfaces
      • Interface Tools
        • Signal Manager
        • Signal Importer Exporter
        • Signal Catcher
        • OnValueChangedReconnect
      • Signal Importer / Exporter
      • ABB RobotStudio (Pro)
      • Denso Robotics (Pro)
      • EthernetIP (Pro)
      • Fanuc (Pro)
      • FMI
      • Igus Rebel
      • MQTT (Pro)
      • Modbus (Pro)
      • OPCUA (Pro)
      • PLCSIM Advanced (Pro)
      • RoboDK (Pro)
      • RFSuite (Pro)
      • SEW SimInterface (Pro)
      • Siemens Simit Interface (Pro)
      • Simit Shared Memory (Pro)
      • Simulink (Pro)
      • S7 TCP
      • TwinCAT (Pro)
      • TwinCAT HMI (Pro)
      • UDP (Pro)
      • Universal Robots (Pro)
      • Wandelbots Nova (Pro)
      • Websocket (Pro)
      • Windmod Y200 (Pro)
      • Custom Interfaces
    • Performance Tools
      • Combine Meshes (Pro)
      • Create Prefab (Pro)
      • Hierarchy Cleanup (Pro)
      • Mesh Optimizer (Pro)
      • Performance Optimizer (Pro)
    • Defining Logic
      • Unity Scripting
      • Behavior Graph
      • Logicsteps
      • Unity Visual Scripting
      • Recorder
    • Robot Inverse Kinematics (Pro)
    • Volume Tracking (Pro)
  • Multiplayer (Pro)
  • Extensions
    • ModelZoo
      • Beckhoff TwinCAT
      • Siemens S7
      • Denso Cobotta 1300
      • Wandelbots Nova Fanuc CRX
      • Universal Robots UR10
      • Fanuc Roboguide
    • realvirtual.io AIBuilder
      • realvirtual.io AI Builder Overview
      • Generate AI Training Data
      • AI Training
      • Testing AI in a Digital Twin
      • Deploying the AI
    • realvirtual.io Simulation
      • Conveyor Library
      • Path System
        • Path finding
        • Line
        • Curve
        • Workstation
        • Catcher
        • Pathmover
    • realvirtual.io Industrial Metaverse
      • Setup Guide
      • VR Modules
      • AR Modules
      • Multiuser
    • AGX Physics
    • VR Builder
    • CMC ViewR
  • Advanced Topics
    • Render Pipelines
    • Mixed Reality with Meta Quest3
    • Upgrade Guide
      • Upgrade to 2022
    • Open Digital Twin Interface
    • Usefull Addons
    • Improving Performance
    • Supported Platforms
    • Compiler Defines
    • For Developers
      • Important Classes and Interfaces
      • Assembly Definitions
      • Starting your development
      • Class documentation
      • realvirtual Init Sequence
      • realvirtualBehavior Lifetime Methods
      • Testing
    • Newtonsoft JSON
    • Troubleshooting
  • Release Notes
  • AI Digital Twin Assistant (GPT4)
  • License Conditions
Powered by GitBook
On this page
Edit on GitHub
  1. Extensions
  2. realvirtual.io AIBuilder

Deploying the AI

Deploying the AI to external systems with ONNX or run it within a Unity Build

After training and testing an AI model within a digital twin environment, the final step is deployment. Deployment involves making the trained model available for real-time inference, where it can be used to perform tasks such as object detection, classification, or decision-making in production environments. There are two primary ways to deploy the AI model: as part of a Unity application or in an external inference system.

  1. Unity Application Deployment: In this approach, the trained AI model is converted to an ONNX (Open Neural Network Exchange) format and included directly in a Unity executable. The Unity app performs the inference using the embedded ONNX model, allowing the AI to process data in real time within the simulation or a deployed Unity application. This method is suitable for scenarios where the entire solution, including AI inference, needs to run as a standalone Unity application, offering an integrated experience with the digital twin.

    Deployment to a Unity application can be done for any available Unity destination platform by starting a Unity build process. This enables the AI-powered application to be deployed on various platforms, including Windows, Linux, macOS, Android, iOS, and many more. This cross-platform flexibility ensures that the AI model can be used in a wide range of environments, from desktop applications to mobile devices and specialized hardware.

  2. External Inference System Deployment: Alternatively, the ONNX model can be exported from Unity and used in an external inference system. This setup involves deploying the model on a separate inference platform, such as a cloud-based AI service, an edge device, or a custom-built inference server. The external system can perform the AI computations and send the results back to the Unity application or other control systems. This approach is beneficial for leveraging specialized hardware, integrating with existing AI infrastructure, or scaling inference across multiple devices.

Deployment blueprint - Camera Device Demo

We provide a simple example application called CameraDeviceDemo, which can be found in the main AI Builder folder. This app demonstrates how to use a trained ONNX model for real-time inference together with a webcam or an integrated camera on a mobile device, such as a phone or tablet. The CameraDeviceDemo app showcases the deployment process by allowing the AI model to perform object detection or classification using live camera feeds.

The example app is versatile and can be used on various platforms, supporting real-time inference on desktop systems with webcams or mobile devices equipped with built-in cameras. This flexibility enables quick usage of AI models in different environments, making it easy to test, validate, and utilize the trained model for practical applications in diverse settings.

PreviousTesting AI in a Digital TwinNextrealvirtual.io Simulation

Last updated 6 months ago