Asynchronous multi-body framework
This sandbox is in the article namespace. Either move this page into your userspace, or remove the {{User sandbox}} template. AMBF, Asynchronous Multi-Body Framework, is an open-source 3D versatile simulator for robots developed on April 2019. This multi body framework provides a real-time dynamic simulation of multi-bodies (robots, free bodies and multi-link puzzles) paired with real-time haptic interaction with various input devices (CHAI-3D)[1]. The framework integrates real surgeon master console, haptic or not, to control simulated robots in real-time. This feature results in the simulator being able to be used in real-time training applications for surgical and non-surgical tasks. It offers the ability to interact with soft bodies ensuring the ability to simulate surgical tasks where tissues are subject to deformation. It also provides a Python Client to interact in an easy way with the simulated bodies and to train Neural Network on real-time data with in-loop simulation. It includes a wide range of robots, grippers, sensor, puzzles and soft bodies. Each simulated object is represented as an afObject, likewise the simulation world is represented as an afWorld. Both utilize two communication interfaces: State and Command. Through the State command the object can send data outside the simulation environment, while the Command allows to apply commands to the underlying afObject.
The AMBF simulator uses several external packages including CHAI-3D[2] and Bullet Physics for simulating rigid and soft bodies.
It is compatible with Ubuntu 16.04 and Ubuntu 18.04 but it has been also tested on MacOs Maverick and MacOs Mojave.
The simulator finds applications in many fields such as multi-bodies simulation, manipulation of robotic manipulators, real-time training for surgical and non surgical tasks and renforcement learning.
AMBF File Format
The Asynchronous Multi-Body Framework introduces a new robot description file format: the AMBF description format or ADF. The ADF is based on YAML which allows to modify, create or test multi-bodies in an easy way thanks to its human readability. The idea is that a robot is a spatial tree of bodies where joints are parts of links. The AMBF description file can be seen as composed by blocks. Each of these blocks contains the data for a single independent body such that it can be modified or removed without influencing the other blocks. The header list is located at the beginning of the file and it containes global parameters and all the elements that define the specific description file such as bodies, visual elements and constraints[3].
This file format allows also to define different multi-bodies or multi-robots in the same description file.
Features
ROS Communication
The simulator is integrated with ROS (Robot Operating System), a middle-ware that handles the comminication with robots. ROS allows to control the simulated robot through external codes and it also offers useful plotting (RQT Plot) and loggin (ROS Bag) tools. The Asynchronous Framework remains isolated from ROS-based run-time mechanics while being able to leverage its tools. AMBF presents a stable and bidirectional ROS communication handled by the Python Client.
Python Client
The Python Client provides the possibility to control different afObject while keeping a high communication speed. This allows to manage the ROS communication making the process of controlling simulated bodies much easier compared to any other simulator. The communication between the Client and the AMBF simulator is managed thorugh ROS as middle-ware. The Client uses a bidirectional communication such that it is possible to set commands to the bodies and at the same time to read their states using a library of Python functions. These functions are used, for example, to set or get position and orientation of bodies as well as control the wrench acting on a body or get the number of joints connected to it. In order to use it, there is the need to crate an instance of the client and connect it to the simulation. This creates callable objects from ROS topics and initiates a shared pool of threads for bidrectional communication[4]. Each callable object has a WatchDog timer that resets commands it the timing condition fails.
Moreover, the Python Client is used for the training of reinforcement learning agents on real-time data.
Input Inerface Decive
The framework allows to integrate real master console to manipulate simulated bodies in real-time. These interfaces are also referred as Input Interface Device or IIDs and can be haptic or not. Several IIDs are already included in the simulator such as the Geomagic Phantom, Falcon Novint, Razer Hydra and dVRK MTM. Others can be easily included in the simulator by defining them in the input_device.yaml file. Each IID is simulated as a dynamic End-Effector (SDE) that can be bound or not to any simulated bodies. The SDE is controlled using a dynamic control law based on the motion of the IIDs[5]. The root link is the base of the SDE to which the IID is connected. Usually the state of the IID is in the reference frame of the device itself while the SDE is with respect to the world frame therefore a transform mapping is needed in order to have the states converted to a common frame. For each element some properties can be specified including the following:
- Workspace scaling: it scales the motion of the IID in simulation.
- Simulated multibody: it specifies the multi-body that emulates the external device within the simulated AMBF scene. Different descriptions files such as grippers can be chosen to be implemented inn the simulation.
- Haptic gain is a set of gains for controlling the force feedback applied on the IID.
- Controller gain is used for scaling the wrench for the SDE.
- Pair cameras filed is optional and it is used to set one or more cameras to be paired with the IID-SDE pair. [6]
Soft Bodies
In addition to rigid bodies, AMBF provides support for soft bodies. Soft bodies are defines as rigid bodies with additional parameters that can be tune for defining the behaviour of the soft body. The interaction between bodies is provided by the Bullet's solver which handles the dynamics of both rigid and soft bodies.
Soft bodies are represented as a collection of interconnected inertial nodes that can collide with other objects in the scene. The interconnection is generalized as a three-dimensional spring that accounts for the tension, torsion and flexion. The position of each node is computed using the symplectit Euler method at each time-step[7]. A high-quality mesh for visualization and a lower resolution mesh to represent the soft-body can be specified for each soft body.
Blender Add-on
AMBF includes an Add-on with Blender that allows the user to create new model or modified exsisting models according to its pourpose. Blender has a large community support for graphic designers and represents an immediate and intuitive interface for the user to create or modify bodies[8]. The Blender-to-AMBF add-on is bidirectional meaning that the user can both import objects defined through the AMBF file format and to create both high and low resolution files and subsequently AMBF yaml configuration files of complex robots and multi-bodies. This tool facilitates the creation process of new elements by allowing the user to tune rigid and soft bodies with real-time visual feedback.
References
- ^ "WPI-AIM/ambf".
{{cite web}}
: CS1 maint: url-status (link) - ^ "CHAI-3D".
{{cite web}}
: CS1 maint: url-status (link) - ^ Munawar, Adnan; Wang, Yan; Gondokaryono, Radian; Fischer, Gregory (November 4–8, 2019). "A Real-Time Dynamic Simulator and an Associated Front-End Representation Format for Simulating Complex Robots and Environments". IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS).
{{cite journal}}
: CS1 maint: date format (link) - ^ "Python Client".
{{cite web}}
: CS1 maint: url-status (link) - ^ Munawar, Adnan; Fischer, Gregory (November 2019). "An Asynchronous Multi-Body Simulation Framework for Real-Time Dynamics, Haptics and Learning with Application to Surgical Robots". IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS).
- ^ "Input Devices".
{{cite web}}
: CS1 maint: url-status (link) - ^ Adnan Munawar, December 2019, "An Asynchronous Simulation Framework for Multi-User Interactive Collaboration: Application to Robot-Assisted Surgery".
- ^ "Blender".
{{cite web}}
: CS1 maint: url-status (link)