Reconstruction and Optimization of Complex Network Community Structure under Deep Learning and Quantum Ant Colony Optimization Algorithm

Community structure is a key component in complex network systems. This paper aims to improve the effectiveness of community detection and community discovery in complex network systems by providing directions for the reconstruction and optimization of community structures to expand the application of intelligent optimization algorithms in community structures. First, deep learning algorithms and ant colony algorithms are used to elaborate the community detection and community discovery in complex networks. Next, we introduce the technology of transfer learning and propose an algorithm of deep self-encoder modeling based on transfer learning (DSEM-TL). The DSEM-TL algorithm’s indicators include normalized mutual information and modularity. Finally, an algorithm that combines the ant colony optimization (ACO) algorithm and the quantum update strategy, called QACO, is proposed. The proposed community structure reconstruction scheme is compared with other methods using the accuracy rate as the indicator. The results show that the DSEM-TL algorithm exhibits the optimal detection rate, better applicability, and higher effectiveness in real networks. Under the given the condition that the number of edges between communities Zout is >6, DSEM-TL shows better performance on the Girvan–Newman benchmark network than several other community discovery algorithms. Furthermore, under the given condition that the mixed parameter μ is >0.65, the DSEMTL algorithm outperforms several other algorithms on the Lancichinetti–Fortunato–Radicchi benchmark network. When given μ < 0.4, the QACO algorithm can determine the proper division of the corresponding network. When the case is μ > 0.45, the division result corresponding to the QACO algorithm is closer to the real community division, which has a faster convergence speed and better convergence performances. Consequently, the proposed community structure reconstruction scheme has higher accuracy. The proposed two intelligent optimization algorithms have potential application in the reconstruction and optimization of community structure.


Introduction
As a branch of network science, the complex network can be regarded as a collection formed by some individuals, which shows the interconnection between individuals [1,2]. Most research on complex networks consists of structure, models, dynamics, structure mining prediction, and control [3]. In additional, network reconstruction belongs to the category of dynamics [4], which predict a network's topological structure by mining the missing information in the network [5,6]. Various scholars have conducted research on community structure because of its critical role in complex networks [7][8][9][10]. Jia et al. [11] proposed a k nearest neighborhoods (k-NN) graph with increased node attributes to mitigate the sparsity and noise effects of the original network. K-NN enhances the community structure in complex networks and is expected to be widely applied in large-scale network analysis. Guendouz et al. [12] proposed a discrete improved firework algorithm (FWA) for community detection in complex networks based on the label propagation strategy. They believed that the new algorithm had sound effects. Zou et al. [13] proposed an optimized multi-objective discrete backtracking search algorithm (MODBSA/D) and decomposed it into community detection in complex networks. Afterward, they proved that the algorithm performs well in the community detection of complex networks. Li et al. [14] combined orthogonal triangulation decomposition with compressed sensing and proposed a method to solve the reconstruction problem of complex networks using input noise. This research method reconstructed sparse complex networks and was useful in the reconstruction of dense and complex networks. Ma et al. [15] proposed an approach based on statistical reasoning to solve the problem of reconstructing complex network structures in observed binary data. The application of the expectation-maximization (EM) algorithm provided a new supplement for the rapidly expanding reconstruction problems of complex network systems. Based on the issue of binary state dynamics in the reconstruction of complex network systems, Li et al. [16] developed a data-based linearization method, which provided a framework for the reconstruction of complex networks using binary state dynamics. Fu et al. [17] proposed a new node degree variance ratio method for distinguishing a leading community from a self-organizing community in a complex network system. This method achieved robustness on a real network. In summary, while research results about the reconstruction and optimization of community structures in complex network systems vary, the methods of integrating quantum mechanisms into them are rarely reported. Therefore, to explore the reconstruction and optimization of the community structure in the complex network systems, the optimized deep learning algorithm and quantum ant colony optimization (QACO) algorithm are applied to community detection and community discovery. The algorithms aim to improve the effectiveness of community detection, discovery, and mining. Hopefully, the results can provide some references for the reconstruction and optimization of community structure.

Complex Network Community Detection and Discovery
Community detection is a critical characteristic of complex networks. The analysis and mining of community structures in complex networks are of great significance for discovering the inherent development rules of complex networks and the correlation of relevant indicators within these networks [18,19]. Nodes belonging to the same community have a higher degree of similarity in the representation of related features. Community discovery of complex networks is an effective way to classify these nodes in complex networks. In the study of complex networks, the exploration of community structure not only discovers the unknown laws or phenomena but also leads to an understanding of the relationship between the structures and corresponding functions. Complex networks, such as transportation systems, power grid systems, and the World Wide Web are in inextricably linked to the daily lives of people. However, finding and mining useful information inside the network is a challenge. We need to learn how to retrieve information from the massive amounts of big data in the study of complex networks.
In the real network structure, the community structure is widespread. From the perspective of network nodes, it can be divided into a collection of many nodes. If there is a close connection within the network node collection, and this connection between them also shows a relatively loose state, it will be determined that the corresponding complex network has a community structure. The accurate identification of community structure has developed into a crucial stage of obtaining sufficient information [20,21]. The topological structure of a complex network can be expressed as: where: G represents the topology of the complex network, V represents the set v 1 ; v 2 ; Á Á Á ; v n f gcorresponding to the points including n nodes, and E represents the set of edges corresponding to two random nodes in V .

Community Discovery Optimization Algorithm Based on Deep Learning
Because deep learning algorithms have excellent performance in feature extraction, deep learning has been successfully applied in the fields of image classification and semantic recognition [22,23]. Fig. 1 below illustrates a hidden learning network structure composed of three hidden layers. The technologies of self-encoders, deep belief networks, and convolutional neural networks are widely utilized in deep learning. Self-encoders are built for deep structures through stacking and layerwise training. The encoder can also fine-tune the input signal in the entire network [24]. Therefore, combined with transfer learning, self-encoders are applied to community discovery for complex network community structures.
The proposed deep self-encoder modeling based on transfer learning (DSEM-TL) consists of the data preprocessing module, the feature extraction module, and the optimization module. The data preprocessing module is primarily responsible for the preprocessing of the original adjacency matrix in the complex network. Based on the topology of the complex network, the community discovery problem is to divide complex network systems into nodes as different groups or communities. The problem can be expressed as:

Input layer
Hidden layer Output layer Figure 1: Structural composition of the deep learning network where: D 1 represents the converted adjacency matrix, DG : ð Þ represents the function diag : ð Þ among Matlab, which can realize the construction of the diagonal matrix, and d 1 represents the degree of the network node. The realization of the entire matrix conversion process is completed by vector operation. Thus, we need to construct the matrix A 1 and A 2 . The corresponding expression is Then, based on the eigenvalue function, the maximum eigenvalue U 1 corresponding to A 2 is calculated. The corresponding calculation is where: Eig : ð Þ represents the eigs : ð Þ function in Matlab, k ¼ C, and C represents the size of the community in a complex network. Finally, the transformed similarity matrix can be obtained, where: d 2 represents the row sum corresponding to the matrix U 2 1 , and M corresponds to the input matrix of the self-encoder.
In the feature extraction module, transfer learning is introduced to build a target prediction model with excellent generalization performance. The algorithm is trained by a parameter-based migration method. Specifically, the overall loss function is defined À Á þ b h ð Þ represents the KL divergence that the embedding instance has between two different domains, and J represents the overall loss function.
In the optimization module, through the application of the backpropagation algorithm based on the stochastic gradient descent method, the minimization problem in the overall loss function is solved. The update of the weight and the update of the offset term parameters are then realized by the following rules where: W 1 , W 2 , f W 1 , and f W 2 represent weights, p 1 , p 2 , q 1 , and q 2 represent bias term parameters, and r represents the learning rate. The implementation process of the DSEM-TL algorithm is shown in Fig. 2.
To test the effectiveness of the proposed DSEM-TL algorithm, the learning rate corresponding to the deep self-encoder is set to 0.01, and the number of training iterations is set to 100,000. Furthermore, by comparing and analyzing the widely used community discovery solutions in the Girvan-Newman (GN) and the Lancichinetti-Fortunato-Radicchi (LFR) benchmark network, we test the effectiveness of the DSEM-TL algorithm in structural reconstruction and optimization in the complex network community. The selected commonly used community discovery schemes the subspace pursuit (SP) algorithm [25], unified link and content (ULC) [26], fast Fourier transform (FFT) Accumulation Method (FAM) [27], fast unfolding algorithm (FUA) [28], and deep nonlinear reconstruction algorithm based on cross-entropy (DNR-CE) [29]. SP is a method for detecting community structure by spectral analysis using Laplace or modularity matrix. ULC is a heuristic search algorithm based on modularity optimization problemsolving. FAM is a greedy clustering algorithm. FUA is a community discovery method based on modularity. DNR-CE achieves community discovery based on the nonlinear reconstruction of deep neural networks. The evaluation datasets and phase information composition are shown in Tab. 1. The evaluation datasets, which can gauge the effectiveness of the algorithm in real networks, are Karate, which represents the karate club network; Friendship 6, which represents the campus relationship network; Polbooks, which represents the Books about US politics; Citeseer, which represents a citation network of computer science publications; Cora, which represents a dataset of citation types; and Football, which represents a network of U.S. football teams. These six datasets are all widely used network datasets in community discovery research. The normalized mutual information (NMI) and modularity (Q) are chosen as the evaluation indicators. In this field, modularity is expressed as "Q" [30,31].

Quantum ACO Algorithm Based on Community Detection
The ant colony optimization (ACO) algorithm is an intelligent optimization heuristic algorithm. It has strong robustness and well-integrated with other algorithms. It has strong applicability in solving discrete optimization and complex network community detection problems, and is more applicable in the network structure for small-scale datasets [32,33]. Therefore, for large-scale datasets, the ACO algorithm is  Figure 2: Implementation process of DSEM-TL algorithm combined with the quantum update strategy to form the proposed QACO algorithm, which we then apply to the community detection of complex networks.
For the ACO algorithm, when the ants move from the starting node to a viable neighbor node, the generation of the solution can be expressed as where: s ij and g ij represent the corresponding pheromone and heuristic information between node i and node j, a and b correspond to the parameters that regulate the ratio between s ij and g ij , q represents a uniformly distributed random number, q 0 describes the preset parameters, and S corresponds to a selection variable of the probability distribution. In the case of q > q 0 , the artificial ant selects the next node according to the transition probability p ij , where the transition probability p ij can be expressed as In Eq. (14), the meaning of each symbol is the same as in that of Eq. (13) above.
As for quantum computing, the state of qubits can be expressed as where: a and b represent the probability amplitude in the corresponding state. Furthermore, in the QACO algorithm, the pheromone can be expressed as The update of pheromone can be expressed as where 4h i ð Þ represents the rotation angle.
A specific number of ants are randomly assigned among the complex network nodes using the QACO algorithm. The ants move from one node to another according to the heuristic information and the strength of the pheromone. Then, small groups appear in the population. We will integrate the small groups into the community according to the maximization of modularity and community division to realize the determination of the community structure in the complex network. In this process, the rotation and mutation mechanism based on quantum computing enhance the global search capability and solution diversity of the algorithm. Once the optimal solution or the maximum number of iterations appears, the entire optimization process terminates accordingly. The specific implementation process of the QACO algorithm is shown in Fig. 3.
During the implementation of the QACO algorithm, the pheromone in the initialization phase can be expressed as The heuristic information calculation between nodes can be expressed as where: C i; j ð Þ represents the Pearson correlation matrix. It can be defined as where: n represents the number of nodes, A ik represents the k-th element corresponding to row i in the adjacency matrix A, k represents the average value corresponding to node i, and r i represents the value of standard deviation corresponding to the node A jk . A jk , l j , and r j may be deduced by analogy.
Furthermore, it is possible to update the pheromone intensity by using quantum rotation gates. The new pheromone intensity obtained at this time can be expressed as where: 4h i represents the quantum rotation angle corresponding to each qubit.
The extended GN benchmark network is used to verify the effectiveness of the QACO algorithm. At the same time, the QACO algorithm is compared with the interest factor-based ACO algorithm (IACO), the multi-objective discrete particle swarm optimization (MODPSO) community detection algorithm, the quantum distribution algorithm (QDM), the quantum genetic algorithm (QGA), and the locally optimized community detection algorithm (MABA) based on minimum spanning tree. In this way, we analyze the performance of the QACO algorithm in the detection of complex network community with NMI and Q selected as evaluation indicators.
All the nodes are treated as having integrity in the complex network community structure. We introduce the concept of game theory to excavate the implicit constraint conditions. The results are achieved through the DSEM-TL and QACO algorithms. The advantages of the deep self-encoder based on the DSEM-TL and QACO algorithms are organically integrated so that the accuracy of community detection in the community Analysis of the NMI corresponding to different community discovery schemes in Fig. 4(a) shows that the detection rate corresponding to DSEM-TL is superior to that of the DNR-CE method, as well as several other complex network community discovery schemes. The analysis concludes that the DSEM-TL algorithm has better applicability and more effectiveness in real networks. Analysis of the modularity measures corresponding to different community discovery schemes in Fig. 4(b) shows that while the clustering effect of the DSEM-TL and DNR-CE algorithms is almost the same. Meanwhile, the DNR-CE algorithm shows a better clustering effect than several other algorithms.
The performance comparison of the six complex network community discovery solutions on the GN and LFR benchmark network is shown in Figs. 5a and 5b. In the above figure, Z out represents the number of edges between each vertex community.
As shown in Fig. 5, when Z out is greater than 6, DSEM-ML shows better performance on the GN benchmark network than other community discovery methods. Similarly, when the mixed parameter μ is greater than 0.65, the performance of DSEM-TL is superior to several other algorithms on the LRF benchmark network. This further validates the effectiveness of the DSEM-ML algorithm in complex network community discovery and community detection.
The above analysis reveals that the proposed DSEM-TL algorithm has the best performance. The reason is that the new method used for matrix preprocessing in the model construction process of DSEM-TL actually highlights the local information of the vertex. n additional, the DSEM-TL algorithm employs transfer learning to obtain low-dimensional feature matrices. Therefore, DSEM-TL has useful community discovery and community detection performances in complex networks. Furthermore, the DSEM-TL algorithm model based on deep learning has applicability in the artificial benchmark network. Accordingly, it is predicted that this complex network community discovery and community detection method based on deep learning has vast application potential in the reconstruction and optimization of community structure.

Performance of Community Detection QACO Algorithm
The NMI comparison results of the QACO algorithm with IACO, MODPSO, QDM, QGA, and MABA algorithms are shown in Fig. 6a. The modularity measures comparison results of the QACO algorithm with these five algorithms, are shown in Fig. 6b.
We compare the results of the NMI and modularity measures of several algorithms, as shown in Fig. 6. When the mixed parameter μ is smaller than 0.4, the QACO and QDM-PSO algorithms can determine the real division of the corresponding networks. At this point, the corresponding NMI value is 1. When the mixed parameter μ is not greater than 0.25, the situation is reversed. The other algorithms can determine the correct community structure of complex networks. When the mixed parameter μ is higher than 0.45, none of the algorithms can determine the real community division of the network. However, the division result corresponding to the QACO algorithm is more inclined to the actual community division. From the perspective of the changes in the modularity measures of each algorithm, the QACO algorithm has a faster convergence speed than the QGA algorithm, but the QDM-PSO and MODPSO algorithms have faster convergence speeds in the initial stage. Overall, the convergence of the QACO algorithm is better and faster.
The comparison between the proposed optimization scheme of complex network community structure and several community reconstruction methods is shown in Fig. 7.
As shown in Fig. 7, the complex network community reconstruction scheme incorporating two optimization algorithms has the highest accuracy rate. Therefore, the DSEM-TL method and the QACO algorithm have promoted the reconstruction and optimization of the complex network community structure.
The QACO algorithm can improve the accuracy of the GN benchmark network community division. The integration of quantum mechanisms gives the network a faster convergence speed, which leads to superior performance in complex network community testing. The introduction of quantum strategy has expanded the application of the ACO algorithm in solving community detection problems. The QACO algorithm is more applicable to the detection of complex network community structure than other algorithms, and therefore can play an active role in the reconstruction and optimization of complex network community structure. Notably, the proposed community structure reconstruction scheme has a high accuracy rate.

Conclusion
This article proposes the DSEM-TL algorithm model, which introduces transfer learning into deep selfencoders, and the QACO algorithm, which integrates the quantum strategy into the ACO algorithm. The results show that the two algorithms have significant advantages in the application of community discovery and community detection in complex network community structures. The combination of the two optimization algorithms shows the best accuracy in the reconstruction of the complex network community structure. However, the optimization of the complex network community structure still stays in the exploration stage. At this time, the coverage of the selected real network dataset is limited, and there has not been sufficient consideration of the characteristics of the complex network structure. Resolving these issues, which are due to several factors, is a focus of future research.