Research Article
DA-ActNN-YOLOV5: Hybrid YOLO v5 Model with Data Augmentation and Activation of Compression Mechanism for Potato Disease Identification
Algorithm 1
Algorithm description of ActNN compression process. The training process uses minibatch random gradient descent training.
| Input: training data: X | (1) | Convert compressible model: Replace the model module with ActNN | (2) | Initialize Data Loader: Create mini-batch data loaders based on X | (3) | Initialize Model: Load model parameters or initialize model parameters, Let W be the model parameters | (4) | for number of training iterations do | (5) | for (data, target) of mini-batch data loader do | (6) | Neural network models complete a computational process based on data | | Compress the activation (CA) value parameter according to the data in forwarding propagation | | Calculate the gradient based on the activation parameter in backpropagation decompression again (DCA) | | Calculate the gradient that satisfies (4) | (7) | Update the model parameter W based on data | (8) | end for | (9) | end for | | Output: Model and model parameters W |
|