Performance Analysis of CNN and Transformers Models with Weighted Ensemble for Agricultural Pest Image Classification

Insect pests cause large and recurring crop losses, and manual identification in the field is slow and needs entomological expertise.This paper compares a convolutional network (ResNet50) with two vision transformers (ViT-B/16 and Swin-B) for fine-grained pest recognition on IP102, a public benchmark of 75,222 images in 102 classes with a strongly long-tailed class distribution.All three models are fine-tuned from ImageNet-pretrained weights under one shared, short (six-epoch) training protocol and evaluated once on the official 22,619-image test split.We then combine them by weighted soft voting, with the weights tuned only on the validation split.Swin-B is the best single model, with 76.29% top 1 accuracy and 0.684 macro F1, narrowly ahead of ViT-B/16 (75.90%,McNemar 𝑝 = 0.046) and well ahead of ResNet50 (70.67%).The ensemble reaches 77.09% top 1 accuracy (95% bootstrap CI 76.57-77.65%),94.77% top 5 accuracy and 0.694 macro F1, a significant gain over Swin-B (McNemar 𝑝 < 10 -12 ).Validation-based weight tuning assigned ResNet50 a weight of zero, so the final ensemble combines the two transformers.All three models fail on the same 18.0% of test images, per-class F1 rises with the number of training images (Spearman 𝜌 ≈ 0.30-0.33),and the most frequent errors are between closely related species and between life stages of the same pest.Code, configurations and all predictions are released for reproducibility.

Authors

Institutions

Publication Details

Journal
IJARCCE
Published
2026-11-08
DOI
https://doi.org/10.17148/ijarcce.2026.151180
Primary Topic
Smart Agriculture and AI
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
NOV
article

Performance Analysis of CNN and Transformers Models with Weighted Ensemble for Agricultural Pest Image Classification

Arathi Chitla, Narsaiah Battu
2 links
IJARCCE
Smart Agriculture and AI
article

Performance Analysis of CNN and Transformers Models with Weighted Ensemble for Agricultural Pest Image Classification

Arathi Chitla, Narsaiah Battu
article en

Abstract

Insect pests cause large and recurring crop losses, and manual identification in the field is slow and needs entomological expertise.This paper compares a convolutional network (ResNet50) with two vision transformers (ViT-B/16 and Swin-B) for fine-grained pest recognition on IP102, a public benchmark of 75,222 images in 102 classes with a strongly long-tailed class distribution.All three models are fine-tuned from ImageNet-pretrained weights under one shared, short (six-epoch) training protocol and evaluated once on the official 22,619-image test split.We then combine them by weighted soft voting, with the weights tuned only on the validation split.Swin-B is the best single model, with 76.29% top 1 accuracy and 0.684 macro F1, narrowly ahead of ViT-B/16 (75.90%,McNemar 𝑝 = 0.046) and well ahead of ResNet50 (70.67%).The ensemble reaches 77.09% top 1 accuracy (95% bootstrap CI 76.57-77.65%),94.77% top 5 accuracy and 0.694 macro F1, a significant gain over Swin-B (McNemar 𝑝 < 10 -12 ).Validation-based weight tuning assigned ResNet50 a weight of zero, so the final ensemble combines the two transformers.All three models fail on the same 18.0% of test images, per-class F1 rises with the number of training images (Spearman 𝜌 ≈ 0.30-0.33),and the most frequent errors are between closely related species and between life stages of the same pest.Code, configurations and all predictions are released for reproducibility.

IJARCCEVol. 15(11)
Telangana University (IN)
Zero hunger
Smart Agriculture and AI
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon