| Algorithm 1: Training process of ATT-MRCNN for the |
| Input: The collected orange picture data, selected COCO and VOC |
| Initialization. |
| Define the ATT-MRCNN. |
| Weights initialization using the COCO datasets with transfer learning manner. |
| Feature extraction. |
| Channel attention and Spatial attention mechanism for the feature map. |
| Model training: Epochs initialization. |
| while epoch<preset epoch do |
| Sample data from Input. |
| Feed data to the ATT-MRCNN. |
| Model updates. |
| End |
| Parameters Fine tuning |
| while epoch<preset epoch do |
| Validation dataset input. |
| Loss calculation. |
| Compute precision, recall and F1-score |
| Save the optimal model |
| end |
| Output: Trained ATT-MRCNN network |