Measurements

Putting an end to false alarms in exports: AI that can finally distinguish a live larva from simple internal decay

Advanced deep learning algorithms solve the long-standing problem of false positives for fungi at customs.

orange 1.jpeg
29 October, 2026

New research published in overcomes a major, long-standing obstacle for the agribusiness sector: the use of automated X-ray systems without the risk of natural blemishes or fungal growth confusing the technology and compromising healthy shipments.


The limitations of conventional X-ray systems

Operators at produce packing facilities and customs inspectors are well aware that industrial X-ray scanners are nothing new; they have been used for years to detect density anomalies in food products. However, in the context of international trade, traditional systems suffer from a critical flaw that renders them unsuitable for rigorous phytosanitary certification: a dark spot inside an orange is almost impossible to distinguish—whether it is a tunnel created by a fruit fly larva (*Ceratitis capitata*) or simply a patch of natural decay or common fungus.

Until now, in cases of uncertainty, the scanner would trigger an alert as a precautionary measure, or require a human operator to spend hours analyzing screens to determine the cause of the damage. This created unsustainable bottlenecks and led to frequent false positives, resulting in the erroneous destruction or detention of commercial shipping containers.


What is truly new about this study?

An international research team has just published a groundbreaking advancement that addresses this problem at its root not by improving the X-ray machine itself, but by equipping it with an analytical "brain" based on Artificial Intelligence (Deep Learning), a novel approach for this specific purpose:

  1. AI that "learns" to distinguish between pests and rot: The major scientific leap lies in the use of transfer-learning models (such as the DenseNet121 architecture), which can map and isolate the precise mathematical morphology of larval tunnels, differentiating them from tissue affected by common pathogens. This drastically reduces the historical margin of error, where any internal defect would previously trigger a false-positive quarantine alert.

  2. Resolving "label noise" through attention-based learning: Until now, training an AI using whole oranges was mathematically ineffective, as 99% of the fruit consists of healthy pulp, with only a few microscopic pixels revealing the presence of an insect. This study introduces, for the first time, an "attention-based multiple instance learning" system. It teaches the network to ignore the massive "noise" of healthy tissue and focus with surgical precision on the biological traces of the pest—all without the need for manual intervention.

  3. Commercially viable speed (less than 90 seconds per fruit): While high-precision scanners previously required time-consuming, laboratory-scale processes, this protocol has optimized micro-scanning to just 1 minute and 26 seconds per unit (across 125 projections). In validation tests, it achieved 100% sensitivity in detecting early larval stages (as early as the fourth day of incubation).


Towards Truly Autonomous Inspection

This advancement transforms imaging technology from a simple, passive visualization tool into an intelligent, real-time automated decision-making system. By overcoming the challenge of false positives for rot and eliminating reliance on the human eye, the industry is finally moving closer to 100% non-destructive inspection lines—capable of safeguarding global exports without sacrificing a single piece of marketable fruit.


Source:

Scolari, F., Serfontein, L., Kirkman, W., Moore, S., Hoffman, J., Bam, L., Moyano, A., Sutton, G. F., Pezzoni, C., Możdżyński, G. J., Pescini, D., Sandionigi, A., & Manrakhan, A. (2027). Applying convolutional neural networks to X-ray images to improve postharvest detection of fruit fly infestation. Postharvest Biology and Technology, 243, 114707.
https://doi.org/10.1016/j.postharvbio.2026.114707

 

 

 

 

 

whatsapp
Plan de Recuperación, Transformación y Resiliencia Financiado por la Unión Europea