[论文解读] A Lightweight CNN-Transformer Model for Learning Traveling Salesman Problems
该论文提出了一种轻量级CNN-Transformer模型,通过CNN嵌入层增强空间特征学习能力,并通过解码器中的部分自注意力机制降低计算开销。与先前基于Transformer的模型相比,该模型在TSP实例上实现了最先进(SOTA)的解质量,同时将GPU内存使用量降低了约20%,推理时间减少了45%。
Several studies have attempted to solve traveling salesman problems (TSPs) using various deep learning techniques. Among them, Transformer-based models show state-of-the-art performance even for large-scale Traveling Salesman Problems (TSPs). However, they are based on fully-connected attention models and suffer from large computational complexity and GPU memory usage. Our work is the first CNN-Transformer model based on a CNN embedding layer and partial self-attention for TSP. Our CNN-Transformer model is able to better learn spatial features from input data using a CNN embedding layer compared with the standard Transformer-based models. It also removes considerable redundancy in fully-connected attention models using the proposed partial self-attention. Experimental results show that the proposed CNN embedding layer and partial self-attention are very effective in improving performance and computational complexity. The proposed model exhibits the best performance in real-world datasets and outperforms other existing state-of-the-art (SOTA) Transformer-based models in various aspects. Our code is publicly available at https://github.com/cm8908/CNN_Transformer3.
研究动机与目标
- 解决标准Transformer模型在求解大规模TSP实例时计算复杂度高和GPU内存占用大的问题。
- 通过用基于CNN的嵌入层替代标准嵌入层,提升TSP中的空间特征提取能力。
- 通过在解码器中采用部分自注意力机制,减少冗余注意力计算,提升效率而不损失解质量。
- 在内存占用更低、推理速度更快的前提下,实现优于现有最先进(SOTA)基于Transformer的TSP模型的解质量。
- 为组合优化问题(如TSP)提供一种更高效、更具可扩展性的深度学习解决方案。
提出的方法
- 引入基于CNN的嵌入层,以更好地捕捉城市坐标输入中的局部空间模式。
- 采用改进的Transformer解码器,引入部分自注意力机制,仅对相关标记计算注意力,减少冗余。
- 使用自回归解码策略结合束搜索(beam search)生成有效TSP路径,同时避免重复访问城市。
- 在编码器和解码器模块中应用批量归一化,与先前模型中使用的标准层归一化不同。
- 采用监督学习进行模型训练,以路径长度作为优化目标。
- 由于内存消耗降低,训练过程中可使用更大的批量大小,从而提升训练效率。

实验结果
研究问题
- RQ1与标准Transformer相比,CNN-Transformer混合模型是否能提升TSP的空间特征学习能力?
- RQ2在解码器中采用部分自注意力机制是否能降低计算开销,同时保持或提升解质量?
- RQ3所提出的模型是否能在推理速度和GPU内存使用方面优于当前最先进(SOTA)的基于Transformer的TSP求解器?
- RQ4该模型在合成随机TSP实例和真实世界TSP基准(如kroC100和berlin52)上的表现如何?
- RQ5通过结合启发式优化技术,该模型的性能可提升到何种程度?
主要发现
- 与TSP Transformer模型相比,所提模型将GPU内存使用量降低了约20%,从而支持更大的批量大小。
- 对于TSP100,该模型的推理时间比TSP Transformer快45%,分别为51.33秒和74.86秒。
- 在kroC100上,该模型的平均路径长度为21,523,优于TSP Transformer的21,788。
- 在berlin52上,该模型的平均路径长度为7,610,优于TSP Transformer的7,637。
- 该模型的参数量略高(1.43M)于TSP Transformer(1.41M),但其效率与性能的提升有效抵消了这一差异。
- 该模型在随机和真实世界TSP实例上均表现出更优的解质量,TSP50的最优性间隙为0.0004%,TSP100为0.39%。

更好的研究,从现在开始
从阅读论文到最终审阅,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。