paper-with-me

홈 › Papers

Unifying Convolution and Attention via Convolutional Nearest Neighbors

2025-11-18 · Mingi Kang, Jeová Farias Sales Rocha Neto arxiv

Convolutional Neural Networks and Vision Transformers are the two dominant architectural families in computer vision, defined by spatially local convolution and global self-attention respectively. Despite their apparent differences, we show that both operations are special cases of a single $k$-nearest neighbor aggregation framework: convolution selects neighbors by spatial proximity while attention selects by feature similarity, placing them at two ends of a shared operational spectrum. We introduce Convolutional Nearest Neighbors (ConvNN), a unified framework that exactly recovers standard and depthwise convolution, self-attention, and sparse attention variants including KVT-attention as special cases, and exposes the design space of neighbor-selection strategies between them through configurable similarity functions, positional encodings, and aggregation kernels. We validate ConvNN on ImageNet-1K classification across two complementary architectures: a hybrid branching layer in ResNet-50 that combines local and global feature learning, improving top-1 accuracy by 3.0% over the ResNet-50 baseline, and ConvNN-attention in ViT-Base that achieves 81.64% top-1 accuracy, surpassing standard multi-head self-attention by 0.7%. Together, these results demonstrate that ConvNN provides a principled foundation for designing operations that bridge convolutional and attention-based computation.

📄 PDF Abstract BibTeX arXiv:2511.14137

Code (0)

등록된 구현이 없습니다.

Similar Papers 제목 키워드 기반

Interpolation between Convolution and Attention via K-Nearest Neighbors

2026-05-31 · Mingi Kang arxiv

The shift from Convolutional Neural Networks to Transformers has reshaped computer vision, yet these two architectural families are typically viewed as fundamentally distinct. Convolutional Neural Networks are defined by…

Neural Nearest Neighbors Networks

2018-10-30 · NeurIPS 2018 12 · Tobias Plötz, Stefan Roth

Non-local methods exploiting the self-similarity of natural signals have been well studied, for example in image analysis and restoration. Existing approaches, however, rely on k-nearest neighbors (KNN) matching in a fix…

DenoisingImage DenoisingImage RestorationImage Super-Resolution+1

Detecting 5G Narrowband Jammers with CNN, k-nearest Neighbors, and Support Vector Machines

2024-05-07 · Matteo Varotto, Florian Heinrichs, Timo Schuerg, Stefano Tomasin 외

5G cellular networks are particularly vulnerable against narrowband jammers that target specific control sub-channels in the radio signal. One mitigation approach is to detect such jamming attacks with an online observat…

Binary ClassificationClassification

Generalized Convolutional Neural Networks for Point Cloud Data

2017-07-20 · Aleksandr Savchenkov, Andrew Davis, Xuan Zhao

The introduction of cheap RGB-D cameras, stereo cameras, and LIDAR devices has given the computer vision community 3D information that conventional RGB cameras cannot provide. This data is often stored as a point cloud. …

Feature Engineering

When Naive Bayes Nearest Neighbors Meet Convolutional Neural Networks

2016-06-01 · CVPR 2016 6 · Ilja Kuzborskij, Fabio Maria Carlucci, Barbara Caputo

Since Convolutional Neural Networks (CNNs) have become the leading learning paradigm in visual recognition, Naive Bayes Nearest Neighbor (NBNN)-based classifiers have lost momentum in the community. This is because (1) s…

Domain Adaptation