| Algorithm 1: Our Modified Residual-Dense CNN Network Architecture | |
| Step 1: | Input: Training dataset, X; Corresponding labels, Y; Number of residual blocks, num_res_blocks Number of dense blocks, num_dense_blocks; Number of layers within each residual block, num_res_layers; Number of layers within each dense block, num_dense_layers |
| Step 2: | Output: Trained Residual-Dense Network model |
| Step 3: | [Initialization]: a. Define the input layer: Input layer: , shape determined by dataset b. Add an initial convolutional layer: Initial Convolutional Layer: c. Add residual-dense blocks: Initialize |
| Step 4: | [Define Inner Residual Block]: Repeat For k = 1 to num_res_blocks do: a. Initialize a new Block: Block input: b. Repeat For I = 1 to num_res_layers do Convolutional layer: Convolutional Layer: Batch normalization: Activation: c. Residual connection: Residual output: d. Update |
| Step 5: | [Define the Dense Block]: Repeat For k =1 to num_dense_blocks do: a. Initialize a new Block: Block input: b. Repeat For I= 1 to num_dense_layers do Convolutional layer: Convolutional Layer: Batch normalization: Activation: c. Concatenate with block input: output: d. Update |
| Step 6: | Global Average Pooling and Fully Connected Layers: Global average pooling: ) Flatten layer: Fully-connected layers: ) |
| Step 7: | [Return Trained Residual-Dense Network model] |