Genetic Algorithm HPO

Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

Journal of Network and Computer Applications 221 (2024) 103784

DTL-IDS: An optimized Intrusion Detection Framework


using Deep Transfer Learning and Genetic Algorithm
Shahid Latif a , Wadii Boulila a,b,∗ , Anis Koubaa a , Zhuo Zou c , Jawad Ahmad d,∗∗

This article includes the application of the genetic algorithm in the fields of computer
networks and deep learning, it highlights the proposed framework's focus on
combining deep transfer learning and genetic algorithm techniques to achieve
optimized intrusion detection capabilities.

The methodology is divided into three key stages. First, a state-of-the-art


cybersecurity dataset is transformed into image data to facilitate CNN-based
analytics. Second one is our main study which consists of the implementation of
genetic algorithm GA to fine-tune the hyperparameters of each base learning model,
enhancing adaptability and overall performance. In the final stage, the outputs of the
top-performing models are combined using ensemble techniques, specifically the
bootstrap aggregation algorithm, to enhance the robustness of the IDS.

The goal of this GA-based HPO algorithm is to find the optimal set of
hyperparameters for training a Convolutional Neural Network (CNN )model to
achieve the best performance within the framework of GA-based Hyperparameter
Optimization (HPO). The comprehensive procedure is delineated in Algorithm 1.
Each hyperparameter is represented as a chromosome, which is a binary string. The
decimal value of the chromosome represents the value of the corresponding
hyperparameter. This allows the GA to manipulate hyperparameters using genetic
Journal of Network and Computer Applications 221 (2024) 103784

operations. An initial population of chromosomes is randomly generated. Each


chromosome represents a potential set of hyperparameters for the CNN model

. For Iteration the GA iteratively refines the population of chromosomes over multiple
generations. Each generation involves the following steps:
1. Evaluation: The fitness of each chromosome is evaluated by training a CNN
model with the corresponding hyperparameters and measuring its
performance.
2. Selection: Chromosomes with higher fitness values are more likely to be
selected for reproduction. This ensures that the next generation contains a
higher proportion of chromosomes with better hyperparameters.
3. Crossover: Selected chromosomes are paired, and their genes are combined
to create new chromosomes. This allows the GA to explore new combinations
of hyperparameters.
4. Mutation: Random changes are introduced to the genes of chromosomes. This
prevents the GA from getting stuck in local optima and helps it explore a wider
range of hyperparameter values.
5. Replacement: The new chromosomes generated through crossover and
mutation replace the old chromosomes in the population.

The iteration process stops when a maximum number of generations is reached or


when no significant improvement in fitness is observed.Output The best chromosome
found during the GA process represents the optimal set of hyperparameters for the
CNN model.

Overall, GA-based HPO is a powerful tool for optimizing hyperparameters of CNN


models. It can automate the search process, handle complex dependencies between
hyperparameters, and efficiently explore a large space of potential solutions

You might also like