Asynchronous Perception-Action-Communication with Graph Neural Networks
Collaboration in large robot swarms to achieve a common global objective is a
challenging problem in large environments due to limited sensing and
communication capabilities. The robots must execute a
Perception-Action-Communication (PAC) loop -- they perceive their local
environment, communicate with other robots, and take actions in real time. A
fundamental challenge in decentralized PAC systems is to decide what
information to communicate with the neighboring robots and how to take actions
while utilizing the information shared by the neighbors. Recently, this has
been addressed using Graph Neural Networks (GNNs) for applications such as
flocking and coverage control. Although conceptually, GNN policies are fully
decentralized, the evaluation and deployment of such policies have primarily
remained centralized or restrictively decentralized. Furthermore, existing
frameworks assume sequential execution of perception and action inference,
which is very restrictive in real-world applications. This paper proposes a
framework for asynchronous PAC in robot swarms, where decentralized GNNs are
used to compute navigation actions and generate messages for communication. In
particular, we use aggregated GNNs, which enable the exchange of hidden layer
information between robots for computational efficiency and decentralized
inference of actions. Furthermore, the modules in the framework are
asynchronous, allowing robots to perform sensing, extracting information,
communication, action inference, and control execution at different
frequencies. We demonstrate the effectiveness of GNNs executed in the proposed
framework in navigating large robot swarms for collaborative coverage of large
environments.
Saurav Agarwal, Alejandro Ribeiro, Vijay Kumar
# Asynchronous Perception-Action-Communication with Graph Neural Networks

###### Abstract

Collaboration in large robot swarms to achieve a common global objective is a challenging problem in large environments due to limited sensing and communication capabilities. The robots must execute a Perception-Action-Communication (PAC) loop--they perceive their local environment, communicate with other robots, and take actions in real time. A fundamental challenge in decentralized PAC systems is to decide _what_ information to communicate with the neighboring robots and _how_ to take actions while utilizing the information shared by the neighbors. Recently, this has been addressed using Graph Neural Networks (GNNs) for applications such as flocking and coverage control. Although conceptually, GNN policies are fully decentralized, the evaluation and deployment of such policies have primarily remained centralized or restrictively decentralized. Furthermore, existing frameworks assume sequential execution of perception and action inference, which is very restrictive in real-world applications. This paper proposes a framework for asynchronous PAC in robot swarms, where decentralized GNNs are used to compute navigation actions and generate messages for communication. In particular, we use aggregated GNNs, which enable the exchange of hidden layer information between robots for computational efficiency and decentralized inference of actions. Furthermore, the modules in the framework are asynchronous, allowing robots to perform sensing, extracting information, communication, action inference, and control execution at different frequencies. We demonstrate the effectiveness of GNNs executed in the proposed framework in navigating large robot swarms for collaborative coverage of large environments.

 Graph Neural Networks, Decentralized Control, Multi-Robot Systems, Robot Swarms

## I Introduction

Decentralized collaboration for navigation of robot swarms through an environment requires high-fidelity algorithms that can efficiently and reliably handle Perception-Action-Communication (PAC) in a feedback loop (Figure 1). The primary challenge in such systems is to decide _what_ a robot should communicate to its neighbors and _how_ to use the communicated information to take appropriate actions. Graph Neural Networks (GNNs) [1] are particularly suitable for this task as they can operate on a communication graph and can learn to aggregate information from neighboring robots to take decisions [2, 3]. They have been shown to be an effective learning-based approach for several multi-robot applications, such as flocking [2, 4], coverage control [5], path planning [6], and target tracking [7]. Furthermore, GNNs exhibit several desirable properties for decentralized systems [8]: (1) _transferability_ to new graph topologies not seen in the training set, (2) _scalability_ to large teams of robots, and (3) _stability_ to graph deformations due to positioning errors.

Neural networks on graphs have been developed in the past decade for a variety of applications such as citation networks [1], classification of protein structures [9], and predicting power outages [10]. A fundamental difference between these applications and the collaboration of robot swarms is that the graph is generally static, whereas the robots are continuously moving, resulting in a dynamic and sparse communication graph. Moreover, control policies are executed on robots in real time with limited computational capabilities, which makes it imperative to provide an efficient framework for decentralized inference.

Some of these challenges have been addressed in recent works on GNNs for multi-robot systems. Tolstaya _et al._[2] proposed an aggregated GNN model that uses aggregated features with hidden outputs of the internal network layers for decentralized GNNs. Gama _et al._[4] proposed a framework for learning GNN models using imitation learning for decentralized controllers. Despite these recent advances and the conceptually decentralized nature of GNNs, evaluation and deployment of GNN policies have largely remained centralized or assume fully connected communication graphs [5, 11]. A primary reason for this is that training of GNNs is usually performed in a centralized setting for efficiency, and there is

Fig. 1: Perception-Action-Communication (PAC) in robots: The perception module utilizes the sensor data to perform tasks such as SLAM, semantic mapping, and object detection. The communication module is responsible for the exchange of information between robots via message buffers, thereby enabling the coordination and collaboration of robots. Limited communication capabilities restrict robots to exchanging messages only with neighboring robots. The planning and control module takes actions from the action module, plans a trajectory, and sends control commands to the actuators. In this paper, we use Graph Neural Networks (GNNs) to compute the messages to be exchanged, the aggregation of received messages, and action inferencing.
a lack of asynchronous PAC frameworks for evaluation and deployment of these policies in decentralized settings.

Recently, Blumenkamp _et al._[12] proposed a framework for running decentralized GNN-based policies on multi-robot systems, along with a taxonomy of network configurations. While our framework focuses more on the architecture design for PAC systems and less on networking protocols, a key difference is that we enable the asynchronous execution of different modules in the framework. In real-world applications with robots running PAC loops, a robot may need to perform perception tasks such as sensing, post-processing of sensor data, constructing semantic maps, and SLAM, which results in a computationally expensive perception module. Most prior work on GNNs for multi-robot systems [2, 4] do not consider the entire PAC loop and focus on action inference. This results in a sequential computation--first, the system evolves, providing a new state, and then the GNN module is executed to generate the message and action, and the process is repeated. In robotics, it is desirable to perform computations asynchronously, which is generally already done for low-level sensing, communication, and control. This motivates the need for a fully asynchronous PAC framework, where the GNN module can be executed at a higher frequency than the perception module. An asynchronous GNN module enables multiple rounds of GNN message aggregation, thereby diffusing information over a larger portion of the communication graph. Furthermore, perception tasks, execution of the current action, and computation of the next action can all be performed asynchronously and concurrently. This has the potential to significantly improve the performance of the system, especially in multi-core processors.

The primary _contribution_ of this paper is a learnable PAC framework composed of four asynchronous modules: perception, inter-robot communication, decentralized GNN message aggregation and inference, and low-level controller. The two key salient features of the framework are:

**(1) Decentralized GNN:** We leverage the aggregated GNN model [2] for decentralized message aggregation and inferencing. The model uses aggregated features comprising hidden outputs of the internal network layers. As the hidden layer outputs from neighboring robots are encoded in the messages, robots need not recompute graph convolutions performed by other robots, thereby distributing the computation over the robots. **(2) Asynchronous modules:** The framework is designed to execute perception and GNN computations asynchronously. This allows the message aggregation and inferencing to be performed at a much higher frequency than the computationally intensive perception tasks.

We also provide a ROS2 [13] compatible open-source implementation of the framework written primarily in C++ for PAC in robot swarms using GNNs.

## II Navigation Control Problem

The navigation control problem, in the paper, considers a homogeneous team of \(N\) mobile robots that needs to navigate through a \(d\)-dimensional environment \(\mathcal{W}\subseteq\mathbb{R}^{d}\) to minimize the expected value of an application-defined cost function. We denote the set of robots by \(\mathcal{V}=\{1,\ldots,N\}\), with the position of the \(i\)-th robot denoted by \(\mathbf{p}_{i}(t)\in\mathcal{W}\) at time \(t\). The state of the \(i\)-th robot at time \(t\) is denoted by \(\mathbf{x}_{i}(t)\in\mathbb{R}^{m}\), which in addition to robot positions may comprise velocities and other sensor measurements. The states of the multi-robot system and the control actions are collectively denoted by:

\[\mathbf{X}(t)=\begin{bmatrix}\mathbf{x}_{1}(t)\\ \mathbf{x}_{2}(t)\\ \vdots\\ \mathbf{x}_{N}(t)\end{bmatrix}\in\mathbb{R}^{N\times m},\quad\mathbf{U}(t)= \begin{bmatrix}\mathbf{u}_{1}(t)\\ \mathbf{u}_{2}(t)\\ \vdots\\ \mathbf{u}_{N}(t)\end{bmatrix}\in\mathbb{R}^{N\times d}.\]

We consider the multi-robot system to evolve as per a Markov model \(\mathbb{P}\), i.e., the state of the system at time \(t+\Delta t\) depends only on the state of the system and the control actions at time \(t\), where \(\Delta t\) is the time required for a single step.

\[\mathbf{X}(t+\Delta t)=\mathbb{P}(\mathbf{X}\mid\mathbf{X}(t),\mathbf{U}(t)) \tag{1}\]

The control problem can then be posed as an optimization problem, where the system incurs a cost given by a cost function \(c(\mathbf{X}(t),\mathbf{U}(t))\) for state \(X(t)\) and control action \(U(t)\) taken at time \(t\), and the goal is to find a policy \(\Pi_{c}^{*}\) that minimizes the expected cost [4]:

\[\Pi_{c}^{*}=\operatorname*{argmin}_{\Pi_{c}}\mathbb{E}\left[\sum_{t=0}^{ \infty}\gamma^{t}c(\mathbf{X}(t),\mathbf{U}(t))\right].\]

Here, the control actions are drawn from a conditional distribution \(\mathbf{U}(t)=\Pi_{c}(\mathbf{U}\mid\mathbf{X}(t))\). Note that the policy \(\Pi_{c}^{*}\) is centralized as the control actions, in the above formulation, require complete knowledge of the state of the system.

### _Decentralized Navigation Control_

In the decentralized navigation control problem, the robots take control actions based on their local information and the information communicated by their neighbors. Thus, we consider that the robots are equipped with a communication device for exchanging information with other robots that are within a given communication radius \(r_{c}\). The problem can

Fig. 2: Learning Perception-Action-Communication (PAC) loops using an architecture composed of three Neural Networks (NN): The perception NN, usually a Convolution NN, computes features using the sensor data obtained through perception. The core of the architecture is a collaborative NN, a Graph NN in our case, which computes the messages to be exchanged between robots and aggregates received messages. The GNN also computes features for the action NN, often a shallow Multi-Layer Perceptron (MLP), the output of which is sent to a planning and control module.
then be formulated on a _communication graph_\(\mathcal{G}=(\mathcal{V},\mathcal{E})\), where \(\mathcal{V}\) represents the set of robots and \(\mathcal{E}\) represents the communication topology of the robots. A robot \(i\) can communicate with another robot \(j\) if and only if their relative distance is less than a given communication radius \(r_{c}\), i.e., an edge \(e=(i,j)\in\mathcal{E}\) exists if and only if \(\|\mathbf{p}_{i}-\mathbf{p}_{j}\|_{2}\leq r_{c}\). We assume bidirectional communication and, therefore, the communication graph is assumed to be undirected.

A robot \(i\) can communicate with its neighbors \(\mathcal{N}(i)\), defined as \(\mathcal{N}(i)=\{j\in\mathcal{V}\mid(j,i)\in\mathcal{E}\}\). Information can also be propagated through multi-hop communication. The set of \(k\)-hop neighbors that the robot \(i\) can communicate with at most \(k\) communication hops is defined recursively as:

\[\mathcal{N}_{k}(i)=\mathcal{N}_{k-1}(i)\cup\bigcup_{j\in\mathcal{N}_{k-1}(i)} \mathcal{N}(j),\quad\text{with }\mathcal{N}_{0}(i)=\{i\}.\]

Let \(\frac{1}{\Delta t_{c}}\) be the frequency at which the robots communicate with each other, i.e., \(\Delta t_{c}\) is the time required for a single communication to take place. Then the total information acquired by robot \(i\) is given by:

\[\mathcal{X}_{i}(t)=\bigcup_{k=0}^{\lfloor\frac{\sigma_{i}^{k}}{\Delta t_{c}} \rfloor}\{\mathbf{x}_{j}(t-k\Delta t_{c})\mid j\in\mathcal{N}_{k}(i)\}.\]

Now, the control actions can be defined in terms of a decentralized control policy \(\pi_{i}\):

\[\mathbf{u}_{i}(t)=\pi_{i}(\mathbf{u}_{i}\mid\mathcal{X}_{i}(t)).\]

Denoting by \(\mathbf{U}(t)=[\mathbf{u}_{1}(t),\dots,\mathbf{u}_{N}(t)]^{\top}\) and \(\mathcal{X}(t)=[\mathcal{X}_{1}(t),\dots,\mathcal{X}_{N}(t)]^{\top}\), the decentralized control problem can be formulated as:

\[\Pi^{*}=\operatorname*{argmin}_{\Pi}\mathbb{E}\left[\sum_{t=0}^{\infty}\gamma ^{t}c(\mathcal{X}(t),\mathbf{U}(t))\right].\]

Computing the optimal decentralized policy is much more challenging than the centralized control as it contains the trajectory histories, unlike the Markov centralized controller [4]. The problem is computationally intractable for complex systems [14], which motivates the use of learning-based approaches. GNNs, in particular, are well-suited for decentralized control for multi-robot systems as they operate on the communication graph topology and can be used to learn a decentralized control policy from training data generated using a centralized controller.

**Remark 1**.: **Asynchronous Communication and Inference:** The formulation for the centralized and decentralized control problems follows the structure given by Gama _et al._[4]. However, similar to several other works on decentralized control, the formulation in [4] assumes that a single step of message aggregation and diffusion is performed at the same time step as the evolution of the system and perception tasks. In contrast, our formulation separates these tasks and executes them asynchronously at a higher frequency by explicitly parametrizing two different time steps. Asynchronous and decentralized execution of modules results in higher fidelity of the overall system.

## III Decentralized Graph Neural Networks

Graph Neural Networks (GNNs) [1] are layered information processing architecture that operate on a graph structure and make inferences by diffusing information through the graph. In the context of multi-robot systems, the graph is imposed by the communication graph, i.e., the graph nodes \(\mathcal{V}\) represent the robots, and the edges represent the communication links \(\mathcal{E}\), as discussed in Section II-A. In this paper, we focus on Graph Convolutional Neural Networks (GCNNs), a layered composition of convolution graph filters with point-wise nonlinearities (\(\sigma\)). The architecture is defined by \(L\) layers, \(K\) hops of message diffusion, and a _shape shift operator_\(\mathbf{S}\in\mathbb{R}^{N\times N},\,N=|\mathcal{V}|\) that is a based on the communication graph. The elements \([\mathbf{S}]_{ij}\) can be non-zero only if \((i,j)\in\mathcal{E}\). The input to the GCNN is a collection of features \(\mathbf{X}_{0}\in\mathbb{R}^{N\times d_{0}}\), where each element \(\mathbf{x}_{i}\) is a feature vector for robot \(i\), \(\forall i\in\mathcal{V}\). The weight parameters for learning on GNNs are given by \(\mathbf{H}_{lk}\in\mathbb{R}^{d_{(l-1)}\times d_{l}},\,\forall l\in\{1,\cdots,L \},\,\forall k\in\{1,\cdots,K\}\), where \(d_{l}\) is the dimension of the hidden layer \(l\) with \(d_{0}\) as the dimension of the input feature vectors. The convolution graph filters are polynomials of the shape shift operator \(\mathbf{S}\) with coefficients defined by the input and the weight parameters \(\mathbf{H}_{lk}\). The output \(\mathbf{Z}_{l}\) of the filter is processed by a point-wise non-linearity \(\sigma\) to obtain the output of layer \(l\), i.e., \(\mathbf{X}_{l}=\sigma(\mathbf{Z}_{l})\). The final output of the GCNN is given by \(\mathbf{X}_{L}\) and the entire network is denoted by \(\Phi(\mathbf{X};\mathbf{S},\mathcal{H})\). Figure 3 shows an architecture with two layers.

To see that GNNs are suitable for decentralized robot swarms, consider the computation \(\mathbf{Y}_{kl}=(\mathbf{S})^{k}\mathbf{X}_{(l-1)}\) for some layer \(l\). These computations can be done recursively: \(\mathbf{Y}_{kl}=\mathbf{S}(\mathbf{S})^{(k-1)}\mathbf{X}_{(l-1)}=\mathbf{S} \mathbf{Y}_{(k-1)l}\). For a robot \(i\), vector \((\mathbf{y}_{i})_{kl}=[\mathbf{Y}_{kl}]_{i}\) can be computed as:

\[(\mathbf{y}_{i})_{kl}=\sum_{j\in\mathcal{N}(i)}[\mathbf{S}]_{ij}(\mathbf{y}_{j} )_{(k-1)l} \tag{2}\]

Fig. 3: A Graph Convolution Neural Network (GCNN) with two layers. Each layer is made up of a convolution graph filter followed by a point-wise non-linearity. GNNs are particularly suitable for decentralized robot swarms as the computations respect the locality of the communication graph.
Here, \(\mathcal{N}(i)\) is the set of neighbors of robot \(i\), and \([\mathbf{S}]_{ij}\) is the \((i,j)\)-th element of the shape shift operator \(\mathbf{S}\). Since the value of \([\mathbf{S}]_{ij}\) is non-zero only if \((i,j)\in\mathcal{E}\), the computation of \((\mathbf{y}_{i})_{kl}\) only involves the features of the neighbors of robot \(i\), i.e., the computation respects the locality of the communication graph. Thus, the robot \(i\) needs to only receive \((\mathbf{y}_{j})_{(k-1)l}\) from its neighbors to compute \((\mathbf{y}_{i})_{kl}\), which makes the overall system decentralized. The collection of hidden feature vectors \((\mathbf{y}_{i})_{kl}\) forms the _aggregated message_[2]\(\mathbf{Y}_{i}\) for robot \(i\), which is precisely the information the robot \(i\) needs to communicate to its neighboring robots.

**Definition 1**.: _Aggregated Message \(\mathbf{Y}_{i}\):_ The aggregated message for a robot \(i\) is defined as:

\[\mathbf{Y}_{i}=\begin{bmatrix}\left(\mathbf{y}_{i}\right)_{01}=\left(\mathbf{ x}_{i}\right)_{0}&\left(\mathbf{y}_{i}\right)_{11}&\cdots&\left(\mathbf{y}_{i} \right)_{(K-1)1}\\ \vdots&\vdots&\ddots&\vdots\\ \left(\mathbf{y}_{i}\right)_{0l}=\left(\mathbf{x}_{i}\right)_{l-1}&\left( \mathbf{y}_{i}\right)_{1l}&\cdots&\left(\mathbf{y}_{i}\right)_{(K-1)l}\\ \vdots&\vdots&\ddots&\vdots\\ \left(\mathbf{y}_{i}\right)_{0L}=\left(\mathbf{x}_{i}\right)_{L-1}&\left( \mathbf{y}_{i}\right)_{1L}&\cdots&\left(\mathbf{y}_{i}\right)_{(K-1)L}\end{bmatrix}\]

where, \(\left(\mathbf{x}_{i}\right)_{0}\) is the input feature for robot \(i\), \(\left(\mathbf{x}_{i}\right)_{l}\) is the output of layer \(l\) of the GNN, and

\[\begin{split}\left(\mathbf{y}_{i}\right)_{kl}=\sum_{j\in\mathcal{ N}(i)}\left[\mathbf{S}\right]_{ij}(\mathbf{y}_{j})_{(k-1)l},\\ \forall k\in\{1,\cdots,K-1\},\,\forall l\in\{1,\cdots,L\}\end{split} \tag{3}\]

Note that the dimension of each vector in a row is same but the dimension across rows may be different, i.e., \(\mathbf{Y}_{i}\) is a collection of matrices and not a proper tensor.

The overall algorithm for message aggregation and inference using a GNN is given in Algorithm 1. The output of the GNN is the output of the last layer \(\mathbf{X}_{L}\). To completely diffuse a signal \(\mathbf{x}_{i}\) across the network, each robot needs to exchange messages and execute Algorithm 1 for \(KL\) times. This would require that the GNN message aggregation must be executed at a frequency that is \(KL\) times higher than the frequency of perception. Depending on the application and the number of layers of the network, this may not be always feasible. However, due to the stability properties of the GNNs, they perform well even when the message aggregation is executed at a lower frequency.

```
Input : Messages \(\{\mathbf{Y}_{j}\mid j\in\mathcal{N}(i)\}\), model parameters \(\mathcal{H}\) Output : Inference output \((\mathbf{x}_{i})_{L}\), messages \(\mathbf{Y}_{i}\) \((\mathbf{x}_{i})_{0}\leftarrow\mathbf{x}_{i}\);// Input feature for robot \(i\)
1for\(l=1\)do
2\((\mathbf{y}_{i})_{l-1}\leftarrow(\mathbf{x}_{i})_{l-1}\);
3\(\mathbf{z}_{l}\leftarrow(\mathbf{y}_{i})_{0l}\,\mathbf{H}_{lk}\);
4for\(k=1\)to\(K\)do
5\((\mathbf{y}_{i})_{kl}\leftarrow\mathbf{0}\);
6for\(j\in\mathcal{N}(i)\)do
7\((\mathbf{y}_{i})_{kl}\leftarrow\left(\mathbf{y}_{i}\right)_{kl}+\left[\mathbf{S }\right]_{ij}(\mathbf{y}_{j})_{(k-1)l}\);
8
9 end for
10\(\mathbf{z}_{l}\leftarrow\mathbf{z}_{l}+\left(\mathbf{y}_{i}\right)_{kl}\, \mathbf{H}_{lk}\);
11
12 end for
13\(\mathbf{z}_{l}\leftarrow\mathbf{z}_{l}+\mathbf{b}_{l}\); // If bias is used
14\((\mathbf{x}_{i})_{l}\leftarrow\sigma(\mathbf{z}_{l})\); // Point-wise non-linearity
15
16 end for
17\(\mathbf{Y}_{i}\leftarrow\left[\mathbf{x}_{i},(\mathbf{y}_{i})_{kl}\right]\); // Def. 1
```

**Algorithm 1**GNN Aggregation and Inference

**Remark 2**.: The computation of each individual element of \((\mathbf{y}_{i})_{kl}\) is a single matrix multiplication, as the computation of \((\mathbf{y}_{j})_{(k-1)l}\) is already performed by the neighboring robot \(j\). Thus, aggregated GNNs naturally distribute computation across robots. Furthermore, the size of the aggregated message \(\mathbf{Y}_{i}\) is defined by the architecture of the GNN, the dimension of the input feature vector, and the dimension of the output. It is independent of the number of robots in the system, making it scalable to large robot swarms. These properties make the aggregated GNNs suitable for decentralized robot swarms and, therefore, are used in the proposed framework for asynchronous PAC.

## IV Asynchronous PAC Framework

The framework is designed to efficiently perform decentralized and asynchronous Perception-Action-Communication (PAC) loops in robot swarms. It comprises four primary modules for different PAC subtasks that are executed asynchronously: (1) Perception, (2) Inter-Robot communication, (3) GNN message aggregation and inference, and (4) Low-level actuator controller. The asynchronous design of the framework is motivated by two main advantages:

**Concurrent execution:** Asynchronous modules allow non-related subtasks to be executed concurrently, especially the computationally expensive perception module and relatively faster GNN module. As a result, the GNN module can perform several steps of message aggregation, thereby diffusing information over a larger number of nodes in the communication graph, while the perception module is still processing the sensor data. Furthermore, concurrent execution significantly reduces the computation time when executed on multi-core processors, thereby enabling better real-time performance.

**Variable frequency:** Asynchronous modules allow different subtasks to be executed at different frequencies. In particular, the GNN module can be executed at a higher frequency than the perception module, which has not been possible in prior work. Similarly, as is often the case, the communication and the low-level actuator controller modules can run at a higher frequency than the GNN message aggregation module. Generally, a GNN policy computes a high-level control action, which is then executed by a low-level controller for several time steps. Even in the case where the perception task is minimal, asynchronous execution allows the GNN module to perform several steps of message aggregation while the low-level controller is executing the previous control action.

In prior work, the perception and GNN computations were considered to be executed synchronously, even if communication and low-level controller are asynchronous, affecting the computation time and the number of message aggregations that can be performed by the GNN module. This is mitigated in
our proposed framework by allowing asynchronous execution. We now describe the different modules of the framework.

### _Perception_

The perception module is responsible for getting the sensor data and processing it to obtain the input features for the GNN. The module may also contain application-specific tasks such as semantic mapping, object detection, and localization, which makes the module computationally expensive. The entire perception module is typically executed at a low frequency in applications that require significant computation. In our specific implementation for the coverage control problem in Section V, we use a CNN to generate a low-dimensional feature vector for the GNN module.

### _Inter-Robot Communication_

Robots _broadcast_ their message \(\mathbf{Y}_{i}\), for robot \(i\), to other robots within their communication range \(r_{c}\), i.e., the neighboring robots \(\mathcal{N}(i)\). They also receive messages from their neighbors: \(\mathbf{Y}_{j},\forall j\in\mathcal{N}(i)\). Generally, communication hardware may allow either receiving a message or transmitting a message at a given time. Thus, the communication module may need to be executed twice the frequency of the GNN message aggregation module. We use two buffers to maintain messages: a transmitter buffer \(\mathrm{T_{x}}\), which stores the message to be transmitted, and a receiver buffer \(\mathrm{R_{x}}\), which stores the most recent message received from each neighbor. The module is composed of three submodules: a message buffer manager, a transmitter, and a receiver.

_Message Buffer Manager:_ The message buffer manager handles the transmitter \(\mathrm{T_{x}}\) and receiver \(\mathrm{R_{x}}\) buffers. When a new message is generated by the GNN module, the message buffer performs five sequential actions (1) momentarily locks the transmitter and receiver to avoid race conditions in writing and reading the buffers, (2) loads the new message \(\mathbf{Y}_{i}\), received from the GNN module, onto the transmitter buffer, (3) sends the contents of the receiver buffer to the GNN module, (4) clears the receiver buffer, and (5) releases the lock on the buffers. Since having a lock on the communication buffers is not desirable, our implementation makes efficient use of _smart memory pointers_ in C++ to exchange the contents from the GNN module and the buffers, i.e., the actual contents are not loaded to the buffers, but the pointers to the memory locations are exchanged. Clearing the receiver buffer is critical to ensure old messages, which would have been used in the previous GNN message aggregation, are not considered further.

_Transmitter:_ The transmitter submodule broadcasts the message \(\mathbf{Y}_{i}\), using the \(\mathrm{T_{x}}\) message buffer, to neighboring robots \(\mathcal{N}(i)\). Additionally, an identification is attached to the message so that the receiving robot can rewrite old messages in the buffer with the most recent message from the same robot.

_Receiver:_ The receiver submodule receives the messages broadcast by the neighboring robots \(\mathcal{N}(i)\). If a message is received from a robot that already has a message in the receiver buffer, the message is overwritten with the most recent message, i.e., only the most recent message from a neighboring robot is stored in the receiver buffer. The size of the buffer needs to be dynamic as it is dependent on the number of neighbors, which may change over time.

### _GNN Message Aggregation and Inference_

The GNN message aggregation module has two tasks: (1) generate messages to be communicated to neighboring robots in the next time step, and (2) perform inference for control actions. Our framework uses the aggregated GNN model, described in Section III. The system is fully decentralized, i.e., each robot has its own GNN model and the inference is performed locally. An important attribute of the aggregated GNN model is that the size of the messages is dependent on the number of layers in the network, and is independent of the number of robots. Thus, the system is highly scalable to large robot swarms. The module is executed at a higher frequency than the perception module.

### _Low-Level Controller_

The low-level controller interfaces the framework with the robot actuators. It receives the control action at the end of the computation of the GNN module and executes it for a pre-defined time interval. The controller is executed at a very high frequency to ensure that the control actions are reliably executed in real-time while correcting the control commands using a feedback loop. Since the implementation of the framework is designed to work with ROS2, any existing package for low-level control can be used with the framework.

## V Evaluation on the Coverage Control Problem

We evaluate our approach for asynchronous Perception-Action-Communication (PAC) on the coverage control problem [15] for a swarm of 32 robots in simulation. Coverage control requires the collaboration of a robot swarm to provide sensor coverage to monitor a phenomenon or features of interest in an environment. An _importance density function_ (IDF) [5] is used to model the probability distribution of features of interest. The problem is widely studied in robotics and has applications in various domains, including mobile networking [16], surveillance [17], and target tracking [18]. We consider the decentralized setup where the robots have limited sensing and communication capabilities. Furthermore, the environment is not known a priori, and the robots use their sensor to make localized observations of the environment.

Coverage control is posed as an optimization problem using _Voronoi partitions_\(\mathcal{P}_{i}\) to assign each robot a distinct subregion of the environment [19, 20, 5]. The objective of the coverage problem is to minimize the cost to cover the environment, weighted by the IDF \(\Phi(\cdot)\), see [20] for details.

\[\mathcal{J}(\mathbf{p}_{1},\ldots,\mathbf{p}_{|\mathcal{V}|})=\sum_{i=1}^{| \mathcal{V}|}\int_{\mathcal{P}_{i}}\|\mathbf{p}_{i}-\mathbf{q}\|^{2}\Phi( \mathbf{q})\mathbf{d}\mathbf{q} \tag{4}\]

We model a 1024 m\(\times\)1024 m rectangular environment and robots that make 64 m\(\times\)64 m localized sensor observations. Each robot maintains a local map of size 256 m\(\times\)256 m with cumulatively added observations and an obstacle map of the
same size for the boundaries of the environment. Based on our contemporary work on coverage control, these maps are processed by a CNN with three layers of 32 latent size each. Additionally, relative positions of neighboring robots, obtained either through sensing or communication, within a communication radius of 128 m is mapped onto a two-channel (\(x\) and \(y\)) normalized heatmap. These four maps are concatenated to form the input to a CNN, which is composed of three layers of 32 latent size and generates a 32 dimensional feature vector for each robot. The sensing and processing of maps by CNN constitute the perception module of the PAC framework. The output of the CNN is augmented with the normalized position of the robot to form a 34-dimensional feature vector, which is used as the input to the GNN with two layers of 256 latent size and \(K=3\) hops of communication. The output of the GNN is processed by a multi-layer perceptron (MLP), i.e., an action NN, with one hidden layer and 32 latent size to compute the control velocities for the robot. These CNN and GNN architectures are part of an ongoing work on coverage control1.

Footnote 1: Appropriate references will be added in the final publication.

The entire model is trained using imitation learning with the ground truth generated using a centralized clairvoyant Lloyd's algorithm that has complete knowledge of the IDF and the positions of the robots. We compare our approach with a decentralized and a centralized Lloyd's algorithm [19]. The decentralized algorithm is only aware of its maps and the relative positions of neighboring robots, whereas the centralized algorithm has the combined knowledge of all the robots and their global positions. We executed these algorithms in our asynchronous PAC framework for four different operating frequencies from (1.25 Hz to 5 Hz) of the perception module. Our approach performs significantly better than the decentralized and centralized algorithms, see Figure 4. We also evaluated our approach with noisy position information, see Figure 5. These results show the efficacy of asynchronous PAC systems for decentralized control of robot swarms.

## VI Conclusion

We presented a framework for asynchronous Perception-Action-Communication with Graph Neural Networks (GNNs). Perception comprises application-specific tasks such as sensing and mapping, while the action module is responsible for executing controls on the robot. The GNN bridges these two modules and provides learned messages for collaboration with other agents. The decentralized nature of the GNN enables scaling to large robot swarms. The asynchronous capability

Fig. 4: Evaluation of coverage control algorithms, within our decentralized PAC framework, for four different operating frequencies (1.25 Hz to 5 Hz) of system evolution, which includes all perception tasks. The decentralized GNN, with CNN for perception, is trained using imitation learning with the ground truth generated using a clairvoyant Lloyd’s algorithm. The plots show the coverage cost, averaged over 30 environments, for 600 time steps and are normalized by the cost at the starting configuration of the system. Our approach significantly outperforms decentralized and centralized Lloyd’s algorithms.

Fig. 5: Evaluation of coverage algorithms with a Gaussian noise \(\epsilon\) added to the position of each robot, i.e., the sensed position \(\bar{\mathbf{p}}_{i}=\mathbf{p}_{i}+\epsilon\). The perception module is executed at 2.5 Hz for all four cases. It is interesting that the performance of Lloyd’s algorithm increases slightly with noise, as this leads to discovering more of the IDF. However, the algorithms converge to a stable configuration after more number of steps. The decentralized GNN approach outperforms the two Lloyd’s algorithms in all cases, thereby demonstrating the robustness of our approach to noisy information.
of our system allows the execution of GNN-based message aggregation and inferencing at a frequency in between that of perception and action modules. We demonstrated the effectiveness of using learnable PAC policies in a decentralized manner for the coverage control problem. The framework will allow evaluation and deployment of asynchronous PAC systems with GNNs with large robot swarms in real-world applications.

Future work entails validating the system on real robots--an essential yet challenging task due to difficulties operating a large number of robots. We also plan to evaluate our framework on other applications, such as flocking and target tracking, and analyze the compatibility of our framework with other GNN architectures.
