A Distributed Machine Learning-Based Approach for IRS-Enhanced Cell-Free MIMO Networks

In cell-free multiple input multiple output (MIMO) networks, multiple base stations (BSs) collaborate to achieve high spectral efficiency. Nevertheless, high penetration loss due to large blockages in harsh propagation environments is often an issue that severely degrades communication performance. Considering that intelligent reflecting surface (IRS) is capable of constructing digitally controllable reflection links in a low-cost manner, we investigate an IRS-enhanced downlink cell-free MIMO network in this paper. We aim to maximize the sum rate of all the users by jointly optimizing the transmit beamforming at the BSs and the reflection coefficients at the IRS. To address the optimization problem, we propose a fully distributed machine learning algorithm. Different from the conventional iterative optimization algorithms that require a central processing at the central processing unit (CPU) and large amount of channel state information and signaling exchange between the BSs and the CPU, in the proposed algorithm, each BS can locally design its beamforming vectors. Meanwhile, the IRS reflection coefficients are determined by one of the BSs. Simulation results show that the deployment of IRS can significantly boost the sum user rate and that the proposed algorithm can achieve a high sum user rate with a low computational complexity.


I. INTRODUCTION
With the surge of data traffic in the fifth generation (5G)and-beyond wireless communication networks, small-cell base stations and large-scale antenna arrays have been increasingly deployed [1].The colocated multiple-input multiple-output (MIMO) architecture adopted by these BSs, however, leads to severe intercell interference for cell-edge users [2].In this context, cell-free MIMO has emerged as an attractive solution to eliminating intercell interference.In such a new network architecture, all the BSs cooperatively serve the users occupying the same time-frequency resources by exploiting the aggressive spatial user multiplexing [3], [4].Connected to the central processing unit (CPU) through front-haul links, the BSs simultaneously send their data streams to the served users.Thereby, cell-free MIMO networks experience no cell boundaries and achieve uniform coverage at high spectral efficiency.However, cell-free MIMO networks often suffer from a low signal-to-noise ratio (SNR) due to the harsh propagation environment, e.g.urban areas with dense buildings [5].Although deploying more multi-antenna BSs can alleviate the issue, conventional large-scale antenna arrays result in skyrocketing hardware and power costs as well as signal processing complexity.
As one of the most cutting-edge techniques in recent years, intelligent reflecting surface (IRS) has shown a huge potential to address the issue of harsh propagation, in a cost-and energy-efficient manner [6]- [8].To be specific, IRS is a uniform planar array consisting of a large number of programmable passive reflection elements whose amplitudes and phases can be adaptively adjusted.Accordingly, IRS is capable of achieving smart radio environment by creating favorable propagation conditions without using active radio-frequency chains/amplifiers.Recently, IRS has found wide applications in wireless communications [9]- [12].In [9], the authors investigated an IRS-assisted single-cell downlink multi-user MIMO network, where the weighted sum-rate (WSR) of all users was maximized by optimizing the transmit beamforming and IRS phase shifts.In [10], the authors considered a multi-cell MIMO scenario and jointly optimized the transmit beamforming at each BS and the IRS phase shifts to maximize the WSR by utilizing a block coordinate descent algorithm.In [11], the authors targeted at maximizing the secrecy rate for an IRS-aided MIMO system with a multi-antenna eavesdropper.In [12] and [13], IRS backscatter-assisted downlink and uplink multi-cell communication networks were investigated, respectively, and the beamforming vectors at the power beacon and the IRSs were optimized to maximize the WSR.
There have been several works integrating the IRS into cellfree MIMO networks [14]- [18].In [14], tight approximation expressions of the outage probability and achievable rate were analytically derived.The numerical results revealed that the performance of cell-free communication networks can be enhanced by deploying an IRS.In [15], multiple IRSs were employed to assist a single-cell communication system, where the transmit beamforming and the IRS-based beamforming were optimized to maximize the sum user rate.In [16], an op-timization problem was formulated to maximize the minimum achievable rate.In particular, the transmit beamforming was optimized based on instantaneous channel state information (CSI) and the IRS phase shifts were optimized based on the statistical CSI.In [17], the authors focused on the energy efficiency maximization problem.However, the aforementioned works adopted centralized optimization algorithms that require a large amount of CSI and signaling exchanges between the BSs and the CPU, which limits the system scalability.The authors in [18] proposed a decentralized optimization algorithm for cooperative beamforming in IRS-assisted cell-free MIMO networks.Although no CSI exchange is required, the optimization variables need to be shared among neighboring BSs during the iterations of the algorithm.Up to now, a fully distributed algorithm that can jointly optimize the transmit beamforming and IRS reflection coefficients without CSI and signaling exchanges is still missing.Moreover, these works rely on iterative optimization algorithms that would incur an immense computational complexity.
As a key enabling technology for 5G-and-beyond wireless communication systems, machine learning has potential to solve mathematically intractable non-convex optimization problems [19], [20].It has been used in IRS-assisted singlecell communication networks [21]- [24].In [21], the authors investigated a single-user multiple-input single-output scenario, where the SNR is maximized by optimizing IRS phase shifts using deep reinforcement learning (DRL).The authors in [22] further studied a multi-user scenario and applied DRL to jointly optimize the transmit beamforming matrix at the BS and the phase shifts at the IRS.In [23], DRL was used to design secure beamforming with the worst-case secrecy rate and data rate constraints.In [24], the beamformers at the BS and the IRS in a single-cell dowlink communication network were designed directly based on received pilots using a graph neural network (GNN).
To the best of our knowledge, machine learning has not been exploited in IRS-assisted cell-free MIMO networks.In this paper, we propose a novel distributed machine learning algorithm to jointly optimize the beamforming vectors at the BSs and the reflection coefficient vector at the IRS.Our major contributions are summarized as follows: • We investigate an IRS-enhanced cell-free MIMO network and formulate a joint transmit beamforming and reflect beamforming optimization problem aiming to maximize the sum user rate.Then we develop an centralized alternative optimization (AO)-based baseline algorithm to solve the optimization problem.• We novelly propose a fully distributed machine learning algorithm where each BS determines its own beamforming vectors using a GNN based on its local CSI.The IRS reflection coefficients can be determined by only one of the BSs.Our proposed distributed machine learning framework does not require any CSI exchange, and thus is front-haul friendly.• Different from conventional optimization algorithms that rely on iterative optimization, the proposed algorithm can directly obtain the transmit and reflect beamforming vectors as the outputs of the well trained GNNs.We provide extensive simulation results to demonstrate the effectiveness of the proposed distributed machine learning approach in terms of boosting the sum user rate.The rest of the paper is organized as follows.Section II presents the system model and formulates the optimization problem.An AO-based baseline solution is introduced in Section III.In Section IV, a distributed machine leaning-based algorithm for joint design of BS transmit beamforming and IRS reflection coefficients is illustrated.Simulation results are provided in Section V, whereas main conclusions are drawn in Section VI.
Notations: In this paper, scalars, vectors and matrices are represented by italic letters, boldface lower-case letters, and boldface upper-case letters, respectively.(•) T and (•) H and Tr(•) are the transpose, conjugate transpose and trace operations, respectively.[A] i,j denotes the (i, j)-th element of a matrix A. vec(A) is the vectorization of a matrix A and diag(a) is a diagonal matrix whose diagonal elements are the corresponding elements in vector a.CN (µ, σ 2 ) stands for a circularly symmetric complex Gaussian distribution with mean µ and variance σ 2 .{a} and {a} denote the real part and imaginary part of a complex number a, respectively.C M ×N and R M ×N represent the space of complex-valued and realvalued matrices, respectively.⊗ is the Kronecker product.

II. SYSTEM MODEL AND PROBLEM FORMULATION A. System Model
Fig. 1 shows an IRS-enhanced downlink cell-free MIMO network, consisting of I multi-antenna BSs with absolutely identical hardware configuration, K single-antenna users and an IRS.Each of the BSs is equipped with M antennas and the IRS has L passive reflecting elements.The index sets of BSs, users, and IRS elements are denoted by It is assumed that only the phase shift is adjustable for each element of the IRS.The reflection coefficient vector of the IRS is given by v = e jθ1 , e jθ2 , • • • , e jθ L , where θ l ∈ [0, 2π), l ∈ L. Under the control of the central processing unit (CPU), the BSs collaborate to send the information to the users while the IRS is reasonably deployed to enhance the communication.
the channels from user k to BS i, from BS i to the IRS and from user k to the IRS, respectively.The superposed channel from BS i to user k is given by In the cell-free system, the data requested by each user is simultaneously sent by all the BSs.Thus, the received signal at user k is given by where w i,k ∈ C M ×1 is the beamforming vector from BS i to user k, s k is the data symbol for user k, and n k ∼ CN (0, δ 2 ) is the additive white Gaussian noise.For brevity, we define The received signal at user k is further given by Accordingly, the achievable data rate of user k is given by

B. Problem Formulation
This paper aims to optimize the beamforming vectors W = {w i,k |∀i ∈ I, ∀k ∈ K} at the BSs and the reflection coefficient vector v at the IRS to maximize the sum rate of all the users.Mathematically, the optimization problem is formulated as where P max is the maximum transmit power per BS.
III. BASELINE SOLUTION In this section, we develop an baseline solution to optimize the transmit beamforming vectors where the IRS reflection coefficients are randomly configured.We first transform the problem (P0) into a tractable form using fractional programming, and then employ the method of AO to solve it.

A. Problem Transformation
Using Lagrangian dual transform to tackle the logarithm functions and introducing auxiliary variable α k , the objective function is rewritten as where γ k denotes the signal-to-interference-and-noise-ratio (SINR) at user k.Introducing an auxiliary variable where A k and B k are respectively given by We consider zero-forcing (ZF) beamforming with power allocation (PA) as the transmit beamformer to eliminate interuser interference and achieve near-optimal solution [17], [25].The global channel information of all the users can be expressed as

and the global ZF precoding matrix is computed by
where W ∈ C IM ×K .Then we have w i,k = P i,k w i,k , where P i,k represents the transmit power allocated to the k-th user at the i-th BS and is the normalized beamforming vector from BS i to user k.Accordingly, the new objective function is given by With the IRS reflection coefficient vector v randomly configured, the problem (P0) is reformulated as However, this problem is still difficult to solve directly.In view of this, we will apply the method of AO to solve it in the following subsection.

B. Problem Optimization
This subsection will develop an alternate method to address the optimization problem by two steps.In the first step, the variables α k and β k are optimized with P i,k fixed.In the second step, the variable P i,k is optimized with α k and β k fixed.
Step-1): Optimizing α k and β k With P i,k given, we separately take the derivative of α k and β k to find the optimal α It is derived that the optimal α • k and β • k are respectively given by Step-2): With α k and β k given, the objective function can be simplified as Thus, the problem is equivalently reformulated as This problem is convex over P i,k and easy to solve.

C. Complexity Analysis
The computational complexity of ZF beamforming in (10) is O(IM K 2 ) [26], [27].The total computational complexity of the baseline solution is approximately given by where T ite represents the iteration number for the alternative optimization in Section III-B.

IV. PROPOSED DISTRIBUTED MACHINE LEARNING ALGORITHM
The baseline solution requires iterative optimization, which incurs a high computational complexity.Moreover, it is a centralized algorithm that relies on global CSI information.The optimal beamforming vectors are determined by the CPU and then transmitted to the BSs, resulting in a heavy front-haul overhead.
In this section, we aim to develop a distributed machine learning algorithm where each BS uses an independent GNN to design the local beamforming vectors according to its local CSI information.Moreover, the reflection coefficients of the IRS are controlled by only one of the BSs locally.The structure of the proposed distributed machine learning algorithm will be elaborated in the following subsections.

A. Preliminaries of GNN
Graphs are used to characterize non-Euclidean data.A typical graph is expressed as G = (V, E), where V and E denote the sets of nodes and edges, respectively [28].A node is denoted by v k ∈ V and an edge is denoted by (v k , v j ) ∈ E. The connections between the nodes are represented by an adjacency matrix A, where For an undirected graph, the adjacency matrix is symmetric, and the main diagonal elements are all zero.Each node has its own attribute feature.In this paper, the feature of v k is characterized by a node feature vector x k .We adopt spatial graph convolutional networks to update the node feature vectors by aggregating information from their neighbour nodes.Under the message passing neural network framework [29], the node feature vector of v k in the n-th iteration is given by where ∆ n is the set aggregation function and Ω n is the combination function (For more details, please kindly refer to Section IV-C).The parameters of ∆ n and Ω n are shared among all the nodes, and thus GNNs are scalable to varying node sizes [30].On the other hand, the conventional neural networks can only be applied to a particular number of nodes.
In our considered IRS-enhanced cell-free MIMO network, the number of users may vary over time.In this light, the number of conventional neural networks required is equal to that of possible users.This observation motivates us to adopt GNNs.

B. Graph Representation of the IRS-Enhanced Cell-Free MIMO Network
We will show in Section V-C that it does not matter which BS determines the IRS reflection coefficients.Without loss of generality, we assume that BS 1 determines the IRS reflection coefficients in this paper.As shown in Fig. 2, we construct a graph for each local network.Specially, in addition to its local beamforming vectors, BS 1 also determines the configuration of the IRS reflection coefficients.Hence, graph 1 is constructed by BS 1, the K users and the IRS.The other BSs except BS 1 only determine their own local beamforming vectors.Accordingly, graph i, ∀i > 1, is constructed by BS i and the K users.
The structures of the graphs are shown in Fig. 3, where v i,k denotes node k of graph i and x i,k denotes the node feature vector of v i,k .Graph 1 is defined as is the set of nodes and E 1 is the set of edges in graph 1.More specifically, v 1,0 represents the IRS and v 1,k , ∀k ∈ K, represents user k.Similarly, graph i, ∀i > 1, is defined as  edges in graph i.Each graph is constructed as a undirected graph, where each node is connected to all other nodes, i.e., an edge exists between any two nodes.As such, the adjacency matrix of G i , i ∈ I, denoted by A i , has [A i ] k,j = 1, ∀k = j.

C. Structure of GNNs
The aim of the GNNs is to obtain efficient node feature vectors that contain enough information to design the BS beamforming vectors and IRS reflection coefficient vector.The overall structure of the GNNs used is shown in Fig. 4 and is detailed as follows: 1) Input: The initial node feature vector taking the node input feature of v i,k is denoted by x 0 i,k .The input feature of user node v i,k , ∀i ∈ I, k ∈ K, is the vectorized CSI from BS i to user k given by where is the cascaded channel from BS i to user k through the reflection of the IRS.The CSI information is separated by real and imaginary components as neural networks only support real-valued input.The dimension of x 0 i,k is 2M (L + 1).
Since the IRS contains channel information of all the user channels, we design the input feature of the IRS node as the mean of user input features.Recall that the IRS node is only included in graph 1, and thus the input feature of the IRS node is given by where F mean (•) is the element-wise mean function.
2) Graph convolutions: The initial node feature vectors are updated by N layers of graph convolutions.In our proposed structure of GNNs, all the nodes share the same node update role, which is shown in Fig. 5.To be specific, the update rule for the n-th layer at node v i,k is given by where N (v i,k ) is the set of neighbour nodes of v i,k , Ψ n i (•) is a multi-layer perceptron (MLP) used to extract information from the neighbour node feature vectors of the last layer, Φ(•) is the aggregation function that aggregates information from the neighbour nodes and Ω n i (•) is the combining function that combines the aggregated information m n i,k with its own information x n−1 i,k , which is parameterized by a MLP.Note that in each GNN, Ψ n i (•) and Ω n i (•) share the same weights for all the nodes, which enables the proposed distributed machine learning algorithm to be generalized to an IRSenhanced cell-free network with varying numbers of users.The aggregation function is usually chosen to be a permutationinvariant function.In this paper, we set Φ(•) as an elementwise max function F max (•) following [31].After N layers of graph convolutions, the node feature vectors contain the information within its N -hop neighborhood nodes and learn to handle inter-user interference.
3) Output: Each node feature vector of the N -th layer is followed by a fully connected layer (FCL) to output the beamforming vector or IRS reflection coefficient vector.As neural networks only support real-valued output, for user node v i,k , ∀i ∈ I, k ∈ K, a FCL with 2M units outputs a realvalued vector w i,k ∈ R 2M ×1 .Then a normalization layer (NL) is employed in each GNN.In particular, GNN i converts each w i,k , ∀k ∈ K, to a complex-valued vector w i,k ∈ C M ×1 and performs the following steps: For IRS node v 1,0 , a FCL with 2L units outputs a realvalued vector v ∈ R 2L×1 .To satisfy the unit modulus constraint, v is followed by the following NL:

D. Offline Training
We adopt a centralized-training-distributed-deployment algorithm framework, as shown in Fig. 6  information.The weight vectors of the GNNs are updated in an unsupervised manner according to the following loss function: where T is the number of training samples, and w t k and v t are the beamforming vectors and IRS reflection coefficient vector determined by the GNNs for the t-th training sample, respectively.The GNNs learn to minimize the loss function using stochastic gradient descent (SGD).Since the loss function is the opposite value of the optimization objective function, the sum user rate increases as the loss function decreases.The calculation of the loss function requires the global CSI information, which enables the GNNs to learn to deal with interference from other BSs.Noting that the training phase is completed offline, the computational complexity is less a concern.

E. Online Deployment
Different from the centralized training, the online deployment is performed in a fully distributed manner.To do so, each BS updates its local GNN by downloading the well trained weight vectors from the CPU.After obtaining the local CSI information, each BS can determine its local beamforming vectors directly using its local GNN.The IRS reflection coefficient vector is determined by the GNN of BS 1.In contrast to the conventional optimization algorithms that require the global CSI information, the well trained distributed machine learning algorithm requires no CSI exchange between the BSs and the CPU.

F. Complexity Analysis
As the training phase is performed offline, we focus on the computational complexity of the online inference phase.For the input layer, the computational complexity of the average operation at the IRS node over K user input features is O(2KM (L + 1)).We denote the dimensions of Ψ n i and Each neuron of the MLPs uses an activation function.Accordingly, the computational complexity of the graph convolutional layers is q n j,i =1 h q n j,i −1 +1 h q n j,i .For the output layer, the computational complexity is The total computational complexity is the sum of the computational complexity of the input layer, graph convolutional layers output layer.

V. SIMULATION RESULTS
In this section, we provide performance evaluation for the proposed distributed machine learning algorithm in comparison with the benchmark methods.

A. Simulation Setup
In the simulations, we consider an IRS-enhanced cell-free MIMO network as illustrated in Fig. 7, where there are I = 3 BSs cooperatively serving the users.The coordinates of the BSs are (120, 0, 10) m, (60, −60 √ 3, 10) m and (60, 60 √ 3, 10) m, respectively.The IRS is located at (0, 0, 10) m.The users are randomly distributed in the xy-plane with x ∈ [0, 20] m and y ∈ [ −20, 20] m to achieve generalization to user locations.The BSs are assumed be uniform linear arrays parallel to the x-axis.The IRS is assumed to be a uniform square array parallel to the yz-plane with √ L elements per column and

√
L elements per row.The noise power is set to δ 2 = −90 dBm.
The large-scale path loss in dB is computed by where 0 = −30 dB is the path loss at the reference distance, α is the path-loss exponent, d is the length of the transmission link and d 0 = 1 m is the reference distance.Due to the effect of blockages, the path-loss exponent of BS-user channels is set to α BU = 3.75.IRSs are usually deployed at appropriate locations to provide line-of-sight (LOS) links, and thus the path-loss exponents of BS-IRS channels and IRSuser channels are set to α BI = α IU = 2.2.The small-scale fading of BS-user channels is modelled as Rayleigh fading, which is composed of uncorrelated CN (0, 1) elements.For IRS-assisted links, the small-scale fading is assumed to be Rician fading.To be specific, the small-scale fading of the channel from BS i to the IRS is given by where κ is the Rician factor, which is set to 10, G ], the array response vector is given by where and are the array response vectors with respect to the vertical direction and the horizontal direction, respectively, in which λ is the wavelength and d I is the IRS element spacing.In the simulations, we consider the half-wavelength element spacing, i.e., d I = λ 2 .Similarly, when a plane wave is impinging on the BS from the azimuth angle ψ ∈ [−π, π] and elevation angle φ ∈ [− π 2 , π 2 ], the array response vector is given by where d B is the BS antenna spacing and set to half-wavelength, i.e., d B = λ 2 .Applying (33) and (36), G L i can be expressed as where ϕ BI,i and θ BI,i denote the azimuth and elevation angles of arrival (AoA) from BS i to the IRS, respectively, and ψ BI,i and φ BI,i denote the azimuth and elevation angles of departure (AoD) from BS i to the IRS, respectively.The small-scale fading of the channel from user k to the IRS is given by where ϕ UI,k and θ UI,k are the azimuth and elevation AoA from user k to the IRS.

B. GNN Setup
As illustrated in Section IV-C, BS is equipped with a GNN.We set N = 2, i.e., each GNN has 2 layers of graph convolutions.In our simulations, all the MLPs share the same network structure.In particular, the information extraction function Ψ n i in (23) and the combining function Ω n i in (25) are respectively parameterized by a 1600×800 MLP.We adopt the leaky rectified linear unit (LReLU) as the activation function [32].For input X and output Y , the LReLU function is given by The SGD is implemented by Adam optimizer with an initial learning rate of 0.01.We adopt the learning rate decay strategy.

C. Numerical Results
We present the simulation results of the proposed distributed machine learning algorithm in comparison with the following benchmark methods: • Global ZF + PA: Represent the baseline solution developed in Section III.• Global ZF: The ZF beamformer is computed centrally at the CPU using the global CSI with equal power allocation.The reflection coefficients of the IRS are configured randomly.• Local ZF: Each BS computes its ZF beamformer according to its own local CSI with equal power allocation.The reflection coefficients of the IRS are configured randomly.• Maximum ratio transmission (MRT) [3]: MRT precoding matrix at each BS is equal to its channel matrix, and thus no CSI exchange is required.Equal power allocation is adopted.The reflection coefficients of the IRS are configured randomly.All presented simulation results are averaged results over 500 independent channel realizations.
Fig. 8 shows the convergence of the proposed distributed machine learning algorithm.It is clear that the proposed algorithm can effectively learn how to improve the sum user rate.The transmit power P max and the number of IRS elements L have effects on the convergence rate.Generally, larger P max and L lead to slower convergence.Moreover, it is observed that for all the parameter settings, only 20 training epochs can achieve a satisfactory sum user rate.Fig. 9 presents the impact of different BSs determining the IRS reflection coefficients on the sum user rate."Location 1" denotes the default coordinates of the BSs.For "Location 2", we set the coordinates of BS 1-3 to (30, −30 √ 3, 10) m, (90, 0 √ 3, 10) m and (60, 60 √ 3, 10) m, respectively.We can see that determining the IRS reflection coefficients by an arbitrary BS can achieve the same sum user rate, regardless of the BS coordinates.
In Fig. 10, we show the effect of the number of antennas M on the sum user rate.First of all, we can see that the proposed distributed machine learning algorithm outperforms all the benchmark methods, which verifies its effectiveness.To be specific, without any CSI exchange, the proposed algorithm achieves a performance gain of 21.3% and 10.2% compared to the global ZF + PA method when M = 2 and M = 12, respectively.This demonstrates that the optimization of IRS reflection coefficients can significantly improve the sum user rate.The curve of local ZF starts from M = 3 due to the constraint M ≥ K.Although the beamforming vectors can be computed locally, the local ZF method suffers from a low sum user rate when M is small.Despite simple and distributed implementation, the MRT method cannot achieve a satisfactory sum user rate.
In Fig. 11, the sum user rate versus the number of IRS elements L is displayed.For all the methods considered, the sum user rate monotonically increases with L, indicating that the deployment of a larger IRS can improve the sum user rate.Specifically, the proposed distributed machine learning algorithm achieves 42.38% sum user rate gain when L increases from 36 to 144.It is worth noting that the performance gap between the proposed distributed machine learning algorithm and the benchmark methods significantly increases with L, which implies the importance of optimizing reflection coefficients at the IRS.
In Fig. 12, we present the effect of transmit power P max on the sum user rate.Notably, the proposed distributed machine learning algorithm can achieve a higher sum user rate than the benchmark methods for all the values of P max .Additionally, we observe that the global ZF + PA, global ZF and local ZF methods benefit more from from the increase of P max than other methods.When P max = 25 dBm, they can achieve a similar sum user rate as the the proposed distributed machine learning algorithm.On the other hand, they suffer from a poor  performance for a low SNR (P max ).In Fig. 13, we test the generalization capability of the proposed distributed machine learning algorithm to different numbers of users.We train the GNNs with K = 5 and apply the trained GNNs to different numbers of users during the test phase.From Fig. 13, it can be seen that the proposed algorithm has a good generalization capability to different numbers of users.The proposed algorithm outperforms the benchmark methods in terms of sum user rate, while the gap between the proposed algorithm and the benchmark methods decreases with the increasing number of users.This is because for a large number of users, the global ZF method can better eliminate inter-user interference with the global CSI.In contrast, for a large number of users, the distributed method cannot achieve the optimal performance due to the limited interference cancellation capability of a single BS.
Table I compares the sum user rate, computational time and signaling exchange with the benchmark methods, where the proposed distributed machine learning algorithm is referred to as "DML".We run the algorithms for 1000 times on the same platform, a 4 core Intel Core i7 CPU with 2.2 GHz base  frequency and 16GB memory, and record the average sum user rate in bit/s/Hz and the average computational time in milliseconds.Since the global ZF + PA method requires CVX programming, we implement it using MatLab.All other methods are written in Python 3.8.We can see that the computational time of the global ZF + PA method is significantly longer than the other methods.Note that the computational time recorded for the proposed DML algorithm is the total time of all the GNNs.In practical, the GNNs are implemented in parallel on different BSs, and the computational time per GNN is about 0.63 ms and 1.28 ms for K = 3 and K = 6, respectively.With comparable computational time, the proposed DML algorithm achieves a significantly higher sum user rate than the global ZF and local ZF methods.Moreover, the DML algorithm requires no CSI and signaling exchange for determining the transmit and reflect beamforming.The only signaling exchange is the reflection coefficients determined by the GNN that need to be transferred to the IRS.

VI. CONCLUSIONS
In this paper, we have investigated an IRS-enhanced downlink cell-free MIMO network in harsh propagation environments.Aiming to maximize the sum user rate, we have formulated an optimization problem to jointly design the transmit beamforming vectors at the BSs and the reflect beamforming vector at the IRS.We have exploited the recent advances of machine learning and proposed a novel fully distributed machine learning algorithm to solve the optimization problem.The proposed algorithm deploys a GNN at each BS and requires no CSI exchange between the BSs and the CPU.Simulation results reveal that the proposed distributed machine learning algorithm outperforms the benchmark methods in terms of sum user rate and has a low computational complexity.Compared with the conventional machine learning structures, the proposed algorithm has a better generalization capability to different numbers of users.In our future work, we will address the problem of imperfect CSI and explore the deployment of multiple IRSs.

Fig. 1 .
Fig. 1.An illustration of the IRS-enhanced downlink cell-free MIMO network.

Fig. 2 .
Fig. 2.An illustration of graph modelling of the IRS-enhanced cell-free network.
. The training phase is performed at the CPU, which has access to the global CSI  The structure of GNN i, ∀i > 1.

Fig. 4 .Fig. 5 .
Fig. 4. The proposed structure of the GNNs.Each purple node represents an update to the node feature vector.

Fig. 6 .
Fig. 6.The proposed framework of the distributed machine learning approach.
component and non-line-of-sight (NLOS) component of G i , respectively.G NL i is Rayleigh fading, which consists of uncorrelated CN (0, 1) elements.When a plane wave is impinging on the RIS from the azimuth angle ϕ ∈ [−π, π] and elevation angle

L k and f NLk
are the LOS component and NLOS component of f k , respectively.f NL k is Rayleigh fading consisting of uncorrelated CN (0, 1) elements and f L k is expressed as For every 100 training steps, the learning rate is reduced by a factor of 0.995.In each training epoch, 60000 groups of random user locations are used as training samples with a batch size of 600.That is, each training epoch has 100 training steps.We terminate the training when the number of training epochs reaches 2000 or the loss function on the verification data set does not decrease by more than 10 training epochs.

Fig. 11 .
Fig. 11.Sum user rate versus the number of IRS elements L with M = 4, K = 3 and Pmax = 15 dBm.

TABLE I COMPARISON
OF SUM USER RATE, COMPUTATIONAL TIME, AND SIGNALING EXCHANGE (M = 8, L = 100, Pmax = 15 dBm)