A Novel CNN-Fourier-Vision Transformers Framework for Enhanced Pattern Recognition in Visual Data
摘要
In conventional architectures, passing raw convolutional neural network (CNN) feature maps directly to vision transformers (ViT) often results in suboptimal performance. This is mainly due to redundant activations and noise that can obscure relevant patterns, particularly in the case of small, localized anomalies. Additionally, directly transmitting these feature maps to the ViT limits the model’s ability to effectively capture long-range dependencies. A Fourier transform to the CNN-generated feature maps is proposed to address these limitations, converting them to the frequency domain. This transformation reduces noise and amplifies periodic patterns, thereby providing ViT with cleaner, frequency-enhanced inputs that allow for more effective self-attention across the entire image. The proposed method CNN-Fourier-ViT was evaluated on a wireless capsule endoscopy (WCE) dataset comprising 2,618 images focused on detecting bleeding versus non-bleeding conditions in gastrointestinal imaging. Experimental results demonstrated that our model outperformed traditional CNNs (e.g., ResNet-50, Inception-v3) and CNN-ViT hybrids, achieving an accuracy of 96% with a loss of 0.11. This approach illustrates the advantages of combining local feature extraction, frequency-based enhancement, and global attention for precise bleeding detection in WCE images, underscoring its potential in resource-limited clinical settings.