# Real-time on-device weed identification using a hardware-efficient lightweight CNN

**Authors:** Yuxuan Zhang, Yuchen Lu, Luciano Sebastian Martinez-Rau, Quan Qiu, Sebastian Bader

PMC · DOI: 10.3389/fpls.2026.1747863 · Frontiers in Plant Science · 2026-02-16

## TL;DR

This paper introduces TinyWeedNet, a lightweight CNN for real-time weed identification on low-power agricultural devices.

## Contribution

The novel TinyWeedNet model enables on-device weed recognition with high accuracy and low energy consumption.

## Key findings

- TinyWeedNet achieves 97.26% accuracy with only 0.48 M parameters.
- The model supports sub-90 ms inference and low energy consumption on an STM32H7 microcontroller.
- It balances accuracy, speed, and energy efficiency for resource-constrained agricultural platforms.

## Abstract

Accurate and timely weed identification is fundamental to sustainable crop management, particularly for autonomous agricultural systems operating under strict energy and hardware constraints. While deep learning has significantly advanced image-based weed recognition, most existing models rely on GPU-based inference and therefore cannot be deployed directly in low-power field devices. In this study, we propose a hardware-efficient lightweight convolutional neural network (CNN), named TinyWeedNet, designed specifically for real-time on-device weed identification in precision agriculture. The model integrates multi-scale feature extraction, depthwise separable inverted residual blocks, and compact channel attention to enhance discriminative ability while maintaining a minimal computational footprint. To evaluate its suitability for field deployment, TinyWeedNet was trained and tested on the public DeepWeeds dataset and implemented on an STM32H7 microcontroller via the TinyML workflow. Experimental results demonstrate that the model achieves 97.26% classification accuracy with only 0.48 M parameters, supporting sub-90 ms inference and low energy consumption during fully embedded execution. A comprehensive analysis, including benchmark comparisons, hyperparameter sensitivity tests, and ablation studies, demonstrates that TinyWeedNet provides a good balance of accuracy, speed, and energy efficiency for resource-constrained agricultural platforms. Overall, this work demonstrates a practical pathway for integrating real-time, low-power weed identification into field robots, UAVs, and distributed sensing nodes, contributing to more autonomous and energy-aware weed management strategies in precision agriculture.

## Full-text entities

- **Diseases:** Agricultural weed (MESH:D000382), Convolution block (MESH:D006327), prickly acacia (MESH:D008883)
- **Chemicals:** STM32H7 (-), blood glucose (MESH:D001786)
- **Species:** Sida acuta (species) [taxon 108357], Sida (genus) [taxon 108335], Ziziphus mauritiana (ber, species) [taxon 157914], Parthenium hysterophorus (species) [taxon 183063], Eleusine indica (Dutch grass, species) [taxon 29674], kochia [taxon 267503], Linum usitatissimum (flax, species) [taxon 4006], Parkinsonia aculeata (Jerusalem thorn, species) [taxon 58886], Capparis spinosa (caperbush, species) [taxon 65558], Ambrosia artemisiifolia (annual ragweed, species) [taxon 4212], Glycine max (soybean, species) [taxon 3847], Malus domestica (apple, species) [taxon 3750], Senecio vulgaris (old-man-in-the-Spring, species) [taxon 76276], Beta vulgaris subsp. vulgaris (field beet, subspecies) [taxon 3555], Stachytarpheta jamaicensis (bastard vervain, species) [taxon 634377], Vachellia nilotica (babul, species) [taxon 138033], Lantana camara (species) [taxon 126435], Cryptostegia grandiflora (species) [taxon 63468]
- **Mutations:** S from 8 to 24, 5 K at R

## Full text

_Full body text omitted from this summary view._ Fetch the complete paper as Markdown: https://tomesphere.com/paper/PMC12950715/full.md

## Figures

5 figures with captions in the complete paper: https://tomesphere.com/paper/PMC12950715/full.md

## References

38 references — full list in the complete paper: https://tomesphere.com/paper/PMC12950715/full.md

---
Source: https://tomesphere.com/paper/PMC12950715