{'fraction_non_alphanumeric': 0.03075894349715814, 'fraction_numerical': 0.013624205951186893, 'mean_word_length': 4.991487230846269, 'pattern_counts': {'":': 0, '<': 1, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
DronePaint: Swarm Light Painting with DNN-based Gesture Recognition

We propose a novel human-swarm interaction system, allowing the user to directly control a swarm of drones in a complex environment through trajectory drawing with a hand gesture interface based on the DNN-based gesture recognition. The developed CV-based system allows the user to control the swarm behavior without additional devices through human gestures and motions in real-time, providing convenient tools to change the swarm's shape and formation. The two types of interaction were proposed and implemented to adjust the swarm hierarchy: trajectory drawing and free-form trajectory generation control. The experimental results revealed a high accuracy of the gesture recognition system (99.75%), allowing the user to achieve relatively high precision of the trajectory drawing (mean error of 5.6 cm in comparison to 3.1 cm by mouse drawing) over the three evaluated trajectory patterns. The proposed system can be potentially applied in complex environment exploration, spray painting using drones, and interactive drone shows, allowing users to create their own art objects by drone swarms.


INTRODUCTION
Human and aerial swarm interaction (HSI) nowadays serves multiple purposes, such as search and rescue operations, cargo delivery, arXiv:2107.11288v1 [cs.RO] 23 Jul 2021 remote inspection, etc. One of the prominent implementations of the robotic swarms had recently emerged in art industry, where drones perform as scalable and interactive tools for light and spray painting. For example, an autonomous drone equipped with a spray gun-holding arm was developed by [Vempati et al. 2018] for spray painting on various three-dimensional surfaces. Furthermore, a multi-drone graffiti was proposed by [Uryasheva et al. 2019] with a task dispatch system based on the parametric greedy algorithm.
Several research papers focus on interactive art concepts where drones provide the color pallet by LED arrays. For instance, [Dubois 2015] proposed an interactive choreographic show where humans and drones move synchronously with precise swarm behavior computation. A tangible experience of HSI was introduced by [Gomes et al. 2016] where drones serve as a colorful interactive 3D display. Another practical approach was presented by [Knierim et al. 2018], who proposed drones with light beacons as a navigation system that projects the map instructions into the real world.
With these considerations, a real-time control interface over the swarm is required to deliver the user an immersive real-time experience of painting. Many researchers propose gesture-based interfaces as a versatile and intuitive tool of HSI. For example, a tactile interface for HSI with an impedance-based swarm control was developed by [Tsykunov et al. 2019]. A multi-channel robotic system for HSI in augmented reality was suggested by [Chen et al. 2020]. [Suresh and MartÃnez 2019] proposed a complex control approach with arm gestures and motions, which are recorded by a wearable armband, controlling a swarm's shape and formation. [Alonso-Mora et al. 2015] and [Kim et al. 2020] suggested realtime input interfaces with swarm formation control. However, their approach was developed only for mobile robot operation in 2D space. The wearable devices for high mobility of the user were proposed by [Byun and Lee 2019], suggesting an epidermal tactile sensor array to achieve the direct teleoperation of the swarm by human hand.
Previously developed systems have achieved low time delays and high precision of the control, yet their trajectory generating capability is limited to the direct gesture input and simple hand motions. We propose the DronePaint system for drone light painting with DNN-based gesture recognition to make the way we communicate with drones intuitive and intelligent. Only with a single camera and developed software any not-experienced user will be capable of generating impressive light drawings in midair.

SYSTEM OVERVIEW
Before deploying the swarm of drones, the operator positions themselves in front of the webcam, which sends the captured footage to the gesture recognition module. As soon as DronePaint is activated, the module starts to recognize the operator's position and hand gestures, awaiting the "take off" command to deploy the swarm (Fig. 2a). After the drones take off, the gesture recognition module generates a trajectory drawn by the operator with gestures. The developed DronePaint interface allows the operator both to draw and erase the trajectory (Fig. 2c, d) to achieve the desired result. After that, the trajectory is processed by the trajectory planning module to make it suitable for the swarm of drones. Then, the processed trajectory is sent simultaneously to the swarm control module and the flight simulation module using the ROS framework. Finally, the swarm of drones is led by the swarm control module by the received trajectory. Drones complete their work at the command "land" performed by the operator with the appropriate gesture (Fig. 2b).

System architecture
The developed DronePaint system software consists of three modules: human-swarm interface, trajectory processing module, and drone control system. Figure 3: System architecture. The three key modules: human-swarm interface, trajectory processing module, and drone control system.
The hardware part consists of Vicon Tracking system with 12 IR cameras for drone positioning and PC with mocap framework, a PC with CV system and drone-control framework, Logitech HDPro Webcam C920 of @30FPS for recognizing the operator hand movements and gestures, small quadcopters Crazyflie 2.0, and PC with Unity environment for visual feedback provided to the operator (Fig. 3). Communication between all systems is performed by ROS framework.

Gesture recognition
The human-swarm interface consists of two components: hand tracking and gesture recognition modules. The hand tracking module is implemented on the base of the Mediapipe framework. It provides high-fidelity tracking of the hand by employing Machine Learning (ML) to infer 21 key points of a human hand per a single captured frame. The gesture recognition module is based on Deep Neutral Network (DNN) to achieve high precision in human gesture classification, used for drone control and trajectory generation.
For convenient drone control we propose 8 gestures: "one", "two", "three", "four", "five", "okay", "rock", and "thumbs up". A gesture dataset for the model training was recorded by five participants. It consists of 8000 arrays with coordinates of 21 key points of a human hand: 1000 per each gesture (200 per each person). We used normalized landmarks, i.e., angles between joints and pairwise landmark distances as features to predict the gesture class. It resulted in accuracy of 99.75% when performing validation on a test set (Fig.  4). Using coordinates of the landmarks, we calculate the hand coordinates and size on the image received from the USB camera. To calculate the distance between the hand and camera the value of the palm size was applied.

Trajectory processing
To ensure a smooth flight of the drone, a trajectory with equidistant flight coordinates is required. The drawn trajectory may be uneven or contain unevenly distributed coordinates. Therefore, the trajectory processing module smooths the drawn trajectory with an alpha-beta filter (filtration coefficient equals 0.7) and then interpolates it uniformly (Fig. 5). After that, the trajectory coordinates are transformed from the DronePaint interface screen (pixels) to the flight zone coordinate system (meters). The coordinates of the generated trajectory are sequentially transferred to the drone control system using ROS framework. The time intervals between each coordinate transfer depend on the distance between the coordinates and the flight speed of the drone.

Swarm control algorithm
The potential field approach was adjusted and applied to UAVs for robust path planning and collision avoidance between the swarm units. The basic principle of this method lies in the modeled force field, which is composed of two opposing forces, i.e., attractive force and repulsive force. The attractive force pulls the UAV to the desired position, located on the drawn and processed trajectory, while the repulsive force repels the UAV. The repulsive force centers are located on the obstacle surfaces and the other UAVs.

EXPERIMENTAL EVALUATION
Procedure. We invited 7 participants aged 22 to 28 years (mean=24.7, std=1.98) to test DronePaint system. 14.3% of them have never interacted with drones before, 28.6% regularly deal with drones, almost 87% of participants were familiar with CV-based systems or had some experience with gesture recognition. To evaluate the performance of the proposed interface, we collected trajectories drawn by gestures (Fig. 6) and computer mouse from the participants. Drawing by the mouse is a reference point in determining the convenience and accuracy of the proposed method. Figure 6: View of user screen. Hand-drawn trajectory and target trajectory of square shape are illustrated by red and green lines, respectively.
After that, the three best attempts were chosen to evaluate the performance of users with two trajectory generating interfaces. Fig.  7 shows two of three ground truth paths (solid blue line), where for each one a user traces the path several times by hand gesture motion (red dashed line) and a mouse (green dashed line).

Trajectory tracing error
The comparative results of gesture-drawn and mouse-drawn trajectory generation are presented in Table 1.  The experimental results showed that overall mean error equals 5.6 cm (95% confidence interval [CI], 4.6 cm to 6.6 cm) for the gesture-drawn trajectories and 3.1 cm (95% CI, 2.7 cm to 3.5 cm) for the mouse-drawn trajectories. The ANOVA results showed a statistically significant difference between the user's interaction with trajectory patterns: = 4.006, -value = 0.025 < 0.05. On average, the trajectory generated with gestures deviates by 2.5 cm farther from the "ground truth" path compared to one drawn by a computer mouse. The high positional error has presumably occurred due to the lack of tangible experience during the trajectory generation with gesture interface. This problem could be potentially solved by the integration of a haptic device, which will allow users to feel the displacement of their hand and position it more precisely.

CONCLUSIONS AND FUTURE WORK
In this paper, a novel swarm control interface is proposed, in which the user leads the swarm by path drawing with the DNN-based gesture recognition and trajectory generation systems. Thus, Drone-Paint delivers a convenient and intuitive toolkit to the user without any additional devices, achieving both high accuracy and variety of the swarm control. The developed system allowed the participants to achieve high accuracy in trajectory generation (average error by 5.6 cm, max error by 9 cm higher than corresponding values during the mouse input).
In future work, we plan to add an entire body tracking to control a multitude of agents. For example, the movement of the body or hands can change the drone's speed and orientation, which will increase the number of human swarm interaction scenarios. Additionally, we will explore methods to control a swarm in different positioning systems, such as GPS for outdoor performance. Finally, a swarm behavior algorithm for distributing tasks between drones will increase path generation performance and quality.
The proposed DronePaint systems can potentially have a big impact on movie shooting to achieve desirable lighting conditions with the swarm of spotlights controlled by an operator. Additionally, it can be used in a new generation of a light show where each spectator will be able to control the drone display, e.g., navigate the plane, launch the rocket, or even draw the rainbow in the night sky.