Traditional routing solutions have always had shortcomings such as insensitivity to the network and slow convergence. With the development of the data plane programming language P4，the data plane has the ability to collect network status information in real time.
However，a large amount of data is difficult to process through human methods，and the application of machine learning tools can solve the problem of difficult data processing. Based on the above two foundations，the P4 and machine learning-based routing schemes are tested by building a platform.
The test results show that the scheme using the reinforcement learning algorithm to assist the routing strategy generation has good performance.
From this point of view，machine learning has great potential in the field of networking，and is an important tool for realizing network intelligence.