| With the rapid development of the Internet,the network security has become a problem that can not be ignored in today’s society.As an important part of network security,intrusion detection technology has always been the focus of research.With the updating of the network,more and more new attacks appear.The generalization ability of traditional intrusion detection model is not high,so they can not well recognize these new attacks.A new technology is needed to improve the intrusion detection algorithm to meet the needs of society.In recent years,deep learning has shown its superiority in various fields,so this paper applies convolution deep learning to intrusion detection.Firstly,the convolution neural network is analyzed.Traditionally,the convolution neural network is trained by BP algorithm,and the BP algorithm is easily trapped in local optimum,which leads to the network can not train the optimal parameters,thus weakening the classification ability of the network.In order to overcome this shortcoming,this paper introduces grasshopper optimization algorithm,which has a strong ability of global optimization and can quickly converge.In theory,using grasshopper algorithm instead of BP algorithm for network training can enhance the classification ability of the network,but the actual experiment shows that grasshopper algorithm is sensitive to the sample size,in the case of small sample size,grasshopper algorithm performs well,but with the increase of sample size,its optimization ability will decline.Which explains the method that convolution neural network trained by grasshopper algorithm instead of BP algorithm is not entirely feasible.In order to overcome this shortcoming,this paper proposes a model of convolution neural network optimization based on grasshopper algorithm,which combines grasshopper algorithm with BP algorithm.A threshold of iteration times is set.Before the threshold,the grasshopper algorithm is used to train the network.By using the strong global searchability of the grasshopper algorithm,the better parameters can be quickly obtained.When the number of iterations reaches the threshold,the grasshopper algorithm’s searching ability decreases,and then BP algorithm is used to continue the optimization.This hybrid algorithm can be regarded as using grasshopper algorithm to obtain good initial values of network parameters,and then training convolutional neural network on this basis.Appropriate initial value,combined with strong local search ability of BP algorithm,can greatly improve the classification ability of the network.In this paper,three data sets are used to validate the intrusion detection model based on convolutional neural networks optimized by grasshopper algorithm.The experimental results show that,compared with the CNN model before optimization,the detection rate of this model is increased by 2.33% and the false alarm rate is reduced by 0.71%.Compared with the KNN model,the detection rate is increased by 4.14% and the false alarm rate is reduced by 0.02%.Compared with the SVM model,the detection rate is increased by 2.31%,the false alarm rate is reduced by 0.9% and the false alarm rate is reduced by 0.67%.These data show that convolutional neural networks optimized by grasshopper algorithm is an efficient and feasible algorithm,which improves the performance of intrusion detection algorithm. |