Abstract

<title>Abstract</title> The global expansion of quinoa demands optimized non-invasive, objective, and standardized methodologies to ensure uniform quality. In this study, we developed and validated an on-device artificial vision system for regulatory classification of white quinoa according to Peruvian standard (NTP) 011.462:2025. A total of 3000 Sample Units (SU) from Puno (Peru) were used. Each grain was segmented into 64×64 px regions of interest (ROIs) and fed into a Convolutional Neural Network (CNN) based on MobileNet_v1_0.50_224, evaluated using GroupKFold (k = 5, by SU) as the grouping unit. Metrics were estimated with 95% confidence intervals (CIs) using Wilson/Bootstrap, and probabilistic calibration via temperature scaling (TS). The CNN labelled individual grains under 4 size classes and 5 morphologies, enabling each SU to be assigned a type and category via a rule-based engine consistent with NTP thresholds. The system achieved 97.14% Accuracy (pooled SU-level), 94.15% F1_macro, and 0.94 MCC, with specificities &gt; 99% (size) and &gt; 98% (category). Expected Calibration Error (ECE) improved substantially; size: 0.061 to 0.028, defect: 0.094 to 0.052, and category: 0.048 to 0.023, enabling reliable decision thresholds without loss of discrimination. On-device inference required 0.345 s per sample and 0.188 s for capture. The AVS provides an objective, reproducible, and auditable decision for Android mid-range devices, maintaining high generalization and full traceability. Its modular architecture may serve as a reference for other grains and agro-food matrices under their respective chromatic/morphological standards.

Affiliated Institutions

Related Publications

Publication Info

Year
2025
Type
article
Citations
0
Access
Closed

Social Impact

Social media, news, blog, policy document mentions

Citation Metrics

0
OpenAlex
0
CrossRef

Cite This

Orlando Salazar Campos, Daniel Tafur-Vera, Percimil Lecca-Pino et al. (2025). Post-harvest quality control of white quinoa on smartphones using deep learning. . https://doi.org/10.21203/rs.3.rs-8231004/v1

Identifiers

DOI
10.21203/rs.3.rs-8231004/v1

Data Quality

Data completeness: 70%