With an increasing amount of connected cars and devices having more and more sensors, the development of smart architectures and algorithms to efficiently transport data is a major concern. The selection of relays to allow users to connect to Internet is an important aspect in networks with high mobility, particularly in low-population areas having poor network coverage. Furthermore, cellular connectivity can be expensive for users. The solution proposed in this paper uses a machine learning based classification algorithm to select the best relays amongst any user based on their mobility profile. Not only this solution can be used on its own to enhance network performance without requiring a dedicated architecture, but it can be coupled with other algorithms as well to increase performance even more. Simulation results will show the proposition is able to scale up to several hundreds of users simultaneously, it improves the delivery rate of packets by up to a factor 2, it increases connectivity, generates less signaling and yields a more stable topology compared to a random selection or the use of static relays.