# CNATNet: a convolution-attention hybrid network for safflower classification

**Authors:** Pengwei Ma, Nan Lian, Leilei Dong, Yunchen Luo, Zheng Sun, Yuanjiao Zhu, Zefang Chen, Jie Zhou

PMC · DOI: 10.3389/fpls.2025.1639269 · 2025-09-30

## TL;DR

CNATNet is a new lightweight AI model that improves safflower quality classification by combining convolution and attention techniques, enabling fast and accurate grading for agriculture and pharmaceutical use.

## Contribution

CNATNet introduces a novel convolution-attention hybrid network for efficient and accurate safflower classification.

## Key findings

- CNATNet achieves 98.6% accuracy at the cluster level and 95.6% at the filament level.
- It outperforms baselines like YOLOv11m and RT-DETRv2s with higher accuracy and lower latency.
- CNATNet runs at 63 FPS on Jetson Orin Nano, suitable for real-time embedded grading.

## Abstract

Safflower (Carthamus tinctorius L.) is an important medicinal and economic crop, where efficient and accurate filament grading is essential for quality control in agricultural and pharmaceutical applications. However, current methods rely on manual inspection, which is time-consuming and difficult to scale. A coarse-to-fine grading framework is established, consisting of cluster-level classification for rapid assessment and filament-level fine-grained classification. To implement this framework, a lightweight hybrid network, CNATNet, is designed by integrating convolutional operations and attention mechanisms. The classical C2f feature extraction module is optimized into two components: C2S2, a lightweight convolutional variant with cascaded split connections, and AnC2f, an n-order local attention mechanism. A depthwise separable convolution-based head (DWClassify) is further employed to accelerate inference while maintaining accuracy. Experiments on a high-resolution safflower filament dataset indicate that CNATNet achieves 98.6% accuracy at the cluster level and 95.6% at the filament level, with an average latency of 1.9 ms per image. Compared with representative baselines such as YOLOv11m and RT-DETRv2s, CNATNet consistently yields higher accuracy with reduced latency. Moreover, deployment on the Jetson Orin Nano demonstrates real-time performance at 63 FPS under 15 W, confirming its feasibility for embedded agricultural grading in resource-constrained environments. These results suggest that CNATNet provides a task-specific lightweight solution balancing accuracy and efficiency, with strong potential for practical safflower quality classification.

## Full-text entities

- **Species:** Carthamus tinctorius (safflower, species) [taxon 4222]

## Figures

12 figures with captions in the complete paper: https://tomesphere.com/paper/PMC12518317/full.md

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