A Machine Learning Approach to Forecasting SEP Events with Solar Activities