The smart solar LED lamp for pest forecasting is used to research the classification, identification and counting for the rice pests based on the image processing, and to estimate the condition of the rice pests. This system that uses solar energy as power supply is designed to trap pests with light wave. It has realized the artificial intelligence by taking image acquisition, image processing, image feature extraction of the insect body and using image classification and recognition technology to identify the pests. It can effectively kill the rice grub to improve the production of rice at the same time. The smart solar LED lamp is the most ideal choice for pest control with the combination of trapping pests, observing and predicting, and species researching, which meets the demands of the national sustainable development strategy and the healthy development of agricultural economy. It also helps a lot for future industrial pest prevention and researching work of statistics.