Deep Learning-Based Detection of Cannibalism and Competition Behaviour in Asian Corn Borer, Ostrinia furnacalis Larvae
Funding: This work was supported by the National Key Research and Development Program of China, 2023YFD1501103. The Jilin Provincial Department of Science and Technology of China, 20220203198SF. Ministry of Science and Technology of the People's Republic of China, 2022YFD1500701. The Ministry of Agriculture of the People's Republic of China, 15226025.
ABSTRACT
As Ostrinia furnacalis, a notorious pest, navigates the intricate ecology of its habitat, a profound comprehension of cannibalism and competitive behaviour stands as a cornerstone for the implementation of effective pest management strategies. To address this gap, we used a novel deep learning approach based on a convolutional neural network (CNN) to assess larval competition under controlled laboratory conditions. Our study categorised O. furnacalis larval behaviours into 10 distinct types and observed significant differences in their frequency. The CNN model achieved high precision (0.958), recall (0.959) and [email protected] score (0.972) for real-time monitoring of larval activity. During intraspecific competition without food, both the frequency and duration of interactions increased significantly. In particular, the duration of biting the head was longer during the 4th instar. Third instar larvae exhibited a higher cannibalism rate (40%). Pupation rates were highest (80%–90%) in the absence of competition, producing heavier pupae associated with kernel feeding. This study enhances our understanding of intraspecific competition and its effects on larval survival in O. furnacalis. It also promotes the use of artificial intelligence-based approaches in exploring and managing economically important insect species.
1 Introduction
The Asian corn borer, Ostrinia furnacalis (Guenée) (Lepidoptera: Crambidae), is a highly destructive pest to maize, widely distributed across Asia, including China, the Philippines, Korea and Japan (Afidchao et al. 2013; Nafus and Schreiner 1991). Its larvae are voracious consumers, feeding on various parts of maize plants, such as leaves and silk and burrowing into stalks, leading to stalk breakage (Yuan et al. 2013; Zhao et al. 2022). This pest inflicts substantial economic losses by reducing maize yield and increasing the incidence of spike rot diseases (Wang and Wang 2019). Importantly, cannibalism among O. furnacalis larvae has been recognised as a prevalent behaviour, potentially influencing both larval development and the extent of subsequent harm (Ongaratto et al. 2021; Zhao et al. 2022).
Cannibalism, a widespread behavioural trait in the animal kingdom, plays a pivotal role in maintaining population dynamics (Fox 1975; Polis 1981; Valentina et al. 2018). Among Lepidopteran larvae, including O. furnacalis, cannibalistic behaviour has been documented (Shi et al. 2021). Intraspecific competition, shaped by factors such as cannibalism, food availability and spatial constraints, significantly influences pest behaviour and development (Klomp 1964). Importantly, O. furnacalis larvae exhibit competitive behaviours in both intraspecific and interspecific contexts (Shi et al. 2021; Zhao et al. 2022). Understanding these intricate interactions is pivotal for unravelling the complexities of pest dynamics, informing effective pest management strategies, and providing valuable insights for agricultural sustainability.
In light of the challenges posed by O. furnacalis, particularly its destructive feeding habits and cannibalistic tendencies, the need for effective and accurate detection methods is essential. Traditional approaches to studying such behaviours often rely on manual observation, which can be time-consuming, subjective and impractical for large-scale studies. Recognising these limitations, we propose a novel deep-learning-based technique for the automated detection of cannibalism and competitive behaviour in O. furnacalis larvae. Deep learning, a rapidly advancing technology, has demonstrated its efficacy in agriculture by handling extensive datasets and extracting meaningful insights (Shi et al. 2021; Zhao et al. 2022).
Although deep learning has been applied to study insect behaviours such as foraging in Apis mellifera, grooming in Bactrocera minax adults and pose detection in Ceratitis capitata and Acheta domesticus (Fang et al. 2020; Fazzari et al. 2023; Kamilaris and Prenafeta-Boldu 2018; Liu et al. 2020; Manduca et al. 2023; Tsai et al. 2020; Yang et al. 2021; Zhu et al. 2018), its application to lepidopteran behaviour remains relatively limited. Addressing this gap, our study employs a deep-learning-based approach to analyse larval behaviour, bridging the divide between manual observation and precise behaviour classification (Tannous et al. 2023).
Considering the significance of maize, understanding pest behaviour is essential for effective crop protection. Recent research has increasingly focused on the complex ecological interactions between agricultural pests and crops. This study investigates the behavioural dynamics of O. furnacalis larvae in response to non-Bt maize tissues. We applied deep learning techniques to examine intraspecific larval competition among O. furnacalis when feeding on various maize tissues (leaf, silk and kernel). Additionally, we explored the effects of larval competition on cannibalistic behaviour and development. This research contributes to sustainable pest management through artificial intelligence (AI)-driven technological innovations, offering new insights into pest-plant interactions and their ecological implications.
2 Materials and Methods
2.1 Insects and Plants
Maize tissue (non-Bt maize (variety UDI 871) leaves, silks and kernels) and O. furnacalis larvae (3rd and 4th instar) were obtained from the Conservation Tillage Pest and Disease Monitoring Laboratory of Jilin Agricultural University. Larvae were reared on an improved artificial diet consisting of brewer's yeast powder (50.0 g), wheat germ flour (150.0 g), nipagin (4.0 g), sorbic acid (4.0 g), agar (14.0 g), sucrose (15.0 g), vitamin C (4.0 g) and water (700.0 mL) (Zhou et al. 1980). Rearing was carried out in plastic boxes (320 mm × 220 mm × 100 mm) at temperatures ranging from 10°C ± 2°C to 30°C ± 2°C and relative humidity from 40% ± 10% to 70% ± 10%, with a photoperiod of 14 L:10 D.
2.2 Category and Observation of Behaviour
Observations involved 40 pairs of larvae (40 3rd instar larvae and 40 4th instar larvae) placed in separate Petri dishes (60 mm diameter, 15 mm height). Half the larvae were starved for 4 h, while the rest were provided ample food (maize leaves). Each pair of larvae was manually observed for 10 min, and behavioural frequencies were recorded using random, sequential, instantaneous and scan sampling methods (Altmann 1974).
2.3 Data Acquisition, Deep Learning Model, Training and Performance Assessment
2.3.1 Data Acquisition
2.3.1.1 Data-Acquisition Setup
The data-acquisition device was specifically designed and consisted of a camera (Canon EOS 650D, resolution 1920 × 1080, 30 FPS, Canon, Japan), a lens (Canon EF-S 18–55 mm 1:3.5–5.6 IS, Canon, Japan), Petri dishes and a bracket (300 mm × 300 mm × 300 mm) (Figure 1). The camera was positioned 100 mm above the larvae, recording videos from a top-down perspective under natural daylight without additional illumination. Videos were recorded in MOV format with automatic exposure and white balance settings. A total of 228 videos, ranging from 15 s to 10 min, were recorded and later used for training the CNN model. The time at which the larval behaviour occurred in each video was manually observed and recorded. After the videos were automatically split into frames and processed, the relevant segments for each behaviour were extracted every 10 frames to create the dataset. Manual annotation was performed using the open-source image annotation tool labelImg (version 1.8.2). A total of 2750 images were obtained, covering 4 distinct behaviours: Biting body, Biting head, Grooming and Waving up (Figure 2). The category counts for the four behaviours were 672, 778, 822 and 540, respectively. The dataset was divided into training, validation and test sets in a 70:15:15 ratio, with no data overlap.


2.3.1.2 Data Pre-Processing
To improve the generalisation ability of the model with limited data conditions, data augmentation methods were incorporated during the training process to enrich the dataset of larval behaviours and background information. Key techniques included horizontal flip, translation and Mosaic augmentation. Mosaic augmentation involves randomly selecting four images from the training set. Each image undergoes random flipping, scaling and colour gamut adjustment before being combined into a single composite image (Bochkovskiy et al. 2020). A comparison between the original and augmented images (Figure 3) demonstrated the superior effectiveness of the Mosaic-enhanced approach. This technique augments the datasets for training deep learning models, improving detection and classification accuracy across varied scenarios. It offers a greater variety of scenes and behaviours than the original images.

2.3.2 Deep Learning Model and Training
2.3.2.1 Model Description
In this study, a YOLOv7 model was used. This CNN model is known for its high recognition accuracy and fast inference speed (Wang et al. 2022), making it suitable for real-time and precise larval behaviour recognition.
As shown in Figure 4, the YOLOv7 architecture comprises three components: Backbone, Neck and Head. The Backbone is responsible for feature extraction, the Neck for feature fusion and the Head for object prediction.

2.3.2.2 Model Training
The hardware specifications used were NVIDIA GeForce RTX 3060 with 12GB of memory. The system utilised CUDA 11.7.101, Python 3.8 and PyTorch 1.12.1. Training was conducted with a batch size of 16 for 100 epochs. The initial and maximum learning rates were set to 0.001 and 0.1, respectively, with a momentum factor of 0.937 and weight decay of 0.0005.
2.3.3 Performance Assessment
2.4 Trained-Model-Based Detection of Larval Behaviour When Feeding on Different Maize Tissues
In all subsequent experiments, two larvae (each starved for 4 h before the experiment) were randomly selected and placed on the opposite sides of each Petri dish. Each replicate lasted 15 min, and 5 replicates were conducted for each scenario. Each larva was used only once.
The frequency and duration of larval behaviour were assessed by trained YOLOv7 under three feeding conditions: maize leaf, silk, or kernel. Three combinations were set (3rd instar vs. 3rd instar, ; 3rd instar vs. 4th instar, ; 4th instar vs. 4th instar, ).
2.5 Effects of Larval Competition on Cannibalism and Development
Larvae from the aforementioned treatments were paired and kept in Petri dishes. Cannibalism was observed for 24 h following the competition period. Larvae were individually placed in Petri dishes, and the type of diet provided remained the same as in the competition phase until pupation. Two days after pupation, the weights of pupae were individually measured using an electronic balance (BSA224S; Sartorius, Germany).
2.6 Statistical Analysis
The trained YOLOv7 model was used to detect the larval behaviour of O. furnacalis. Preliminary observations revealed that competitive behaviour lasted for at least 0.3 s, while Grooming and Waving up lasted for a minimum of 0.5 s. Therefore, only behaviours that persisted for more than 8 or 14 frames, respectively, were recorded by the model. Statistical analyses were performed using Origin 2023b. First, normality and homoscedasticity of the data were analysed using the Shapiro–Wilk test and Levene's test, respectively. In cases where these assumptions were not met, a square root transformation was applied. If this transformation did not satisfy the conditions, a Kruskal-Wallis test was utilised. Behavioural frequency and duration, pupation rate, pupal weight and pupal period were subjected to ANOVA and Fisher's LSD test ().
3 Results
3.1 Behaviour Category and Observation
The behaviours of O. furnacalis larvae were classified into 10 types, further grouped into three main categories (Table 1). However, for data acquisition, only images depicting four frequently observed behaviours were included in the dataset. There was a significant difference in the frequencies of 10 behaviours (Table 2) (, ). Notably, Waving up, Biting body and Biting head occurred more frequently, followed by Tasting and Grooming. In contrast, behaviours like Recoiling, Feeding, Defecating, Rolling and Silking were less frequent.
Behaviour type | Definition | |
---|---|---|
Main behaviour | Behaviour name | |
Common behaviour | Defecating | The body is stationary except for the tail; cylindrical faeces came out after the tail was cocked |
Grooming | Groom body by mouthpart | |
Waving up | The larva moves its head and thorax from side to side with the head up in the air | |
Recoiling | The larva moves from front to back in a wavy shape | |
Rolling | A lateral flipping of the entire body | |
Silking | Making a silk capsule/boll around its body before going to pupal stage | |
Feeding behaviour | Feeding | Ingestion of food |
Tasting | Head lowered to the plant surface, which it contacts briefly | |
Competition behaviour | Biting body | A bite or jab with the body, directed towards the opponent, which contacts the opponent |
Biting head | A bite or jab with the head, directed towards the opponent, which contacts the opponent |
Behaviour | 3rd larvae | 4th larvae | Average | ||||||
---|---|---|---|---|---|---|---|---|---|
Starvea | N-starveb | Starve | N-starve | ||||||
W-foodc | Foodd | W-food | Food | W-food | Food | W-food | Food | ||
Defecating | 0.00% | 4.00% | 0.00% | 5.88% | 6.67% | 1.52% | 0.00% | 7.69% | 2.48% bc |
Grooming | 3.23% | 12.00% | 0.00% | 0.00% | 13.33% | 7.58% | 0.69% | 7.69% | 6.20% b |
Waving up | 32.26% | 36.00% | 26.09% | 47.06% | 0.00% | 24.24% | 2.08% | 30.77% | 26.03% a |
Recoiling | 3.23% | 0.00% | 0.00% | 5.88% | 0.00% | 0.00% | 0.35% | 0.00% | 1.24% c |
Rolling | 12.90% | 0.00% | 0.00% | 0.00% | 0.00% | 0.00% | 0.00% | 0.00% | 1.65% c |
Silking | 0.00% | 0.00% | 0.00% | 0.00% | 0.00% | 1.52% | 0.00% | 0.00% | 0.41% c |
Feeding | -e | — | — | — | 13.33% | 1.52% | 0.00% | 0.00% | 2.48% bc |
Tasting | — | — | — | — | 20.00% | 12.12% | 1.04% | 19.23% | 15.70% a |
Biting body | 16.13% | 24.00% | 60.87% | 23.53% | 40.00% | 25.76% | 0.69% | 15.38% | 23.97% a |
Biting head | 32.26% | 24.00% | 13.04% | 17.65% | 6.67% | 25.76% | 1.04% | 19.23% | 19.83% a |
- a Ostrinia furnacalis larvae were starved for 4 h before starting the experiment.
- b Ostrinia furnacalis larvae were provided enough food for 4 h before starting the experiment.
- c The Ostrinia furnacalis larval behaviour observation experiment was conducted without food.
- d The Ostrinia furnacalis larval behaviour observation experiment was conducted with maize leaf.
- e No data obtained.
3.2 Model Training and Performance Assessment
The training curves, including loss, precision, recall and [email protected], showed gradual stabilisation as the number of epochs increased (Figure 5). Training loss converged at 0.031, indicating model stability. Precision, recall and [email protected] reached 0.958, 0.959 and 0.972, respectively, confirming the effectiveness of the model training (Figure 5b–d). The model performance on the independent test set (Table 3) demonstrates its capability to meet real-time monitoring requirements for larval behaviour analysis. Behaviour detection results for four larval activities are displayed in Figure 6.

Behaviour | Precision | Recall | F1-Score | [email protected] |
---|---|---|---|---|
Biting body | 0.955 | 0.968 | 0.961 | 0.978 |
Biting head | 0.989 | 0.921 | 0.954 | 0.976 |
Grooming | 0.969 | 1.000 | 0.984 | 0.995 |
Waving up | 0.980 | 0.956 | 0.968 | 0.963 |

3.3 Automatic Detection of Larval Behaviour When Feeding on Different Maize Tissues
O. furnacalis exhibited varying degrees of competition under different dietary conditions (Figure 7). Among all treatments, the most intense competition was observed without food. Among the same larval instar combinations ( and ), there was a significant difference in both the frequency and duration of competitive behaviour.

For combination, the highest frequency (14.60 ± 3.85) and longest duration (19.90 ± 4.57 s) of competitive behaviour were observed in the absence of food, followed by leaf (10.40 ± 3.37), and kernel (4.00 ± 2.26). The frequency and duration with silk (1.40 ± 1.40, 2.79 ± 2.79 s) were significantly lower than those with leaf and without food (, ; , ).
For combination, the frequency of larval competitive behaviour was the highest without food (20.80 ± 3.67), significantly higher than other treatments (, ). In contrast, the duration under the leaf condition (6.73 ± 2.86 s) was significantly shorter compared to other diets (, ).
For combination, the frequency of larval competitive behaviour was the highest without food (9.40 ± 3.20), followed by kernel (4.80 ± 2.40), silk (4.60 ± 2.93), and leaf (3.80 ± 1.80). There was no significant difference in the duration of competitive behaviour among the different dietary conditions (, ).
For the frequency of four behaviours, there was a significant difference without food () (Table 4). The frequencies of Biting body and Biting head were significantly higher than those of Grooming and Waving up (, ).
Combination | Behaviour | Leaf | Silk | Kernel | CK (without food) |
---|---|---|---|---|---|
Biting body | 6.40 ± 2.06a | 0.00 ± 0.00a | 1.40 ± 1.40a | 8.60 ± 3.85a | |
Biting head | 4.00 ± 1.45a | 1.40 ± 1.40a | 2.60 ± 1.69a | 6.00 ± 1.70a | |
Grooming | 0.00 ± 0.00a | 0.00 ± 0.00a | 0.60 ± 0.40a | 1.40 ± 0.87a | |
Waving up | 1.80 ± 1.80a | 0.00 ± 0.00a | 0.20 ± 0.02a | 8.40 ± 3.08a | |
Biting body | 1.00 ± 0.77a | 1.60 ± 0.98a | 2.40 ± 1.17a | 3.80 ± 1.91a | |
Biting head | 2.80 ± 1.32a | 3.00 ± 2.00a | 2.40 ± 1.50a | 5.60 ± 1.78a | |
Grooming | 0.00 ± 0.00a | 0.00 ± 0.00a | 0.00 ± 0.00a | 2.20 ± 1.11a | |
Waving up | 0.60 ± 0.40a | 0.00 ± 0.00a | 0.00 ± 0.00a | 0.40 ± 0.40a | |
Biting body | 5.20 ± 2.58a | 1.00 ± 0.63a | 3.40 ± 1.83a | 9.40 ± 2.69a | |
Biting head | 2.40 ± 1.03a | 2.60 ± 0.93a | 4.60 ± 1.83a | 11.40 ± 3.85a | |
Grooming | 0.80 ± 0.49a | 0.60 ± 0.60a | 0.60 ± 0.60a | 1.40 ± 1.17b | |
Waving up | 2.60 ± 1.47a | 0.00 ± 0.00a | 0.60 ± 0.24a | 1.60 ± 0.68b |
For the duration of four behaviours, a significant difference was observed in (Table 5). Biting head duration was significantly higher than Biting body under both silk and kernel conditions () (, ; , ).
Combination | Behaviour | Leaf | Silk | Kernel | CK (without food) |
---|---|---|---|---|---|
Biting body | 8.16 ± 4.02a | 0.00 ± 0.00a | 1.15 ± 1.15a | 8.29 ± 2.97a | |
Biting head | 5.45 ± 2.99a | 2.79 ± 2.79a | 2.76 ± 2.04a | 11.61 ± 4.31a | |
Grooming | 0.00 ± 0.00a | 0.00 ± 0.00a | 1.56 ± 1.05a | 3.64 ± 2.43a | |
Waving up | 6.14 ± 6.14a | 0.00 ± 0.00a | 1.04 ± 1.04a | 11.70 ± 4.32a | |
Biting body | 0.87 ± 0.77a | 1.21 ± 0.83a | 2.63 ± 1.30a | 3.06 ± 1.25a | |
Biting head | 4.48 ± 2.11a | 3.94 ± 2.45a | 3.89 ± 2.44a | 9.48 ± 4.39a | |
Grooming | 0.00 ± 0.00a | 0.00 ± 0.00a | 0.00 ± 0.00a | 9.90 ± 4.16a | |
Waving up | 2.05 ± 1.38a | 0.00 ± 0.00a | 0.00 ± 0.00a | 0.10 ± 0.10a | |
Biting body | 4.89 ± 2.38a | 0.75 ± 0.50b | 2.87 ± 1.37b | 11.43 ± 3.94a | |
Biting head | 1.84 ± 1.07a | 10.60 ± 4.65a | 12.59 ± 4.89a | 20.14 ± 9.16a | |
Grooming | 2.65 ± 1.93a | 2.59 ± 2.59ab | 2.11 ± 2.11b | 4.58 ± 3.41a | |
Waving up | 6.52 ± 4.68a | 0.00 ± 0.00b | 2.17 ± 0.98b | 2.32 ± 1.08a |
3.4 Effect of Larval Competition on Cannibalism and Development
For 3rd instar larvae, the highest cannibalism rates were observed when fed with leaves and without food in the combination ( and ) (Table 6). The highest pupation rate was observed without competition, which was significantly higher than that under the kernel () and leaf treatments ( and ) (, ; , ). The pupal weight in the kernel treatment was significantly higher than that in the silk and without competition treatments () (, ). There were no significant differences in the pupal period among all treatments.
L-instara | Treatment | b | Cannibalism (%) | Pupation rate (%) | c | Pupal weight (g) | Pupal period (d) | |
---|---|---|---|---|---|---|---|---|
Combination | Diet | |||||||
3rd | Leaf | 10 | 40% | 0.00% ± 0.00% c | 0 | -d | — | |
Silk | 10 | 0% | 50.00% ± 16.67% ab | 5 | 0.05 ± 0.01a | 11.00 ± 0.71a | ||
Kernel | 10 | 0% | 40.00% ± 16.67% b | 4 | 0.05 ± 0.01a | 13.50 ± 1.55a | ||
CK (without food) | 10 | 40% | 0.00% ± 0.00% c | 0 | — | — | ||
CK (without competition) | 10 | — | 80.00% ± 13.33% a | 8 | 0.04 ± 0.00a | 13.40 ± 1.21a | ||
3rd | Leaf | 5 | 40% | 0.00% ± 0.00% b | 0 | — | — | |
Silk | 5 | 20% | 60.00% ± 24.50% a | 3 | 0.05 ± 0.00b | 16.33 ± 5.84a | ||
Kernel | 5 | 0% | 60.00% ± 24.50% a | 3 | 0.07 ± 0.01a | 15.33 ± 3.71a | ||
CK (without food) | 5 | 40% | 0.00% ± 0.00% b | 0 | — | — | ||
CK (without competition) | 10 | — | 80.00% ± 13.33% a | 8 | 0.04 ± 0.00b | 13.40 ± 1.21a | ||
4th | Leaf | 5 | 0% | 0.00% ± 0.00%% c | 0 | — | — | |
Silk | 5 | 0% | 100.00% ± 0.00% a | 5 | 0.06 ± 0.01a | 12.00 ± 1.14a | ||
Kernel | 5 | 0% | 100.00% ± 0.00% a | 5 | 0.05 ± 0.00a | 12.80 ± 1.59a | ||
CK (without food) | 5 | 0% | 40.00% ± 25.00% b | 2 | 0.04 ± 0.01a | 12.50 ± 1.50a | ||
CK (without competition) | 10 | — | 90.00% ± 10.00% a | 9 | 0.05 ± 0.00a | 14.33 ± 0.88a | ||
4th | Leaf | 10 | 30% | 20.00% ± 13.33% b | 2 | 0.03 ± 0.00c | 12.00 ± 1.00a | |
Silk | 10 | 0% | 40.00% ± 16.33% b | 4 | 0.05 ± 0.01abc | 12.50 ± 1.55a | ||
Kernel | 10 | 10% | 50.00% ± 18.90% ab | 4 | 0.06 ± 0.01a | 13.50 ± 1.50a | ||
CK (without food) | 10 | 10% | 30.00% ± 15.28% b | 3 | 0.03 ± 0.01bc | 12.33 ± 0.88a | ||
CK (without competition) | 10 | — | 90.00% ± 10.00% a | 9 | 0.05 ± 0.00ab | 14.33 ± 0.88a |
- a Instar of Ostrinia furnacalis larvae evaluated.
- b Number of Ostrinia furnacalis larvae evaluated.
- c Number of Ostrinia furnacalis pupa evaluated.
- d No data obtained.
For 4th instar larvae, the cannibalism rate was highest in combination, with the leaf treatment showing the greatest rate, followed by kernel, without food and silk treatments. The pupation rate without competition was significantly higher than that under the leaf () and silk treatments ( and ) (, ; , ). The pupal weight in both the kernel and without competition treatments was significantly higher than that in the leaf treatment () (, ).
4 Discussion
4.1 Behavioural Classification and Model Validation
The current study reveals important insights into the complex behaviours of O. furnacalis larvae, identifying ten distinct behavioural patterns through detailed observation. Utilising a deep learning model, we specifically focus on competitive behaviour in various scenarios. Notably, when feeding on maize leaves, larvae exhibit increased frequencies of biting behaviours (Biting body and Biting head) compared to kernels and silk. Additionally, developmental differences were observed, as both 3rd and 4th instar larvae produced heavier pupae when fed on maize kernels. These findings contribute significantly to understanding intraspecific competition in O. furnacalis, emphasising the practical utility of YOLOv7 for real-time detection with high precision (0.958), recall (0.959) and [email protected] (0.972).
The meticulous categorisation of larval behaviours reveals statistically significant disparities in the frequency of key behaviours, such as Waving up, Biting body and Biting head (Scott et al. 2010), indicating potential communicative or aggressive interactions among larvae (Benelli 2015; Rao et al. 2021). The trained YOLOv7 model demonstrated excellent stability and convergence across performance metrics (Jang et al. 2024). This not only attests to the success of the model training but also highlights its reliability for real-time monitoring of larval activities. Its outstanding performance establishes the model as a dependable tool for high-throughput behavioural analysis in entomological research.
4.2 Dietary Impacts on Competition and Cannibalism
The investigation of larval competition under different dietary conditions revealed notable behavioural patterns (Hardin et al. 2015). The most intense competition occurred when larvae were deprived of food, suggesting heightened aggression in resource-scarce environments, aligning with earlier research (Bentivenha et al. 2017; Polis 1981; Sokame et al. 2022). Furthermore, the frequency and duration of larval competitive behaviour varied significantly across different diets, underscoring the profound impact of dietary factors on larval interactions (Bentivenha et al. 2017; Ongaratto et al. 2021). Importantly, among the dietary treatments, leaves induced a notably higher frequency of competition compared to kernel and silk. Biting behaviours (Biting body and Biting head) showed no specific preference for the body or head; rather, larvae bit whichever body part they first encountered during interactions. Biting head episodes tended to last longer, likely due to occasional head-on contact that resulted in stalemates.
The intricate interplay between competition and food sources (various maize tissues) has unveiled critical insights into cannibalism rates, pupation rates and pupal weights in both 3rd and 4th instars. The cannibalism rates of 3rd instar larvae were notably influenced by the presence or absence of food. When the food was leaves, the cannibalism rate was the highest, consistent with the observation without food. For 4th instar larvae, leaf tissue emerged as the predominant contributor to cannibalism rates. Nevertheless, cannibalism was observed with available food, highlighting that resource scarcity is not the sole driver (Polis 1981). Physical attributes such as size and strength influenced fight success, as evidenced by the dominance of 4th instar larvae in cannibalistic events (Ongaratto et al. 2021). Moreover, the sensitivity of pupation rates and pupal weights to variations in both competition and diet further underscores the intricate relationships at play (Applebaum and Heifetz 1999). Competition may lead to the occurrence of cannibalism, which in turn causes larval death or injury, thereby resulting in a decrease in pupation rate. Pupal weight was also affected by injury caused by competition and nutrient content in food.
4.3 Deep Learning in Behavioural Analysis
Deep learning has found significant applications in agriculture, such as identifying plant diseases and pests (Hadi et al. 2021; Panigrahi et al. 2020; Romano 2025; Santaera et al. 2025), predicting crop yields (Maimaitijiang et al. 2020; Ren et al. 2023), and monitoring crop growth (Rasti et al. 2021). This widespread use encourages the exploration of deep learning techniques for understanding insect behaviour. Compared to traditional manual observation, the use of deep learning significantly enhances the efficiency of behavioural analysis. Moreover, the trained model demonstrates a high degree of accuracy in detecting and tracking larvae, enabling a more detailed analysis of their behaviour compared to manual tracking (Hu et al. 2021; Mah et al. 2021). This deep learning approach provides a flexible and scalable solution for analysing intraspecific larval behaviour, making it an invaluable tool for various biological and ecological research endeavours. Our deep learning approach enabled us to analyse and categorise intricate larval behaviours, providing novel insights into the dynamics of intraspecific competition.
4.4 Implications for Pest Management and Future Directions
Integrating deep learning with classical entomological methods enabled a deeper understanding of how larval behaviour, competition, and development interact under different conditions. The comprehensive research methodology provides a favourable paradigm for a thorough understanding of insect behaviour and ecological dynamics in agricultural ecosystems. The study also sets a foundation for future research on pest management strategies and ecological dynamics.
This research pushes the boundaries of AI-based approaches in entomology, offering a flexible and scalable solution for unravelling the complexities of economically significant insect species. The ability of AI to discern complex behavioural processes opens new avenues for precision agriculture and pest control, reinforcing its pivotal role in shaping the future of sustainable and efficient agricultural practices. Our study highlights the crucial role of AI in addressing critical research gaps and fostering a comprehensive understanding of insect behaviour, contributing to the advancement of agricultural practices.
Author Contributions
Xiao Feng: conceptualisation, methodology, software, data curation, investigation, writing – original draft, writing – review and editing. Farman Ullah: methodology, writing – review and editing. Jiali Liu: methodology, data curation, investigation. Sohail Abbas: data curation, writing – original draft. Gianluca Manduca: software, writing – review and editing. Jamin Ali: methodology, writing – review and editing. Donato Romano: writing – review and editing. Nicolas Desneux: writing – review and editing. Rizhao Chen: conceptualisation, methodology, software, funding acquisition, writing – original draft, writing – review and editing.
Acknowledgements
This work was supported by the Jilin Government fund on major pest control (grant number 20220203198SF), the Ministry of Science and Technology of China (grant number 2022YFD1500701) and the Ministry of Agriculture of China (grant number 15226025).
Conflicts of Interest
The authors declare no conflicts of interest.
Open Research
Data Availability Statement
The data that support the findings of this study are openly available in Data.rar at https://github.com/Fexier/Deep-learning-based-detection-of-cannibalism-and-competition-behavior-in-Asian-corn-borer-larvae.