Extracting and detecting road network consistency from high-resolution remote sensing images has been a hot and difficult problem in the computer vision. Although it has made significant progress, there is still a phenomenon of high training accuracy but unsatisfactory actual extraction and detection results. The attention mechanism is one of the efficient and practical mechanisms in deep learning. It improves the performance of deep learning by selectively focusing on a portion of all information while ignoring other visible information, while effectively utilizing computing resources. Numerous experiments have also confirmed that the attention mechanism is resource-saving and effective. Its plug and play feature brings great convenience to programmers. In order to provide better road network detection results and solve the above problem, this paper combines the channel attention mechanism with ResNet and proposes SE-ResNet and ECA-ResNet for remote sensing image road network detection, making networks extract and learn road network features and ignore some non-road network features. The experimental results show that on the Massachusetts roads (MR) and CHN6-CUG roads datasets, ECA-ResNet and SE-ResNet based on channel attention mechanism perform similar to LeNet7 and ResNet in terms of accuracy, loss, accuracy convergence, and loss convergence, and even increase a certain computational burden. However, their final road network detection results (including road network detection pixel count, precision, recall, accuracy, IOU, F1 score, and actual road network detection result) of the former are significantly better than those of the latter. The channel attention mechanism makes the deep neural network pay more attention to the extraction and learning of road network features, while ignoring the extraction and learning of some non-road network features, which improves the accuracy of containing road network samples and reduces the accuracy of not containing road network samples. Therefore, the performance of ECA-ResNet and SE-ResNet is similar to that of LeNet7 and ResNet in the accuracy, loss, accuracy convergence and loss convergence, but the final road network detection results of ECA-ResNet and SE-ResNet are significantly better than those of LeNet7 and ResNet. Therefore, the proposed ECA-ResNet and SE-ResNet have broad application prospects in road network detection, especially ECA-ResNet.