AL-ViT: Label-efficient Robusta coffee-bean defect detection in Thailand using active learning vision transformers

• AL-ViT framework for coffee grading : Introduces an end-to-end AL–ViT pipeline for Robusta green-bean binary defect detection, with label-efficiency verified across five selectors. • Thai-Robusta dataset : Curates and releases the first high-resolution image dataset of southern-Thai Robusta beans captured under real-world mill-floor lighting conditions. • Hybrid AL strategy : Proposes a novel hybrid query strategy combining uncertainty and diversity, achieving 97.1 % accuracy with only 51 % labeled data, approaching fully supervised ViT performance. • Deployment-ready performance : Demonstrates real-time inference speeds (242 beans/sec) and rapid training cycles, making the framework suitable for industrial deployment with minimal annotation and hardware requirements. In major training and export markets, the coffee bean grading process still relies heavily on manual labor to sort individual beans from large harvest volumes. This labor-intensive task is time-consuming, costly, and prone to human error, especially within Thailand’s rapidly expanding Robusta coffee sector. This study introduces AL–ViT, an end-to-end Active-Learning Vision Transformer framework that operationalizes active learning and transformer-based feature extraction within a single, production-oriented pipeline. The framework integrates a ViT-Base/16 backbone with seven active learning (AL) query strategies, random sampling, entropy-based selection, Bayesian Active Learning by Disagreement (BALD), Batch Active Learning by Diverse Gradient Embeddings (BADGE), Core-Set diversity sampling, ensemble disagreement, and a novel hybrid uncertainty–diversity strategy designed to balance informativeness and representativeness during sample acquisition. A high-resolution dataset of 2,098 Robusta coffee bean images was collected under controlled-lighting conditions aligned with grading-machine setups, with only 5 % initially labeled and the remainder forming the AL pool. Across five random seeds, the hybrid strategy without MixUp augmentation achieved 97.1 % accuracy and an F1bad of 0.956 using just 850 labels (41 % of the dataset), within 0.3 percentage points of full supervision. Operational reliability, defined as 95 % accuracy, consistent with prior inspection benchmarks, was reached with only 407 labels, reflecting a 75 % reduction in annotation. Entropy sampling showed the fastest early-stage gains, whereas BADGE lagged by >1 pp; Core-Set and Ensemble provided moderate but stable results. Augmentation and calibration analyses indicated that explicit methods (MixUp, CutMix, RandAugment) offered no further benefit, with the hybrid pipeline already achieving well-calibrated probabilities. Statistical validation via paired t-tests, effect sizes, and bootstrap CIs confirmed consistent improvements of uncertainty-driven strategies over random sampling. Overall, the proposed AL–ViT framework establishes a label-efficient and practically deployable approach for agricultural quality control, achieving near-supervised accuracy at a fraction of the labeling cost.

Authors

Institutions

Publication Details

Journal
Intelligent Systems with Applications
Published
2025-11-28
DOI
https://doi.org/10.1016/j.iswa.2025.200612
Citations
1
Primary Topic
Coffee research and impacts
Type
article
Field-Weighted Citation Impact
1.39
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

AL-ViT: Label-efficient Robusta coffee-bean defect detection in Thailand using active learning vision transformers

Kitti Thamrongaphichartkul, Worapan Kusakunniran, Sirawich Vachmanus, Noppanan Phinklao et al.
1 citations
Intelligent Systems with Applications
Coffee research and impacts
1.39
article

AL-ViT: Label-efficient Robusta coffee-bean defect detection in Thailand using active learning vision transformers

Kitti Thamrongaphichartkul, Worapan Kusakunniran, Sirawich Vachmanus, Noppanan Phinklao, Wimolsiri Pridasawas
article en
1 citations

Abstract

• AL-ViT framework for coffee grading : Introduces an end-to-end AL–ViT pipeline for Robusta green-bean binary defect detection, with label-efficiency verified across five selectors. • Thai-Robusta dataset : Curates and releases the first high-resolution image dataset of southern-Thai Robusta beans captured under real-world mill-floor lighting conditions. • Hybrid AL strategy : Proposes a novel hybrid query strategy combining uncertainty and diversity, achieving 97.1 % accuracy with only 51 % labeled data, approaching fully supervised ViT performance. • Deployment-ready performance : Demonstrates real-time inference speeds (242 beans/sec) and rapid training cycles, making the framework suitable for industrial deployment with minimal annotation and hardware requirements. In major training and export markets, the coffee bean grading process still relies heavily on manual labor to sort individual beans from large harvest volumes. This labor-intensive task is time-consuming, costly, and prone to human error, especially within Thailand’s rapidly expanding Robusta coffee sector. This study introduces AL–ViT, an end-to-end Active-Learning Vision Transformer framework that operationalizes active learning and transformer-based feature extraction within a single, production-oriented pipeline. The framework integrates a ViT-Base/16 backbone with seven active learning (AL) query strategies, random sampling, entropy-based selection, Bayesian Active Learning by Disagreement (BALD), Batch Active Learning by Diverse Gradient Embeddings (BADGE), Core-Set diversity sampling, ensemble disagreement, and a novel hybrid uncertainty–diversity strategy designed to balance informativeness and representativeness during sample acquisition. A high-resolution dataset of 2,098 Robusta coffee bean images was collected under controlled-lighting conditions aligned with grading-machine setups, with only 5 % initially labeled and the remainder forming the AL pool. Across five random seeds, the hybrid strategy without MixUp augmentation achieved 97.1 % accuracy and an F1bad of 0.956 using just 850 labels (41 % of the dataset), within 0.3 percentage points of full supervision. Operational reliability, defined as 95 % accuracy, consistent with prior inspection benchmarks, was reached with only 407 labels, reflecting a 75 % reduction in annotation. Entropy sampling showed the fastest early-stage gains, whereas BADGE lagged by >1 pp; Core-Set and Ensemble provided moderate but stable results. Augmentation and calibration analyses indicated that explicit methods (MixUp, CutMix, RandAugment) offered no further benefit, with the hybrid pipeline already achieving well-calibrated probabilities. Statistical validation via paired t-tests, effect sizes, and bootstrap CIs confirmed consistent improvements of uncertainty-driven strategies over random sampling. Overall, the proposed AL–ViT framework establishes a label-efficient and practically deployable approach for agricultural quality control, achieving near-supervised accuracy at a fraction of the labeling cost.

Intelligent Systems with ApplicationsVol. 29
Mahidol University (TH), King Mongkut's University of Technology Thonburi (TH)
Openalex Percentile: Top 14%
Coffee research and impacts
1.39
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.